Class MpHelper
java.lang.Object
pl.decerto.hyperon.runtime.helper.MpHelper
- Author:
- przemek hertel
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe number of columns in the database to record levels. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncopyDefinition(Parameter src) - copies all information but matrix - sets number of matrix rowscreateEntry(int levelCnt, String... columns) createEntry(String... cells) createEntry(LevelMapper mapper, String... columns) createEntry(Parameter p, String... columns) createInListPattern(int n) String[]ensureLength(String[] row, int length) String[]assumptions: - there are n cells in a row - n-1 cells contain a single value (normal) - the last nth cell contains (potentially) the value of the several levels (vararg)String[][]toDatabaseColumns(String[][] logicalCells) String[][]toDatabaseColumns(String[][] logicalCells, int max)
-
Field Details
-
MAX_LEVELS
public static final int MAX_LEVELSThe number of columns in the database to record levels.- See Also:
-
-
Constructor Details
-
MpHelper
public MpHelper()
-
-
Method Details
-
createEntry
-
createEntry
- Parameters:
levelCnt- number of all levels in parametercolumns- next chambers from the matrix row- Returns:
- MpParameterEntry object
-
createEntry
- Parameters:
mapper- maps master levels to slave levelscolumns- next chambers from the matrix row- Returns:
- MpParameterEntry object
-
createEntry
-
normalize
assumptions: - there are n cells in a row - n-1 cells contain a single value (normal) - the last nth cell contains (potentially) the value of the several levels (vararg)- Parameters:
cells- String object with cells value- Returns:
- separated from each other values of all levels
-
toDatabaseColumns
-
toDatabaseColumns
-
ensureLength
-
copyDefinition
- copies all information but matrix - sets number of matrix rows- Parameters:
src- Parameter object- Returns:
- Parameter object
-
createInListPattern
-
unify
-