Class NumberSeries

    • Constructor Summary

      Constructors 
      Constructor Description
      NumberSeries​(java.lang.String key, long value, int type)
      Deprecated.
      NumberSeries​(java.lang.String key, long value, int type, java.lang.String template)
      Creates a new number series value with the given key, value and type.
      NumberSeries​(java.lang.String key, java.lang.String formattedValue, int type)
      Deprecated.
      NumberSeries​(java.lang.String key, java.lang.String formattedValue, int type, java.lang.String template)
      Creates a new number series value with the given key, formatted value and type.
    • Method Summary

      All Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      protected java.lang.String applyPatternIfExists​(java.lang.String formattedNumber)  
      long getCurrentNumber()
      Returns the long representation this value.
      java.lang.String getCurrentValue()
      Deprecated.
      since ages - usegetFormatted(int) instead
      java.lang.String getFormatted​(int digits)
      Returns a formatted version of this value.
      java.lang.String getKey()
      The sequence key.
      java.lang.String getTemplate()
      The sequence template.
      int getType()
      The sequence type.
      protected java.lang.String replaceSpecialCharacters​(java.lang.String template, java.lang.String formattedNumber)  
      void setCurrentValue​(java.lang.String value)
      Deprecated.
      since ages - has no function
      void setKey​(java.lang.String key)
      Deprecated.
      since ages - has no function
      void setTemplate​(java.lang.String template)
      Deprecated.
      since ages - has no function
      void setType​(int type)
      Deprecated.
      since ages - has no function
      • Methods inherited from class java.lang.Object

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

      • LOG

        public static org.apache.log4j.Logger LOG
    • Constructor Detail

      • NumberSeries

        @Deprecated(since="5.0",
                    forRemoval=false)
        public NumberSeries​(java.lang.String key,
                            java.lang.String formattedValue,
                            int type)
        Deprecated.
        Creates a new number series value with the given key, formatted value and type.
        Parameters:
        key - the number series key
        formattedValue - a formatted value
        type - the sequence type see NumberGenerator.NumberSeriesConstants.TYPES
        Throws:
        java.lang.NumberFormatException - if the formatted value could not be parsed while calculating its long representation
      • NumberSeries

        public NumberSeries​(java.lang.String key,
                            java.lang.String formattedValue,
                            int type,
                            java.lang.String template)
        Creates a new number series value with the given key, formatted value and type.
        Parameters:
        key - the number series key
        formattedValue - a formatted value
        type - the sequence type see NumberGenerator.NumberSeriesConstants.TYPES
        template - the template to be applied on generated number
        Throws:
        java.lang.NumberFormatException - if the formatted value could not be parsed while calculating its long representation
      • NumberSeries

        @Deprecated(since="5.0",
                    forRemoval=false)
        public NumberSeries​(java.lang.String key,
                            long value,
                            int type)
        Deprecated.
        Creates a new number series value with the given key, value and type.
        Parameters:
        key - the key of the number series value
        value - the long value
        type - the series type
      • NumberSeries

        public NumberSeries​(java.lang.String key,
                            long value,
                            int type,
                            java.lang.String template)
        Creates a new number series value with the given key, value and type.
        Parameters:
        key - the key of the number series value
        value - the long value
        type - the series type
        template - the template to be used with generated number
    • Method Detail

      • getCurrentNumber

        public long getCurrentNumber()
        Returns the long representation this value.
      • getCurrentValue

        @Deprecated(since="ages",
                    forRemoval=false)
        public java.lang.String getCurrentValue()
        Deprecated.
        since ages - usegetFormatted(int) instead
        The formatted value.
      • getFormatted

        public java.lang.String getFormatted​(int digits)
        Returns a formatted version of this value. The result text contains at least the number of specified characters. If the underlying number does not fill it completely zeros are prepended.
        Parameters:
        digits - the number of digits to fill; if < 0 no leading zeros are prepended
      • applyPatternIfExists

        protected java.lang.String applyPatternIfExists​(java.lang.String formattedNumber)
      • replaceSpecialCharacters

        protected java.lang.String replaceSpecialCharacters​(java.lang.String template,
                                                            java.lang.String formattedNumber)
      • getTemplate

        public java.lang.String getTemplate()
        The sequence template.
      • getKey

        public java.lang.String getKey()
        The sequence key.
      • setTemplate

        @Deprecated(since="ages",
                    forRemoval=false)
        public void setTemplate​(java.lang.String template)
        Deprecated.
        since ages - has no function
      • setCurrentValue

        @Deprecated(since="ages",
                    forRemoval=false)
        public void setCurrentValue​(java.lang.String value)
        Deprecated.
        since ages - has no function
      • setKey

        @Deprecated(since="ages",
                    forRemoval=false)
        public void setKey​(java.lang.String key)
        Deprecated.
        since ages - has no function
      • setType

        @Deprecated(since="ages",
                    forRemoval=false)
        public void setType​(int type)
        Deprecated.
        since ages - has no function