Package com.hazelcast.partition.strategy
Class StringPartitioningStrategy
- java.lang.Object
-
- com.hazelcast.partition.strategy.StringPartitioningStrategy
-
- All Implemented Interfaces:
PartitioningStrategy
,java.io.Serializable
public class StringPartitioningStrategy extends java.lang.Object implements PartitioningStrategy
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static StringPartitioningStrategy
INSTANCE
-
Constructor Summary
Constructors Constructor Description StringPartitioningStrategy()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static java.lang.String
getBaseName(java.lang.String name)
java.lang.Object
getPartitionKey(java.lang.Object key)
Returns the key object that will be used by Hazelcast to specify the partition.static java.lang.String
getPartitionKey(java.lang.String key)
-
-
-
Field Detail
-
INSTANCE
public static final StringPartitioningStrategy INSTANCE
-
-
Method Detail
-
getPartitionKey
public java.lang.Object getPartitionKey(java.lang.Object key)
Description copied from interface:PartitioningStrategy
Returns the key object that will be used by Hazelcast to specify the partition.- Specified by:
getPartitionKey
in interfacePartitioningStrategy
- Parameters:
key
- actual key object used by Hazelcast to specify the partition- Returns:
- the partition key object, or null to fallback to the default partition calculation
-
getBaseName
public static java.lang.String getBaseName(java.lang.String name)
-
getPartitionKey
public static java.lang.String getPartitionKey(java.lang.String key)
-
-