OpenAPI 1.0

com.aquafold.openapi.type
Interface AQBigIntegerFactory


public interface AQBigIntegerFactory

This interface provides manipulation and validation functionality for BigInteger data type.

An instance of this interface is available via aqua.type.bigInteger alias.


Method Summary
 boolean isEqual(Object a, Object b)
          Checks if two values are equal.
 boolean isGreater(Object a, Object b)
          Checks if the parameter value a is greater then the parameter value b.
 boolean isGreaterOrEqual(Object a, Object b)
          Checks if the parameter value a is greater or equal to the parameter value b.
 boolean isInRange(Object value, Object min, Object max)
          Checks if the value is within a specified range, inclusive.
 boolean isLess(Object a, Object b)
          Checks if the parameter value a is less then the parameter value b.
 boolean isLessOrEqual(Object a, Object b)
          Checks if the parameter value a is less or equal to the parameter value b.
 boolean isValid(String value)
          Interprets a specified value as a BigInteger (using default platform locale).
 BigInteger parse(Object value)
          Creates a BigInteger instance assuming default platform locale.
 BigInteger parse(String value, String pattern)
          Creates a BigInteger instance using a specified pattern and locale.
 BigInteger parse(String value, String pattern, String locale)
          Interprets a specified value as a BigInteger using a specified pattern and locale.
 

Method Detail

parse

BigInteger parse(Object value)
Creates a BigInteger instance assuming default platform locale. Depending on the type of its argument, this method tries to make the most precise conversion.

If conversion is successful, the method returns the resulting BigInteger object, otherwise it throws an exception.

Parameters:
value - The value to be converted.
Returns:
A BigInteger object.
Throws:
Exception - If the parameter is invalid.

parse

BigInteger parse(String value,
                 String pattern)
Creates a BigInteger instance using a specified pattern and locale.

If conversion is successful, the method returns the resulting BigInteger object, otherwise it throws an exception.

Parameters:
value - The value to be converted.
pattern - The pattern used to validate the value against or null to use the default for the Locale. Please see DecimalFormatSymbols
Returns:
An AQBigInteger object.
Throws:
Exception - If the parameter is invalid.

parse

BigInteger parse(String value,
                 String pattern,
                 String locale)
Interprets a specified value as a BigInteger using a specified pattern and locale.

If conversion is successful, the method returns the resulting BigInteger object, otherwise it throws an exception.

Parameters:
value - The value to be converted.
pattern - The pattern used to validate the value against or null to use the default for the Locale. Please see DecimalFormatSymbols
locale - The locale to use for the format, system default if null. Please see Locale.
Returns:
An AQBigInteger object.
Throws:
Exception - If the parameter is invalid.

isInRange

boolean isInRange(Object value,
                  Object min,
                  Object max)
Checks if the value is within a specified range, inclusive.

Parameters:
value - The value specified.
min - The start of the range.
max - The end of the range.
Returns:
True, if the value is with in range.
Throws:
Exception - If any of parameters cannot be converted to BigInteger.

isLess

boolean isLess(Object a,
               Object b)
Checks if the parameter value a is less then the parameter value b.

Parameters:
a - The specified value.
b - The value to be compared.
Returns:
True if the parameter value a is less, and not inclusive of the parameter value of b.
Throws:
Exception - If any of parameters cannot be converted to BigInteger.

isLessOrEqual

boolean isLessOrEqual(Object a,
                      Object b)
Checks if the parameter value a is less or equal to the parameter value b.

Parameters:
a - The specified value.
b - The value to be compared.
Returns:
True if the parameter value a is less or equal to the parameter value of b.
Throws:
Exception - If any of parameters cannot be converted to BigInteger.

isGreater

boolean isGreater(Object a,
                  Object b)
Checks if the parameter value a is greater then the parameter value b.

Parameters:
a - The specified value.
b - The value to be compared.
Returns:
True if the parameter value a is greater, and not inclusive of the parameter value of b.
Throws:
Exception - If any of parameters cannot be converted to BigInteger.

isGreaterOrEqual

boolean isGreaterOrEqual(Object a,
                         Object b)
Checks if the parameter value a is greater or equal to the parameter value b.

Parameters:
a - The specified value.
b - The value to be compared.
Returns:
True if the parameter value a is greater or equal to the parameter value of b.
Throws:
Exception - If any of parameters cannot be converted to BigInteger.

isEqual

boolean isEqual(Object a,
                Object b)
Checks if two values are equal.

param a The specified value.

Parameters:
b - The value to be compared.
Returns:
True if the parameter value a is equal to the parameter value of b.
Throws:
Exception - If any of the parameters cannot be converted to BigInteger.

isValid

boolean isValid(String value)
Interprets a specified value as a BigInteger (using default platform locale).

Parameters:
value - The specified value.
Returns:
True, if the value can be converted to a big integer value.

OpenAPI 1.0


Copyright © 2010 AquaFold, Inc. All Rights Reserved. Use is subject to license terms.