Class Configuration<T>

java.lang.Object
me.bristermitten.mittenlib.config.Configuration<T>
Type Parameters:
T - the type of the config

public class Configuration<T> extends Object
Represents a loadable configuration which will deserialize to an object of type Configuration
  • Constructor Details

    • Configuration

      public Configuration(String fileName, Class<T> type, @Nullable @Nullable DeserializationFunction<T> deserializeFunction)
      Create a new Configuration
      Parameters:
      fileName - the name of the file to load
      type - the type to deserialize to
      deserializeFunction - the function to use to deserialize the data
  • Method Details

    • getFileName

      public String getFileName()
      Returns:
      the name of the file to load
    • getType

      public Class<T> getType()
      Returns:
      the type to deserialize to
    • getDeserializeFunction

      @Nullable public @Nullable DeserializationFunction<T> getDeserializeFunction()
      Returns:
      the function to use to deserialize the data