Constructor and Description |
---|
ProbabilisticCondition(double probability) |
Modifier and Type | Method and Description |
---|---|
Condition |
deepClone()
Deep clone this condition
|
int |
fetch(Membrane membrane,
int tryTimes)
fetch objects from membrane
|
double |
getProbability() |
int |
satisfy(Membrane membrane)
check if condition satisfy the situation in membrane.
|
void |
setProbability(double probability) |
java.lang.String |
toString() |
void |
withdrawFetch(Membrane membrane,
int times)
If some conditions in one rule cannot fetch the objects then the conditions
which have fetched the objects they need withdraw the objects they have
fetched.
|
public double getProbability()
public void setProbability(double probability)
public int satisfy(Membrane membrane)
Condition
public int fetch(Membrane membrane, int tryTimes)
Condition
public void withdrawFetch(Membrane membrane, int times)
Condition
withdrawFetch
in interface Condition
membrane
- the membrane current condition withdraw objects totimes
- withdraw fetch timespublic Condition deepClone()
Condition
public java.lang.String toString()
toString
in class java.lang.Object