org.deidentifier.arx

## Class DataType.ARXInteger

- java.lang.Object
- - org.deidentifier.arx.DataType<java.lang.Long>
  - - org.deidentifier.arx.DataType.ARXInteger

All Implemented Interfaces:
  java.io.Serializable, java.util.Comparator<java.lang.Long>, DataType.DataTypeWithFormat, DataType.DataTypeWithRatioScale<java.lang.Long>

Enclosing class:
  DataType<T>

    public static class DataType.ARXInteger
    extends DataType<java.lang.Long>
    implements DataType.DataTypeWithFormat, DataType.DataTypeWithRatioScale<java.lang.Long>

Base class for numeric types.

Author:
  Fabian Prasser
See Also:
  Serialized Form

### Nested Class Summary

### Nested classes/interfaces inherited from class org.deidentifier.arx.DataType

`DataType.ARXDate, DataType.ARXDecimal, DataType.ARXInteger, DataType.ARXOrderedString, DataType.ARXString, DataType.DataTypeDescription<T>, DataType.DataTypeWithFormat, DataType.DataTypeWithRatioScale<T>`

### Field Summary

### Fields inherited from class org.deidentifier.arx.DataType

`ANY_VALUE, DATE, DECIMAL, INTEGER, NULL_VALUE, ORDERED_STRING, STRING`

### Method Summary

All Methods Instance Methods Concrete Methods
`java.lang.Long` `add(java.lang.Long augend, java.lang.Long addend)` Add
`DataType<java.lang.Long>` `clone()`
`int` `compare(java.lang.Long t1, java.lang.Long t2)` Compare.
`int` `compare(java.lang.String s1, java.lang.String s2)` Compares two values.
`java.lang.Long` `divide(java.lang.Long dividend, java.lang.Long divisor)` Divide
`java.lang.String` `divide(java.lang.String dividend, java.lang.String divisor)` Divide
`boolean` `equals(java.lang.Object obj)`
`java.lang.String` `format(java.lang.Long s)` Converts a value into a string.
`java.lang.Long` `fromDouble(java.lang.Double d)` Converts a double into a value.
`DataType.DataTypeDescription<java.lang.Long>` `getDescription()` Returns a description of the data type.
`java.lang.String` `getFormat()` Format
`java.util.Locale` `getLocale()` Returns the locale of the format.
`java.lang.Long` `getMaximum()` Maximum
`java.lang.Long` `getMinimum()` Minimum
`int` `hashCode()`
`boolean` `isValid(java.lang.String s)` Checks whether the given string conforms to the data type's format.
`java.lang.Long` `multiply(java.lang.Long multiplicand, double multiplicator)` Multiply
`java.lang.Long` `multiply(java.lang.Long multiplicand, int multiplicator)` Multiply
`java.lang.Long` `multiply(java.lang.Long multiplicand, java.lang.Long multiplicator)` Multiply
`java.lang.String` `multiply(java.lang.String multiplicand, java.lang.String multiplicator)` Multiply
`java.lang.Long` `parse(java.lang.String s)` Converts a string into a value.
`double` `ratio(java.lang.Long dividend, java.lang.Long divisor)` Divide
`java.lang.Long` `subtract(java.lang.Long minuend, java.lang.Long subtrahend)` Subtract
`java.lang.Double` `toDouble(java.lang.Long val)` Converts a double into a value.
`java.lang.String` `toString()`

### Methods inherited from class org.deidentifier.arx.DataType

`createAggregate, createDate, createDate, createDecimal, createDecimal, createInteger, createInteger, createOrderedString, createOrderedString, createOrderedString, isAny, isNull, list, list`

### Methods inherited from class java.lang.Object

`getClass, notify, notifyAll, wait, wait, wait`

### Methods inherited from interface java.util.Comparator

`comparing, comparing, comparingDouble, comparingInt, comparingLong, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong`

### Method Detail

#### add

    public java.lang.Long add(java.lang.Long augend,
                              java.lang.Long addend)

Description copied from interface: `DataType.DataTypeWithRatioScale`
Add

Specified by:
  `add` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### clone

    public DataType<java.lang.Long> clone()

Specified by:
  `clone` in class `DataType<java.lang.Long>`

#### compare

    public int compare(java.lang.Long t1,
                       java.lang.Long t2)

Description copied from class: `DataType`
Compare.

Specified by:
  `compare` in interface `java.util.Comparator<java.lang.Long>`
Specified by:
  `compare` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Specified by:
  `compare` in class `DataType<java.lang.Long>`

#### compare

    public int compare(java.lang.String s1,
                       java.lang.String s2)
                throws java.lang.NumberFormatException

