Package com.hazelcast.memory
Class MemorySize
- java.lang.Object
-
- com.hazelcast.memory.Capacity
-
- com.hazelcast.memory.MemorySize
-
@Deprecated public final class MemorySize extends Capacity
Deprecated.Since 5.1,Capacity
should be used instead.MemorySize represents a memory size with given value and
.MemoryUnit
- Since:
- 3.4
- See Also:
MemoryUnit
,Capacity
-
-
Constructor Summary
Constructors Constructor Description MemorySize(long value)
Deprecated.MemorySize(long value, MemoryUnit unit)
Deprecated.
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static MemorySize
parse(java.lang.String value)
Deprecated.since 5.1, useCapacity.parse(String)
instead.static MemorySize
parse(java.lang.String value, MemoryUnit defaultUnit)
Deprecated.since 5.1, useCapacity.parse(String, MemoryUnit)
instead-
Methods inherited from class com.hazelcast.memory.Capacity
bytes, equals, getUnit, getValue, gigaBytes, hashCode, kiloBytes, megaBytes, of, toPrettyString, toPrettyString, toPrettyString, toString
-
-
-
-
Constructor Detail
-
MemorySize
public MemorySize(long value)
Deprecated.
-
MemorySize
public MemorySize(long value, MemoryUnit unit)
Deprecated.
-
-
Method Detail
-
parse
@Deprecated public static MemorySize parse(java.lang.String value)
Deprecated.since 5.1, useCapacity.parse(String)
instead.Parses string representation of a memory size value. Value may end with one of suffixes;- 'k' or 'K' for 'kilo',
- 'm' or 'M' for 'mega',
- 'g' or 'G' for 'giga'.
Default unit is bytes.
Examples: 12345, 12345m, 12345K, 123456G
-
parse
@Deprecated public static MemorySize parse(java.lang.String value, MemoryUnit defaultUnit)
Deprecated.since 5.1, useCapacity.parse(String, MemoryUnit)
insteadParses string representation of a memory size value. Value may end with one of suffixes;- 'k' or 'K' for 'kilo',
- 'm' or 'M' for 'mega',
- 'g' or 'G' for 'giga'.
Uses default unit if value does not contain unit information.
Examples: 12345, 12345m, 12345K, 123456G
-
-