Class MatrixDictRemove
java.lang.Object
com.singularsys.jep.functions.PostfixMathCommand
com.singularsys.jep.functions.BinaryFunction
com.singularsys.jep.misc.dictionary.Remove
com.singularsys.extensions.matrix.dictionary.MatrixDictRemove
- All Implemented Interfaces:
PostfixMathCommandI,Serializable
Removes entries with matching key from the map.
This version uses
The function returns either the value or the removed key
or
FieldI.eq(Object, Object)
to tests keys for equality so
it can also be used with the com.singularsys.extensions.field
package.
Allows:
map = {'x':2, 'y':3};
remove(map, 'x');
Remove.nullValue if the key is missing the key has no value.- Since:
- Jep 4.1
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.singularsys.jep.functions.BinaryFunction
BinaryFunction.BiFunctionWithException<T> -
Field Summary
FieldsFields inherited from class com.singularsys.jep.functions.PostfixMathCommand
curNumberOfParameters, description, name, NaN, numberOfParameters -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class com.singularsys.jep.functions.BinaryFunction
instanceOf, instanceOf, instanceOf, instanceOf, runMethods inherited from class com.singularsys.jep.functions.PostfixMathCommand
asArray, asBool, asDouble, asInt, asLong, asStrictInt, asString, asType, checkNumberOfParameters, getDescription, getDescription, getDescriptionWithType, getName, getNumberOfParameters, setCurNumberOfParameters, setDescription, setName, toString, toString
-
Field Details
-
mf
-
-
Constructor Details
-
MatrixDictRemove
Constructor- Parameters:
nullValue- , value returned when a key has no value or if no key exists.
-
-
Method Details
-
equals
Description copied from class:RemoveTest if key equals k. Default implementation useskey.equals(k)- Overrides:
equalsin classRemove- Parameters:
key- key to testk- key to test- Returns:
- true if parameters are equal
- Throws:
EvaluationException
-