com.hazelcast.config
Class MaxSizeConfig
java.lang.Object
com.hazelcast.config.MaxSizeConfig
- All Implemented Interfaces:
- DataSerializable, Serializable
- Direct Known Subclasses:
- MaxSizeConfigReadOnly
public class MaxSizeConfig
- extends Object
- implements DataSerializable, Serializable
Configuration for map's capacity.
You can set a limit for number of entries or total memory cost of entries.
- See Also:
- Serialized Form
DEFAULT_MAX_SIZE
public static final int DEFAULT_MAX_SIZE
- Default maximum size of map.
- See Also:
- Constant Field Values
MaxSizeConfig
public MaxSizeConfig()
MaxSizeConfig
public MaxSizeConfig(int size,
MaxSizeConfig.MaxSizePolicy maxSizePolicy)
MaxSizeConfig
public MaxSizeConfig(MaxSizeConfig config)
getAsReadOnly
public MaxSizeConfigReadOnly getAsReadOnly()
getSize
public int getSize()
setSize
public MaxSizeConfig setSize(int size)
getMaxSizePolicy
public MaxSizeConfig.MaxSizePolicy getMaxSizePolicy()
setMaxSizePolicy
public MaxSizeConfig setMaxSizePolicy(MaxSizeConfig.MaxSizePolicy maxSizePolicy)
writeData
public void writeData(ObjectDataOutput out)
throws IOException
- Description copied from interface:
DataSerializable
- Writes object fields to output stream
- Specified by:
writeData
in interface DataSerializable
- Parameters:
out
- output
- Throws:
IOException
readData
public void readData(ObjectDataInput in)
throws IOException
- Description copied from interface:
DataSerializable
- Reads fields from the input stream
- Specified by:
readData
in interface DataSerializable
- Parameters:
in
- input
- Throws:
IOException
toString
public String toString()
- Overrides:
toString
in class Object
Copyright © 2015 Hazelcast, Inc.. All Rights Reserved.