public class SNFactory
extends java.lang.Object
Constructor and Description |
---|
SNFactory() |
Modifier and Type | Method and Description |
---|---|
static SNEdge |
createEdge(SNNode source,
SNNode target,
double weight,
SocialGraph.EDGEMEDIUM edgemedium)
Method to create an edge of a given medium type of a given weight between two nodes in the graph.
|
static SNEdge |
createEdge(SNNode source,
SNNode target,
double weight,
SocialGraph.EDGEMEDIUM edgemedium,
java.lang.String label)
Method to create an edge of a given medium type of a given weight between two nodes in the graph.
|
static SocialGraph |
createSocialGraph(SimulationContainer simulationContainer,
SNConfiguration sNConfiguration,
int numberOfNodes)
Method to initialize the SocialGraph given by the configuration
|
static SocialGraph |
createSocialGraph(SimulationContainer simulationContainer,
SNConfiguration sNConfiguration,
java.util.Set<SNNode> initialNodes)
Method to initialize the SocialGraph given by the configuration
|
static EdgeWeightManipulationScheme |
generateSNEdgeWeightMapping(java.lang.String scheme,
java.util.HashMap<java.lang.String,java.lang.Object> parameters)
Method to instantiate the EdgeWeightManipulationScheme for the social network based on the given parameters
|
static TopologyManipulationScheme |
generateSNTopologyManipulationScheme(java.lang.String scheme,
java.util.HashMap<java.lang.String,java.lang.Object> parameters)
Method to instantiate the TopologyManipulationScheme for the social network based on the given parameters
|
public static SocialGraph createSocialGraph(SimulationContainer simulationContainer, SNConfiguration sNConfiguration, java.util.Set<SNNode> initialNodes)
simulationContainer
- The container the SocialGraph is to be included insNConfiguration
- The configuration object of the concrete social network of interestinitialNodes
- The nodes the SocialGraph is initialized withpublic static SocialGraph createSocialGraph(SimulationContainer simulationContainer, SNConfiguration sNConfiguration, int numberOfNodes)
simulationContainer
- The container the SocialGraph is to be included insNConfiguration
- The configuration object of the concrete social network of interestnumberOfNodes
- The number of nodes the SocialGraph is initialized withpublic static TopologyManipulationScheme generateSNTopologyManipulationScheme(java.lang.String scheme, java.util.HashMap<java.lang.String,java.lang.Object> parameters)
scheme
- The qualifier of the TopologyManipulationScheme that is to be instantiatedparameters
- The parameters the TopologyManipulationScheme is to be initialized withpublic static EdgeWeightManipulationScheme generateSNEdgeWeightMapping(java.lang.String scheme, java.util.HashMap<java.lang.String,java.lang.Object> parameters)
scheme
- The qualifier of the EdgeWeightManipulationScheme that is to be instantiatedparameters
- The parameters the EdgeWeightManipulationScheme is to be initialized withpublic static SNEdge createEdge(SNNode source, SNNode target, double weight, SocialGraph.EDGEMEDIUM edgemedium) throws java.lang.IllegalArgumentException
source
- The node the edge is directed fromtarget
- The node the edge is directed toweight
- The weight of the edgeedgemedium
- The medium that is to be instantiatedjava.lang.IllegalArgumentException
- Will be thrown when the medium is not implementedpublic static SNEdge createEdge(SNNode source, SNNode target, double weight, SocialGraph.EDGEMEDIUM edgemedium, java.lang.String label) throws java.lang.IllegalArgumentException
source
- The node the edge is directed fromtarget
- The node the edge is directed toweight
- The weight of the edgeedgemedium
- The medium that is to be instantiatedlabel
- The label the new edge will getjava.lang.IllegalArgumentException
- Will be thrown when the medium is not implemented