Interface ObjectNameEncoder

  • All Known Implementing Classes:
    ObjectNameEncoderAccessor.DefaultObjectNameEncoder

    public interface ObjectNameEncoder

    Defines methods that should be used to encode and decode values included within an ObjectName. It is necessary to encode the values used in the ObjectNames since they may contain illegal characters, such as colon (:), equals (=) and question mark (?).

    This class should only be used to encode the actual values within an ObjectName, as indicated in bold in the following example: domain:key1=value1,key2=value2.

    An instance of an ObjectNameEncoder should not be constructed directly, instead it is recommended that the ObjectNameEncoderAccessor is used instead.

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.lang.String decodeValue​(java.lang.String encodedValue)
      Decodes an ObjectName value that was encoded with the encodeValue(String) method.
      java.lang.String encodeValue​(java.lang.String value)
      Encodes the specified value so that it can be included within an ObjectName.
    • Method Detail

      • encodeValue

        java.lang.String encodeValue​(java.lang.String value)

        Encodes the specified value so that it can be included within an ObjectName.

        Parameters:
        value - The value to be encoded.
        Returns:
        The encoded value.
      • decodeValue

        java.lang.String decodeValue​(java.lang.String encodedValue)

        Decodes an ObjectName value that was encoded with the encodeValue(String) method.

        Parameters:
        encodedValue - The value to be decoded.
        Returns:
        The decoded value.