Class ParsedProperty<T>

java.lang.Object
dev.prozilla.pine.common.property.ParsedProperty<T>
All Implemented Interfaces:
Property<T>, Functor<T>

public class ParsedProperty<T> extends Object implements Property<T>
A property whose value is determined using the value of a string property and a parser.
  • Constructor Details

  • Method Details

    • getValue

      public T getValue()
      Returns the parsed value, or null if the parsing failed.
      Specified by:
      getValue in interface Property<T>
      Returns:
      The parsed value, or null if the parsing failed.
    • toStringProperty

      public StringProperty toStringProperty()
      Returns the input property.
      Specified by:
      toStringProperty in interface Property<T>
      Returns:
      The input property.
    • inputProperty

      @NotNull public @NotNull StringProperty inputProperty()
      Returns the input property.
      Returns:
      The input property.
    • getParser

      @NotNull public @NotNull Parser<T> getParser()