Package org.spongepowered.api.fluid
Interface FluidStackSnapshot
-
- All Superinterfaces:
CopyableDataHolder,DataHolder,DataHolder.Immutable<FluidStackSnapshot>,DataSerializable,SerializableDataHolder,SerializableDataHolder.Immutable<FluidStackSnapshot>,ValueContainer
public interface FluidStackSnapshot extends SerializableDataHolder.Immutable<FluidStackSnapshot>
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceFluidStackSnapshot.Builder-
Nested classes/interfaces inherited from interface org.spongepowered.api.data.DataHolder
DataHolder.Immutable<I extends DataHolder.Immutable<I>>, DataHolder.Mutable
-
Nested classes/interfaces inherited from interface org.spongepowered.api.data.SerializableDataHolder
SerializableDataHolder.Immutable<I extends SerializableDataHolder.Immutable<I>>, SerializableDataHolder.Mutable
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description static FluidStackSnapshot.Builderbuilder()Creates a newFluidStackSnapshot.Builderto build a newFluidStackSnapshot.FluidStackcreateStack()Creates a newFluidStackbased on this snapshot.FluidTypefluid()Gets theFluidTypeof this snapshot.intvolume()Gets the volume of this snapshot.-
Methods inherited from interface org.spongepowered.api.data.DataHolder.Immutable
mergeWith, mergeWith, transform, transform, with, with, with, without, without, without
-
Methods inherited from interface org.spongepowered.api.data.persistence.DataSerializable
contentVersion, toContainer
-
Methods inherited from interface org.spongepowered.api.data.SerializableDataHolder
validateRawData
-
Methods inherited from interface org.spongepowered.api.data.SerializableDataHolder.Immutable
copy, withRawData
-
-
-
-
Method Detail
-
builder
static FluidStackSnapshot.Builder builder()
Creates a newFluidStackSnapshot.Builderto build a newFluidStackSnapshot.- Returns:
- The new builder
-
volume
int volume()
Gets the volume of this snapshot.Note that the volume is measured in "milli buckets", otherwise read as
mB. The scaling is as follows: 1 bucket = 1000mB, whereas 1 block usually equals 1000mB.- Returns:
- The volume
-
createStack
FluidStack createStack()
Creates a newFluidStackbased on this snapshot.- Returns:
- The newly created stack
-
-