Interface StringConverter

All Superinterfaces:
Function<Object,String>
All Known Subinterfaces:
StringConverter.WithArguments
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface StringConverter extends Function<Object,String>
Converts any kind of objects to strings.

Built-in argument converters use comma-separated operands in expressions processed by StringUtil.convert(String, IManagedContainer). Nested expression operands are evaluated before the enclosing converter is invoked. Boolean converters accept only trimmed, case-insensitive true and false values.

Since:
3.23
Author:
Eike Stepper
  • Field Details

    • PRODUCT_GROUP

      static final String PRODUCT_GROUP
      See Also:
    • IDENTITY

      static final StringConverter IDENTITY
    • CHARS

      static final StringConverter CHARS
    • SAFE

      static final StringConverter SAFE
    • HEX

      static final StringConverter HEX
      Since:
      3.28
    • BASE64

      static final StringConverter BASE64
      Since:
      3.28
    • UPPER

      static final StringConverter UPPER
    • LOWER

      static final StringConverter LOWER
    • EQUALS

      static final StringConverter EQUALS
      Compares two strings case-sensitively; surrounding whitespace on each operand is ignored.
      Since:
      3.31
    • EQUALS_IGNORE_CASE

      static final StringConverter EQUALS_IGNORE_CASE
      Compares two strings case-insensitively; surrounding whitespace on each operand is ignored. Its converter name is equals_ignore_case.
      Since:
      3.31
    • CONTAINS

      static final StringConverter CONTAINS
      Tests whether the first string contains the second string, with case-sensitive matching.
      Since:
      3.31
    • CONTAINS_IGNORE_CASE

      static final StringConverter CONTAINS_IGNORE_CASE
      Tests whether the first string contains the second string, ignoring case.
      Since:
      3.31
    • STARTS_WITH

      static final StringConverter STARTS_WITH
      Tests whether the first string starts with the second string, with case-sensitive matching.
      Since:
      3.31
    • ENDS_WITH

      static final StringConverter ENDS_WITH
      Tests whether the first string ends with the second string, with case-sensitive matching.
      Since:
      3.31
    • AND

      static final StringConverter AND
      Returns true when all two or more Boolean operands are true. Every nested operand is evaluated before this converter is invoked, so this operation does not short-circuit.
      Since:
      3.31
    • OR

      static final StringConverter OR
      Returns true when at least one of the two or more Boolean operands is true. Every nested operand is evaluated before this converter is invoked, so this operation does not short-circuit.
      Since:
      3.31
    • XOR

      static final StringConverter XOR
      Returns true when an odd number of the two or more Boolean operands are true.
      Since:
      3.31
    • NOT

      static final StringConverter NOT
      Negates one Boolean operand.
      Since:
      3.31
    • CAP

      static final StringConverter CAP
    • CAP_ALL

      static final StringConverter CAP_ALL
    • UNCAP

      static final StringConverter UNCAP
    • UNCAP_ALL

      static final StringConverter UNCAP_ALL
    • ESCAPE

      static final StringConverter ESCAPE
    • UNESCAPE

      static final StringConverter UNESCAPE
    • STRIP_HTML

      static final StringConverter STRIP_HTML
      Since:
      3.26
    • NET4J_USER_PATH

      static final StringConverter NET4J_USER_PATH
    • NET4J_STATE_PATH

      static final StringConverter NET4J_STATE_PATH
    • NET4J_CONFIG_PATH

      static final StringConverter NET4J_CONFIG_PATH
    • SYSTEM_PROPERTY

      static final StringConverter SYSTEM_PROPERTY
      Looks up an OMPlatform property by name. With one argument, it returns the property value or null if absent. The argument may also be propertyName,defaultValue; the first comma separates the property name and the complete remaining text is the default. That default is returned only when the property is absent, not when its value is empty. For example, $$$system_property(transport,tcp)$$$ returns tcp when transport is undefined.
      Since:
      3.31
    • PROPERTY_URI

      static final StringConverter PROPERTY_URI
  • Method Details