Class JacksonJsonEnumHelper<E extends java.lang.Enum<E>>


  • public class JacksonJsonEnumHelper<E extends java.lang.Enum<E>>
    extends java.lang.Object
    • Constructor Summary

      Constructors 
      Constructor Description
      JacksonJsonEnumHelper​(java.lang.Class<E> enumType)  
      JacksonJsonEnumHelper​(java.lang.Class<E> enumType, boolean firstLetterCapitalized)  
      JacksonJsonEnumHelper​(java.lang.Class<E> enumType, boolean firstLetterCapitalized, boolean camelCased)  
      JacksonJsonEnumHelper​(java.lang.Class<E> enumType, boolean firstLetterCapitalized, boolean camelCased, boolean preserveUnderscores)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addEnum​(E e, java.lang.String name)
      Add an enum that has a specialized name that does not fit the standard naming conventions.
      E forValue​(java.lang.String value)  
      java.lang.String toString​(E e)
      Get the string used by the API for this enum.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • JacksonJsonEnumHelper

        public JacksonJsonEnumHelper​(java.lang.Class<E> enumType)
      • JacksonJsonEnumHelper

        public JacksonJsonEnumHelper​(java.lang.Class<E> enumType,
                                     boolean firstLetterCapitalized)
      • JacksonJsonEnumHelper

        public JacksonJsonEnumHelper​(java.lang.Class<E> enumType,
                                     boolean firstLetterCapitalized,
                                     boolean camelCased)
      • JacksonJsonEnumHelper

        public JacksonJsonEnumHelper​(java.lang.Class<E> enumType,
                                     boolean firstLetterCapitalized,
                                     boolean camelCased,
                                     boolean preserveUnderscores)
    • Method Detail

      • addEnum

        public void addEnum​(E e,
                            java.lang.String name)
        Add an enum that has a specialized name that does not fit the standard naming conventions.
        Parameters:
        e - the enum to add
        name - the name for the enum
      • forValue

        public E forValue​(java.lang.String value)
      • toString

        public java.lang.String toString​(E e)
        Get the string used by the API for this enum.
        Parameters:
        e - the enum value to get the API string for
        Returns:
        the string used by the API for this enum