Class PartitionParameterNode
- java.lang.Object
-
- org.apache.ignite.internal.sql.optimizer.affinity.PartitionSingleNode
-
- org.apache.ignite.internal.sql.optimizer.affinity.PartitionParameterNode
-
- All Implemented Interfaces:
PartitionNode
public class PartitionParameterNode extends PartitionSingleNode
Node with partition which should be extracted from argument.
-
-
Field Summary
-
Fields inherited from class org.apache.ignite.internal.sql.optimizer.affinity.PartitionSingleNode
tbl
-
-
Constructor Summary
Constructors Constructor Description PartitionParameterNode(PartitionTable tbl, PartitionResolver partRslvr, int idx, int type, PartitionParameterType clientType)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IntegerapplySingle(PartitionClientContext cliCtx, Object... args)Apply arguments and get single partition.PartitionParameterTypeclientType()booleanconstant()StringtoString()inttype()intvalue()-
Methods inherited from class org.apache.ignite.internal.sql.optimizer.affinity.PartitionSingleNode
apply, cacheName, equals, hashCode, joinGroup, table
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.apache.ignite.internal.sql.optimizer.affinity.PartitionNode
optimize
-
-
-
-
Constructor Detail
-
PartitionParameterNode
public PartitionParameterNode(PartitionTable tbl, PartitionResolver partRslvr, int idx, int type, PartitionParameterType clientType)
Constructor.- Parameters:
tbl- Table descriptor.partRslvr- Partition resolver.idx- Parameter index.type- Parameter data type.clientType- Mapped parameter type to be used by thin clients.
-
-
Method Detail
-
applySingle
public Integer applySingle(PartitionClientContext cliCtx, Object... args) throws IgniteCheckedException
Apply arguments and get single partition.- Specified by:
applySinglein classPartitionSingleNode- Parameters:
cliCtx- Client context.args- Arguments.- Returns:
- Partition or
nullif failed. - Throws:
IgniteCheckedException
-
constant
public boolean constant()
- Specified by:
constantin classPartitionSingleNode- Returns:
Trueif constant,falseif argument.
-
value
public int value()
- Specified by:
valuein classPartitionSingleNode- Returns:
- Partition for constant node, index for argument node.
-
type
public int type()
- Returns:
- Parameter data type.
-
clientType
public PartitionParameterType clientType()
- Returns:
- Client parameter type.
-
-