Modifier and Type | Class and Description |
---|---|
class |
PositionResult.Target |
Constructor and Description |
---|
PositionResult() |
PositionResult(Tunnel.TunnelType move) |
Modifier and Type | Method and Description |
---|---|
void |
addDimension(java.lang.Long dimensions)
Add new fixed dimensions to an instance of
Dimensional . |
void |
addDimension(java.lang.String formulas)
Add new formula dimensions to an instance of dimension.
|
void |
addObjectResult(ObjectResult or) |
void |
addTarget(PositionResult.Target target) |
PositionResult |
deepClone()
Clone the name
|
int |
fetch(Membrane membrane,
int times)
fetch objects from membrane
|
void |
fix(java.util.Map<java.lang.String,java.lang.Object> mappedValues)
Fix all the dimension by calculating them using the mapped values
|
java.util.ArrayList<Dimension> |
getDimensions()
Get all the dimensions of an instance
|
int |
getDimensionSize()
Return the number of total dimensions
|
Tunnel.TunnelType |
getMove() |
java.lang.String |
getNameDim()
Get the name with dimensions.
|
java.util.ArrayList<PositionResult.Target> |
getTargets() |
boolean |
isFixed()
Check if all the dimensions are fixed
|
int |
satisfy(Membrane membrane)
check if condition satisfy the situation in membrane.
|
Tunnel |
selectTunnel(Membrane current)
Select which tunnel this result will go through
|
void |
setMove(Tunnel.TunnelType move) |
void |
setResult(Membrane membrane,
int times)
Set the result to target membrane
|
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.
|
addDimension, get, getName, predictPossibleValue, predictPossibleValueOfNeighbor, predictPossibleValueOfObjects, predictPossibleValueOfSubmembrane, setName
public PositionResult()
public PositionResult(Tunnel.TunnelType move)
public void addObjectResult(ObjectResult or)
public void addTarget(PositionResult.Target target)
public void setResult(Membrane membrane, int times)
Result
public PositionResult deepClone()
Name
public Tunnel.TunnelType getMove()
public void setMove(Tunnel.TunnelType move)
public java.util.ArrayList<PositionResult.Target> getTargets()
public java.lang.String toString()
toString
in class java.lang.Object
public void addDimension(java.lang.Long dimensions)
Dimensional
Dimensional
. For example,
a[1] have a dimension 1
and 1
should be added to a
.addDimension
in interface Dimensional
addDimension
in class BasicName
dimensions
- dimensionspublic void addDimension(java.lang.String formulas)
Dimensional
i+1
and i+1
should be added to a
.addDimension
in interface Dimensional
addDimension
in class BasicName
formulas
- dimensionspublic int getDimensionSize()
Dimensional
getDimensionSize
in interface Dimensional
getDimensionSize
in class BasicName
public java.util.ArrayList<Dimension> getDimensions()
Dimensional
getDimensions
in interface Dimensional
getDimensions
in class BasicName
public java.lang.String getNameDim()
Name
2
, then the return value is a[2]
.getNameDim
in interface Name
getNameDim
in class BasicName
public boolean isFixed()
Dimensional
isFixed
in interface Dimensional
isFixed
in class BasicName
true
if all the dimensions are fixed, and if
getDimensionSize()==0
return true
, else return
false
public void fix(java.util.Map<java.lang.String,java.lang.Object> mappedValues)
Dimensional
fix
in interface Dimensional
fix
in class BasicName
mappedValues
- mapped valuespublic int satisfy(Membrane membrane)
Condition
public int fetch(Membrane membrane, int times)
Condition
public void withdrawFetch(Membrane membrane, int times)
Condition
withdrawFetch
in interface Condition
membrane
- the membrane current condition withdraw objects totimes
- withdraw fetch timespublic Tunnel selectTunnel(Membrane current) throws TunnelNotExistException
Result
selectTunnel
in interface Result
current
- current membraneTunnelNotExistException
- if tunnel doesn't exist and cannot be created