Interface GuacamoleProperty<Type>

Type Parameters:
Type - The type this GuacamoleProperty will parse into.
All Known Implementing Classes:
BooleanGuacamoleProperty, ByteArrayProperty, EnumGuacamoleProperty, FileGuacamoleProperty, IntegerGuacamoleProperty, IPAddressListProperty, LongGuacamoleProperty, StringGuacamoleProperty, StringListProperty, TimeZoneGuacamoleProperty, URIGuacamoleProperty

public interface GuacamoleProperty<Type>
An abstract representation of a property in the guacamole.properties file, which parses into a specific type.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final Pattern
    A pattern which matches against the delimiters between values.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the name of the property in guacamole.properties that this GuacamoleProperty will parse.
    Parses the given string value into the type associated with this GuacamoleProperty.
    default Collection<Type>
    Parses the given string value into a Collection of values of the type associated with this GuacamoleProperty.
  • Field Details

    • DELIMITER_PATTERN

      static final Pattern DELIMITER_PATTERN
      A pattern which matches against the delimiters between values. This is currently simply a semicolon and any following whitespace. Parts of the input string which match this pattern will not be included in the parsed result.
  • Method Details

    • getName

      String getName()
      Returns the name of the property in guacamole.properties that this GuacamoleProperty will parse.
      Returns:
      The name of the property in guacamole.properties that this GuacamoleProperty will parse.
    • parseValue

      Type parseValue(String value) throws org.apache.guacamole.GuacamoleException
      Parses the given string value into the type associated with this GuacamoleProperty.
      Parameters:
      value - The string value to parse.
      Returns:
      The parsed value.
      Throws:
      org.apache.guacamole.GuacamoleException - If an error occurs while parsing the provided value.
    • parseValueCollection

      default Collection<Type> parseValueCollection(String value) throws org.apache.guacamole.GuacamoleException
      Parses the given string value into a Collection of values of the type associated with this GuacamoleProperty. The default implementation simply returns a list containing a single item as parsed by the parseValue method.
      Parameters:
      value - The string value to parse.
      Returns:
      A sorted Collection of the parsed values.
      Throws:
      org.apache.guacamole.GuacamoleException - If an error occurs while parsing the provided value.