Description copied from class: `DataType`
Compares two values. The result is 0 if both values are equal, less than 0 if the first value is less than the second argument, and greater than 0 if the first value is greater than the second argument.

Specified by:
  `compare` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Specified by:
  `compare` in class `DataType<java.lang.Long>`
Returns:
Throws:
  `java.lang.NumberFormatException`

#### divide

    public java.lang.Long divide(java.lang.Long dividend,
                                 java.lang.Long divisor)

Description copied from interface: `DataType.DataTypeWithRatioScale`
Divide

Specified by:
  `divide` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### divide

    public java.lang.String divide(java.lang.String dividend,
                                   java.lang.String divisor)

Description copied from interface: `DataType.DataTypeWithRatioScale`
Divide

Specified by:
  `divide` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### equals

    public boolean equals(java.lang.Object obj)

Specified by:
  `equals` in interface `java.util.Comparator<java.lang.Long>`
Specified by:
  `equals` in class `DataType<java.lang.Long>`

#### format

    public java.lang.String format(java.lang.Long s)

Description copied from class: `DataType`
Converts a value into a string.

Specified by:
  `format` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Specified by:
  `format` in class `DataType<java.lang.Long>`
Returns:

#### fromDouble

    public java.lang.Long fromDouble(java.lang.Double d)

Description copied from interface: `DataType.DataTypeWithRatioScale`
Converts a double into a value.

Specified by:
  `fromDouble` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### getDescription

    public DataType.DataTypeDescription<java.lang.Long> getDescription()

Description copied from class: `DataType`
Returns a description of the data type.

Specified by:
  `getDescription` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Specified by:
  `getDescription` in class `DataType<java.lang.Long>`
Returns:

#### getFormat

    public java.lang.String getFormat()

Description copied from interface: `DataType.DataTypeWithFormat`
Format

Specified by:
  `getFormat` in interface `DataType.DataTypeWithFormat`
Returns:

#### getLocale

    public java.util.Locale getLocale()

Returns the locale of the format.

Specified by:
  `getLocale` in interface `DataType.DataTypeWithFormat`
Returns:

#### getMaximum

    public java.lang.Long getMaximum()

Description copied from interface: `DataType.DataTypeWithRatioScale`
Maximum

Specified by:
  `getMaximum` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### getMinimum

    public java.lang.Long getMinimum()

Description copied from interface: `DataType.DataTypeWithRatioScale`
Minimum

Specified by:
  `getMinimum` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### hashCode

    public int hashCode()

Specified by:
  `hashCode` in class `DataType<java.lang.Long>`

#### isValid

    public boolean isValid(java.lang.String s)

Description copied from class: `DataType`
Checks whether the given string conforms to the data type's format.

Specified by:
  `isValid` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Specified by:
  `isValid` in class `DataType<java.lang.Long>`
Returns:

#### multiply

    public java.lang.Long multiply(java.lang.Long multiplicand,
                                   double multiplicator)

Description copied from interface: `DataType.DataTypeWithRatioScale`
Multiply

Specified by:
  `multiply` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### multiply

    public java.lang.Long multiply(java.lang.Long multiplicand,
                                   int multiplicator)

Description copied from interface: `DataType.DataTypeWithRatioScale`
Multiply

Specified by:
  `multiply` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### multiply

    public java.lang.Long multiply(java.lang.Long multiplicand,
                                   java.lang.Long multiplicator)

Description copied from interface: `DataType.DataTypeWithRatioScale`
Multiply

Specified by:
  `multiply` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### multiply

    public java.lang.String multiply(java.lang.String multiplicand,
                                     java.lang.String multiplicator)

Description copied from interface: `DataType.DataTypeWithRatioScale`
Multiply

Specified by:
  `multiply` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### parse

    public java.lang.Long parse(java.lang.String s)

Description copied from class: `DataType`
Converts a string into a value.

Specified by:
  `parse` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Specified by:
  `parse` in class `DataType<java.lang.Long>`
Returns:

#### ratio

    public double ratio(java.lang.Long dividend,
                        java.lang.Long divisor)

Description copied from interface: `DataType.DataTypeWithRatioScale`
Divide

Specified by:
  `ratio` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### subtract

    public java.lang.Long subtract(java.lang.Long minuend,
                                   java.lang.Long subtrahend)

Description copied from interface: `DataType.DataTypeWithRatioScale`
Subtract

Specified by:
  `subtract` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### toDouble

    public java.lang.Double toDouble(java.lang.Long val)

Description copied from interface: `DataType.DataTypeWithRatioScale`
Converts a double into a value.

Specified by:
  `toDouble` in interface `DataType.DataTypeWithRatioScale<java.lang.Long>`
Returns:

#### toString

    public java.lang.String toString()

Overrides:
  `toString` in class `java.lang.Object`