Class EntryValidator


public class EntryValidator extends Object
A validator for storing EntryData. It can be used to validate whether a SectionNode contains the required entries. This validation process will return an EntryContainer for accessing entry values.
See Also:
  • Method Details

    • builder

      public static EntryValidator.EntryValidatorBuilder builder()
      A builder to be used for creating an EntryValidator.
    • getEntryData

      public List<EntryData<?>> getEntryData()
      An unmodifiable list containing all EntryData of this validator.
    • validate

      public @Nullable EntryContainer validate(SectionNode sectionNode)
      Validates a node using this entry validator.
      sectionNode - The node to validate.
      A pair containing a map of handled nodes and a list of unhandled nodes (if this validator permits unhandled nodes) The returned map uses the matched entry data's key as a key and uses a pair containing the entry data and matching node Will return null if the provided node couldn't be validated.