Class IntegerOption


  • public class IntegerOption
    extends Option<java.lang.Integer>
    Integer option
    See Also:
    Option
    • Constructor Summary

      Constructors 
      Constructor Description
      IntegerOption​(java.lang.String key, java.lang.Integer defaultValue)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Integer fromString​(java.lang.String value)
      Option values are serialized to strings using toString() call.
      java.lang.String toString​(java.lang.Integer value)
      Serialize option value to string
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • IntegerOption

        public IntegerOption​(@NonNls @NotNull
                             java.lang.String key,
                             @NotNull
                             java.lang.Integer defaultValue)
        Parameters:
        key - name of the parameter. Used in equals and hashCode
        defaultValue - default value for this option, if not specified
    • Method Detail

      • fromString

        public java.lang.Integer fromString​(@NotNull
                                            java.lang.String value)
        Description copied from class: Option
        Option values are serialized to strings using toString() call. To restore option value from string this method is used
        Specified by:
        fromString in class Option<java.lang.Integer>
        Parameters:
        value - serialized option value Object.toString() method is used for serialization)
        Returns:
        deserialized value
      • toString

        public java.lang.String toString​(@NotNull
                                         java.lang.Integer value)
        Description copied from class: Option
        Serialize option value to string
        Specified by:
        toString in class Option<java.lang.Integer>
        Parameters:
        value - value to serialize
        Returns:
        serialized option value