Package org.jacop.fz
Class Tables
java.lang.Object
org.jacop.fz.Tables
This class contains information about all variables, including
the variables which are used by search.
- Version:
- 4.9
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) HashMap
<Integer, BooleanVar> (package private) int
(package private) int
(package private) int
(package private) ArrayList
<OutputArrayAnnotation> (package private) Store
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
It adds an float parameter.void
addFloatArray
(String ident, double[] array) void
addFloatVariable
(String ident, FloatVar var) It adds a variable with a given identity to the storage.void
It adds an int parameter.void
addIntArray
(String ident, int[] array) It stores an int array.void
It adds an output array annotation.void
It adds an output variable.void
addSearchArray
(Var[] v) It adds a search array.void
addSearchFloatArray
(Var[] v) It adds a search array.void
It adds a search variable.void
addSearchSetArray
(Var[] v) It adds an array of search set variables.void
It adds a search set variable.void
addSearchVar
(Var v) It adds a search variable.void
It adds a set of the given identity.void
addSetArray
(String ident, IntDomain[] array) It adds the set array to the storage.void
addSetVariable
(String ident, SetVar var) It adds the set variable of the given identity.void
addSetVariableArray
(String ident, SetVar[] array) It stores the array of the set variables with the specified identity.void
addVariable
(String ident, IntVar var) It adds a variable with a given identity to the storage.void
addVariableArray
(String ident, IntVar[] array) It adds a variable array to the storage.void
addVariableFloatArray
(String ident, FloatVar[] array) It adds a float variable array to the storage.checkFloat
(String ident) It returns an Double parameter of a given identity.It returns an Integer parameter of a given identity.(package private) IntVar
getConstant
(int c) getConstantBoolean
(int c) double
It returns an float parameter of a given identity.double[]
getFloatArray
(String ident) It obtains the int array of the given unique identity.getFloatConstant
(double c) getFloatVariable
(String ident) It returns the variable of the given identity.int
It returns an int parameter of a given identity.int[]
getIntArray
(String ident) It obtains the int array of the given unique identity.int
int
int
It returns the set of the given identity.getSetArray
(String ident) It returns the set array of the given id.getSetVariable
(String ident) It returns the set variable of the given identity.SetVar[]
getSetVariableArray
(String ident) It returns the array of set variables of the given identity.getVariable
(String ident) It returns the variable of the given identity.IntVar[]
getVariableArray
(String ident) It returns the variable array of the given identity.FloatVar[]
getVariableFloatArray
(String ident) It returns the float variable array of the given identity.boolean
It checks whether a variable is output variable.(package private) void
void
setNumberBoolVariables
(int n) void
setNumberFloatVariables
(int n) void
setNumberOfAllVariables
(int nb, int ns, int nf) void
setNumberSetVariables
(int n) toString()
-
Field Details
-
store
Store store -
constantTable
-
constantTableBoolean
HashMap<Integer,BooleanVar> constantTableBoolean -
constantFloatTable
-
intTable
-
floatTable
-
intArrayTable
-
floatArrayTable
-
setTable
-
setArrayTable
-
variableTable
-
variableArrayTable
-
variableFloatTable
-
variableFloatArrayTable
-
setVariableTable
-
setVariableArrayTable
-
outputVariables
-
outputArray
ArrayList<OutputArrayAnnotation> outputArray -
defaultSearchVariables
-
defaultSearchFloatVariables
-
defaultSearchArrays
-
defaultSearchFloatArrays
-
defaultSearchSetVariables
-
defaultSearchSetArrays
-
aliasTable
-
numberBoolVariables
int numberBoolVariables -
numberFloatVariables
int numberFloatVariables -
numberSetVariables
int numberSetVariables
-
-
Constructor Details
-
Tables
public Tables()It constructs the storage object to store different objects, like int, array of ints, sets, ... . -
Tables
-
-
Method Details
-
getConstant
-
getConstantBoolean
-
getFloatConstant
-
addAlias
-
getAlias
-
removeAliasFromSearch
void removeAliasFromSearch() -
addInt
It adds an int parameter.- Parameters:
ident
- the identity of the added int parameter.val
- the value of the parameter.
-
getInt
It returns an int parameter of a given identity.- Parameters:
ident
- the identify of the parameter.- Returns:
- the int value of the specified parameter.
-
checkInt
It returns an Integer parameter of a given identity.- Parameters:
ident
- the identify of the parameter.- Returns:
- the int value of the specified parameter.
-
addFloat
It adds an float parameter.- Parameters:
ident
- the identity of the added int parameter.val
- the value of the parameter.
-
getFloat
It returns an float parameter of a given identity.- Parameters:
ident
- the identify of the parameter.- Returns:
- the double value of the specified parameter.
-
checkFloat
It returns an Double parameter of a given identity.- Parameters:
ident
- the identify of the parameter.- Returns:
- the Double value of the specified parameter.
-
addIntArray
It stores an int array.- Parameters:
ident
- the identity of the stored array.array
- the array being stored.
-
getIntArray
It obtains the int array of the given unique identity.- Parameters:
ident
- the identity of the required array.- Returns:
- the int array with the specified identity.
-
addSet
It adds a set of the given identity.- Parameters:
ident
- the identity of the set being added.val
- the set being added.
-
getSet
It returns the set of the given identity.- Parameters:
ident
- the identity of the searched set.- Returns:
- the set of the given identity.
-
addSetArray
It adds the set array to the storage.- Parameters:
ident
- the identity of the added set array.array
- the array being added.
-
getSetArray
It returns the set array of the given id.- Parameters:
ident
- the unique id of the looked for set array.- Returns:
- the set array of the given identity.
-
addFloatArray
-
getFloatArray
It obtains the int array of the given unique identity.- Parameters:
ident
- the identity of the required array.- Returns:
- the int array with the specified identity.
-
addVariable
It adds a variable with a given identity to the storage.- Parameters:
ident
- the identity of the added variable.var
- the variable being added.
-
getVariable
It returns the variable of the given identity.- Parameters:
ident
- the identity of the returned variable.- Returns:
- the variable of the given identity.
-
addFloatVariable
It adds a variable with a given identity to the storage.- Parameters:
ident
- the identity of the added variable.var
- the variable being added.
-
getFloatVariable
It returns the variable of the given identity.- Parameters:
ident
- the identity of the returned variable.- Returns:
- the variable of the given identity.
-
addVariableArray
It adds a variable array to the storage.- Parameters:
ident
- the identity of the added variable array.array
- the array of variables being added.
-
getVariableArray
It returns the variable array of the given identity.- Parameters:
ident
- the identity of the returned variable array.- Returns:
- the variable array of the given identity.
-
addVariableFloatArray
It adds a float variable array to the storage.- Parameters:
ident
- the identity of the added variable array.array
- the array of variables being added.
-
getVariableFloatArray
It returns the float variable array of the given identity.- Parameters:
ident
- the identity of the returned variable array.- Returns:
- the variable array of the given identity.
-
addSetVariable
It adds the set variable of the given identity.- Parameters:
ident
- the identity of the added set variable.var
- the set variable being added.
-
getSetVariable
It returns the set variable of the given identity.- Parameters:
ident
- the identity of the returned set variable.- Returns:
- the set variable of the given identity.
-
addSetVariableArray
It stores the array of the set variables with the specified identity.- Parameters:
ident
- the identity of the stored array of set variables.array
- the array of set variables being added.
-
getSetVariableArray
It returns the array of set variables of the given identity.- Parameters:
ident
- the identity of the returned array of set variables.- Returns:
- the array of set variables with the given identity.
-
addOutVar
It adds an output variable.- Parameters:
v
- the output variable being added.
-
isOutput
It checks whether a variable is output variable.- Parameters:
v
- the variable to be checked.- Returns:
- true if variable is output, false otherwise
-
addOutArray
It adds an output array annotation.- Parameters:
v
- the output array annotation being added.
-
addSearchVar
It adds a search variable.- Parameters:
v
- the search variable being added.
-
addSearchFloatVar
It adds a search variable.- Parameters:
v
- the search variable being added.
-
addSearchArray
It adds a search array.- Parameters:
v
- the search array being added.
-
addSearchFloatArray
It adds a search array.- Parameters:
v
- the search array being added.
-
addSearchSetVar
It adds a search set variable.- Parameters:
v
- the set search variable being added.
-
addSearchSetArray
It adds an array of search set variables.- Parameters:
v
- array of set variables being added
-
setNumberOfAllVariables
public void setNumberOfAllVariables(int nb, int ns, int nf) -
setNumberBoolVariables
public void setNumberBoolVariables(int n) -
getNumberBoolVariables
public int getNumberBoolVariables() -
setNumberFloatVariables
public void setNumberFloatVariables(int n) -
getNumberFloatVariables
public int getNumberFloatVariables() -
setNumberSetVariables
public void setNumberSetVariables(int n) -
getNumberSetVariables
public int getNumberSetVariables() -
toString
-