Package com.hazelcast.config
Class BitmapIndexOptions
- java.lang.Object
-
- com.hazelcast.config.BitmapIndexOptions
-
- All Implemented Interfaces:
DataSerializable
,IdentifiedDataSerializable
public class BitmapIndexOptions extends java.lang.Object implements IdentifiedDataSerializable
Configures indexing options specific to bitmap indexes.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
BitmapIndexOptions.UniqueKeyTransformation
Defines an assortment of transformations which can be applied tounique key
values.
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
DEFAULT_UNIQUE_KEY
The default forunique key
.static BitmapIndexOptions.UniqueKeyTransformation
DEFAULT_UNIQUE_KEY_TRANSFORMATION
The default forunique key transformation
.
-
Constructor Summary
Constructors Constructor Description BitmapIndexOptions()
Constructs a new bitmap index options instance with all options set to default values.BitmapIndexOptions(BitmapIndexOptions bitmapIndexOptions)
Constructs a new bitmap index options instance by copying the passed bitmap index options.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object o)
int
getClassId()
Returns type identifier for this class.int
getFactoryId()
Returns DataSerializableFactory factory ID for this class.java.lang.String
getUniqueKey()
Returns the unique key attribute configured in this index config.BitmapIndexOptions.UniqueKeyTransformation
getUniqueKeyTransformation()
Returns the unique key transformation configured in this index.int
hashCode()
void
readData(ObjectDataInput in)
Reads fields from the input streamBitmapIndexOptions
setUniqueKey(java.lang.String uniqueKey)
Sets unique key attribute in this index config.BitmapIndexOptions
setUniqueKeyTransformation(BitmapIndexOptions.UniqueKeyTransformation uniqueKeyTransformation)
Sets unique key transformation in this index config.java.lang.String
toString()
void
writeData(ObjectDataOutput out)
Writes object fields to output stream
-
-
-
Field Detail
-
DEFAULT_UNIQUE_KEY
public static final java.lang.String DEFAULT_UNIQUE_KEY
The default forunique key
.
-
DEFAULT_UNIQUE_KEY_TRANSFORMATION
public static final BitmapIndexOptions.UniqueKeyTransformation DEFAULT_UNIQUE_KEY_TRANSFORMATION
The default forunique key transformation
.
-
-
Constructor Detail
-
BitmapIndexOptions
public BitmapIndexOptions()
Constructs a new bitmap index options instance with all options set to default values.
-
BitmapIndexOptions
public BitmapIndexOptions(BitmapIndexOptions bitmapIndexOptions)
Constructs a new bitmap index options instance by copying the passed bitmap index options.
-
-
Method Detail
-
getUniqueKey
public java.lang.String getUniqueKey()
Returns the unique key attribute configured in this index config. Defaults to__key
. The unique key attribute is used as a source of values which uniquely identify each entry being inserted into an index.- Returns:
- the configured unique key attribute.
-
setUniqueKey
public BitmapIndexOptions setUniqueKey(@Nonnull java.lang.String uniqueKey)
Sets unique key attribute in this index config.- Parameters:
uniqueKey
- a unique key attribute to configure.
-
getUniqueKeyTransformation
public BitmapIndexOptions.UniqueKeyTransformation getUniqueKeyTransformation()
Returns the unique key transformation configured in this index. Defaults toOBJECT
. The transformation is applied to every value extracted fromunique key attribue
.- Returns:
- the configured unique key transformation.
-
setUniqueKeyTransformation
public BitmapIndexOptions setUniqueKeyTransformation(@Nonnull BitmapIndexOptions.UniqueKeyTransformation uniqueKeyTransformation)
Sets unique key transformation in this index config.- Parameters:
uniqueKeyTransformation
- a unique key transformation to configure.
-
writeData
public void writeData(ObjectDataOutput out) throws java.io.IOException
Description copied from interface:DataSerializable
Writes object fields to output stream- Specified by:
writeData
in interfaceDataSerializable
- Parameters:
out
- output- Throws:
java.io.IOException
- if an I/O error occurs. In particular, anIOException
may be thrown if the output stream has been closed.
-
readData
public void readData(ObjectDataInput in) throws java.io.IOException
Description copied from interface:DataSerializable
Reads fields from the input stream- Specified by:
readData
in interfaceDataSerializable
- Parameters:
in
- input- Throws:
java.io.IOException
- if an I/O error occurs. In particular, anIOException
may be thrown if the input stream has been closed.
-
getFactoryId
public int getFactoryId()
Description copied from interface:IdentifiedDataSerializable
Returns DataSerializableFactory factory ID for this class.- Specified by:
getFactoryId
in interfaceIdentifiedDataSerializable
- Returns:
- factory ID
-
getClassId
public int getClassId()
Description copied from interface:IdentifiedDataSerializable
Returns type identifier for this class. It should be unique per DataSerializableFactory.- Specified by:
getClassId
in interfaceIdentifiedDataSerializable
- Returns:
- type ID
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-