Record Class StorageInfo
java.lang.Object
java.lang.Record
com.refinedmods.refinedstorage.common.api.storage.StorageInfo
@API(status=STABLE,
since="2.0.0-milestone.1.2")
public record StorageInfo(long stored, long capacity)
extends Record
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionStorageInfo(long stored, long capacity) Creates an instance of aStorageInforecord class. -
Method Summary
Modifier and TypeMethodDescriptionlongcapacity()Returns the value of thecapacityrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.static StorageInfolongstored()Returns the value of thestoredrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
UNKNOWN
-
-
Constructor Details
-
StorageInfo
public StorageInfo(long stored, long capacity) Creates an instance of aStorageInforecord class.- Parameters:
stored- the value for thestoredrecord componentcapacity- the value for thecapacityrecord component
-
-
Method Details
-
of
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
stored
public long stored()Returns the value of thestoredrecord component.- Returns:
- the value of the
storedrecord component
-
capacity
public long capacity()Returns the value of thecapacityrecord component.- Returns:
- the value of the
capacityrecord component
-