Interface IData

All Known Implementing Classes:
EnergyData, FluidData, FluidData.PlatformDependant, ItemData, ProgressData

public interface IData
A typed data for syncing complex data.

Register data types with ICommonRegistrar.dataType(IData.Type, StreamCodec)

For simple data, consider using raw NBT data instead, as it is easier to do and enough for most purpose.

See mcp.mobius.waila.api.data for built-in implementations.

  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static interface 
    IData.Type<D extends IData>
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static <D extends IData>
    IData.Type<D>
    Creates a data type.
    IData.Type<? extends IData>
    Returns the type of the data, should be a constant variable.
  • Method Details

    • createType

      static <D extends IData> IData.Type<D> createType(Identifier id)
      Creates a data type.

      Save the returned value to a static final variable.

      Parameters:
      id - the data id
    • type

      IData.Type<? extends IData> type()
      Returns the type of the data, should be a constant variable.
      See Also: