|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectpeersim.dynamics.WireGraph
peersim.dynamics.WireByMethod
public class WireByMethod
Takes a Linkable
protocol and adds connections using an arbitrary
method.
No connections are removed.
The connections are added by an arbitrary method that can be specified
in the configuration.
The properties the method has to fulfill are the following
Graph
.java.util.Random
Graph
that is passed to
wire(peersim.graph.Graph)
.java.util.Random
then it is initialized with
CommonState.r
, the central source of randomness for the
simulator.WireWS
can be emulated by configuring
init.0 WireByMethod init.0.class GraphFactory init.0.method wireWS init.0.arg1 10 init.0.arg2 0.1 ...Note that the "class" parameter defaults to
GraphFactory
,
and "method" defaults to "wire".
Parameter Summary | |
---|---|
arg
The prefix for the configuration properties that describe parameters. |
|
class
The class that has the method we want to use. |
|
method
The name of the method for wiring the graph. |
Field Summary |
---|
Fields inherited from class peersim.dynamics.WireGraph |
---|
g, pid, undir |
Constructor Summary | |
---|---|
WireByMethod(java.lang.String prefix)
Loads configuration. |
Method Summary | |
---|---|
void |
wire(Graph g)
Invokes the method passing g to it. |
Methods inherited from class peersim.dynamics.WireGraph |
---|
execute |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Parameter Detail |
---|
arg
class
GraphFactory
.
method
wire
.
Constructor Detail |
---|
public WireByMethod(java.lang.String prefix)
WireByMethod
.
prefix
- the configuration prefix for this classMethod Detail |
---|
public void wire(Graph g)
wire
in class WireGraph
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |