Package org.infinispan.functional.impl
Class Params
- java.lang.Object
-
- org.infinispan.functional.impl.Params
-
@Experimental public final class Params extends Object
Internal class that encapsulates collection of parameters used to tweak functional map operations.Internally, parameters are stored in an array which is indexed by a parameter's
Param.id()All parameters have default values which are stored in a static array field in
Paramsclass, which are used to as base collection when adding or overriding parameters.- Since:
- 8.0
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Paramsadd(Param<?> p)ParamsaddAll(Params ps)ParamsaddAll(Param<?>... ps)Adds all parameters and returns a new parameter collection.booleancontainsAll(Param<?>... ps)Checks whether all the parameters passed in are already present in the current parameters.static Paramscreate()static Paramsfrom(Param<?>... ps)static ParamsfromFlagsBitSet(long flagsBitSet)<T> Param<T>get(int index)Retrieve a param given its identifier.static ParamsreadObject(ObjectInput input)longtoFlagsBitSet()Bridging method between flags and params, provided for efficient checks.StringtoString()static voidwriteObject(ObjectOutput output, Params params)
-
-
-
Method Detail
-
containsAll
public boolean containsAll(Param<?>... ps)
Checks whether all the parameters passed in are already present in the current parameters. This method can be used to optimise the decision on whether the parameters collection needs updating at all.
-
addAll
public Params addAll(Param<?>... ps)
Adds all parameters and returns a new parameter collection.
-
get
public <T> Param<T> get(int index)
Retrieve a param given its identifier. Callers are expected to know the exact type of parameter that will be returned. Such assumption is possible because as indicated inParamimplementations will only come from Infinispan itself.
-
toFlagsBitSet
public long toFlagsBitSet()
Bridging method between flags and params, provided for efficient checks.
-
fromFlagsBitSet
public static Params fromFlagsBitSet(long flagsBitSet)
-
create
public static Params create()
-
writeObject
public static void writeObject(ObjectOutput output, Params params) throws IOException
- Throws:
IOException
-
readObject
public static Params readObject(ObjectInput input) throws IOException
- Throws:
IOException
-
-