javax.rad.model.datatype
Class LongDataType

java.lang.Object
  extended by javax.rad.model.datatype.DataType
      extended by javax.rad.model.datatype.LongDataType
All Implemented Interfaces:
Serializable, Cloneable, IDataType

public class LongDataType
extends DataType

A LongDataType is the data type class for a BIGINT column.

See Also:
Serialized Form

Field Summary
static int TYPE_IDENTIFIER
          the type identifier.
 
Constructor Summary
LongDataType()
          Constructs a default BigDecimal data type with undefined precision and scale.
LongDataType(ICellEditor pCellEditor)
          Constructs a default BigDecimal data type with undefined precision, scale and the given cell editor.
 
Method Summary
 LongDataType clone()
          Clone an IDataType.
 Long convertAndCheckToTypeClass(Object pObject)
          Converts the oObject to an Object which is an instance of the class which is handled by IDataType.
 String convertToString(Object pObject)
          Converts the oObject into a String which represents the Object.
 Object convertToTypeClass(Object pObject)
          Converts the oObject to an Object which is an instance of the class which is handled by IDataType.
 String getNumberFormat()
          Returns the current NumberFormat.
 int getSize()
          Returns the size of the DataType.
 Class getTypeClass()
          Returns the class of the Object's handled by IDataType.
 int getTypeIdentifier()
          Gets the data type identifier.
 boolean isSigned()
          Returns if the BigDecimalDataType is signed.
 void setNumberFormat(String pNumberFormat)
          Sets the current NumberFormat.
 void setSigned(boolean pSigned)
          Sets if the BigDecimalDataType is signed.
 
Methods inherited from class javax.rad.model.datatype.DataType
compareTo, getCellEditor, getCellRenderer, getDefaultCellEditor, getDefaultCellRenderer, hashCode, prepareValue, setCellEditor, setCellRenderer, setDefaultCellEditor, setDefaultCellRenderer, setSize
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TYPE_IDENTIFIER

public static final int TYPE_IDENTIFIER
the type identifier.

See Also:
Constant Field Values
Constructor Detail

LongDataType

public LongDataType()
Constructs a default BigDecimal data type with undefined precision and scale.


LongDataType

public LongDataType(ICellEditor pCellEditor)
Constructs a default BigDecimal data type with undefined precision, scale and the given cell editor.

Parameters:
pCellEditor - the cell editor
Method Detail

getTypeIdentifier

public int getTypeIdentifier()
Gets the data type identifier.

Returns:
a unique type identifier

getTypeClass

public Class getTypeClass()
Returns the class of the Object's handled by IDataType.

Returns:
the class of the Object's handled by IDataType.

convertToString

public String convertToString(Object pObject)
Converts the oObject into a String which represents the Object.

Parameters:
pObject - the source Object to convert
Returns:
the String representation of the source Object

convertToTypeClass

public Object convertToTypeClass(Object pObject)
                          throws ModelException
Converts the oObject to an Object which is an instance of the class which is handled by IDataType.

Parameters:
pObject - the source Object to convert
Returns:
the converted Object that is instance of the class which is handled by IDataType.
Throws:
ModelException - if the class/type of oObject is not supported

convertAndCheckToTypeClass

public Long convertAndCheckToTypeClass(Object pObject)
                                throws ModelException
Converts the oObject to an Object which is an instance of the class which is handled by IDataType. The resulting Object is also checked against the type attributes like size, precision,...

Parameters:
pObject - the source Object to convert
Returns:
the converted Object that is instance of the class which is handled by IDataType.
Throws:
ModelException - if the Object is outside the limits of the DataType attributes

getSize

public int getSize()
Returns the size of the DataType.

Overrides:
getSize in class DataType
Returns:
the size of the DataType.

clone

public LongDataType clone()
Clone an IDataType.

Specified by:
clone in interface IDataType
Overrides:
clone in class DataType
Returns:
a clone of this IDataType
See Also:
Object.clone()

isSigned

public boolean isSigned()
Returns if the BigDecimalDataType is signed.

Returns:
if the BigDecimalDataType is signed.

setSigned

public void setSigned(boolean pSigned)
Sets if the BigDecimalDataType is signed.

Parameters:
pSigned - the signed value of the BigDecimalDataType.

getNumberFormat

public String getNumberFormat()
Returns the current NumberFormat.

Returns:
the current NumberFormat.

setNumberFormat

public void setNumberFormat(String pNumberFormat)
Sets the current NumberFormat.

Parameters:
pNumberFormat - the new NumberFormat.


Copyright © 2009 SIB Visions GmbH. All Rights Reserved.