Package tigase.kernel

Class DefaultTypesConverter

    • Constructor Detail

      • DefaultTypesConverter

        public DefaultTypesConverter()
    • Method Detail

      • unescape

        public static String unescape​(String input)
      • convert

        public <T> T convert​(Object value,
                             Class<T> expectedType)
        Converts value to expected type.
        Specified by:
        convert in interface TypesConverter
        Type Parameters:
        T - expected type.
        Parameters:
        value - value to be converted.
        expectedType - class of expected type.
        Returns:
        converted value.
      • convert

        public <T> T convert​(Object value,
                             Type type)
      • customConversion

        protected <T> T customConversion​(Object value,
                                         Class<T> expectedType,
                                         Type genericType)
      • toString

        public String toString​(Object value)
        Converts object to String.
        Specified by:
        toString in interface TypesConverter
        Parameters:
        value - object to convert.
        Returns:
        text representation of value.