Class JDOPrimitive
- java.lang.Object
-
- net.ontopia.persistence.query.jdo.JDOPrimitive
-
- All Implemented Interfaces:
JDOValueIF
public class JDOPrimitive extends Object implements JDOValueIF
INTERNAL: JDOQL value: primitive. Class used to reference primitive values. These can be boolean, byte, short, integer, long, float or double. [FIXME: In addition the classes BigInteger and BigDouble are supported.] Syntax: the same as their Java syntax representations.
-
-
Field Summary
Fields Modifier and Type Field Description static intBIGDECIMALstatic intBIGINTEGERstatic intBOOLEANstatic intBYTEstatic intDOUBLEstatic intFLOATstatic intINTEGERstatic intLONGstatic intSHORTprotected Objectvalueprotected intvalue_type-
Fields inherited from interface net.ontopia.persistence.query.jdo.JDOValueIF
COLLECTION, FIELD, FUNCTION, NATIVE_VALUE, NULL, OBJECT, PARAMETER, PRIMITIVE, STRING, VARIABLE
-
-
Constructor Summary
Constructors Constructor Description JDOPrimitive(int value_type, Object value)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)intgetPrimitiveType()INTERNAL: Returns the type of primitive as indicated by one of the constants in theJDOPrimitiveinterface.intgetType()INTERNAL: Returns the type of JDO value indicated by one of the constants in theJDOValueIFinterface.ObjectgetValue()INTERNAL: Returns the primitive value.ClassgetValueType()inthashCode()booleanisNumeric()INTERNAL: Returns true if the primitive is of numeric type.StringtoString()voidvisit(JDOVisitorIF visitor)INTERNAL: Allows the value to be visited.
-
-
-
Field Detail
-
BOOLEAN
public static final int BOOLEAN
- See Also:
- Constant Field Values
-
BYTE
public static final int BYTE
- See Also:
- Constant Field Values
-
SHORT
public static final int SHORT
- See Also:
- Constant Field Values
-
INTEGER
public static final int INTEGER
- See Also:
- Constant Field Values
-
LONG
public static final int LONG
- See Also:
- Constant Field Values
-
FLOAT
public static final int FLOAT
- See Also:
- Constant Field Values
-
DOUBLE
public static final int DOUBLE
- See Also:
- Constant Field Values
-
BIGDECIMAL
public static final int BIGDECIMAL
- See Also:
- Constant Field Values
-
BIGINTEGER
public static final int BIGINTEGER
- See Also:
- Constant Field Values
-
value_type
protected int value_type
-
value
protected Object value
-
-
Constructor Detail
-
JDOPrimitive
public JDOPrimitive(int value_type, Object value)
-
-
Method Detail
-
getType
public int getType()
Description copied from interface:JDOValueIFINTERNAL: Returns the type of JDO value indicated by one of the constants in theJDOValueIFinterface.- Specified by:
getTypein interfaceJDOValueIF
-
getValueType
public Class getValueType()
-
getPrimitiveType
public int getPrimitiveType()
INTERNAL: Returns the type of primitive as indicated by one of the constants in theJDOPrimitiveinterface.
-
getValue
public Object getValue()
INTERNAL: Returns the primitive value. An object wrapper is represented using its primitive wrapper class.
-
isNumeric
public boolean isNumeric()
INTERNAL: Returns true if the primitive is of numeric type.
-
visit
public void visit(JDOVisitorIF visitor)
Description copied from interface:JDOValueIFINTERNAL: Allows the value to be visited. This method is used for retrieval of nested data in expressions.- Specified by:
visitin interfaceJDOValueIF
-
-