Class JPrimitiveType
java.lang.Object
org.exolab.javasource.JType
org.exolab.javasource.JPrimitiveType
JType sub-class for java primitives.
- Since:
- 1.1
- Version:
- $Revision: 5951 $ $Date: 2006-04-25 16:09:10 -0600 (Tue, 25 Apr 2006) $
- Author:
- Ralf Joachim
-
Field Summary
Fields inherited from class JType
BOOLEAN, BYTE, CHAR, DOUBLE, FLOAT, INT, LONG, SHORTModifier and TypeFieldDescriptionstatic final JPrimitiveTypeJType for a boolean (Boolean).static final JPrimitiveTypeJType instance for a byte (Byte).static final JPrimitiveTypeJType instance for a char (Char).static final JPrimitiveTypeJType instance for a double (Double).static final JPrimitiveTypeJType instance for a float (Float).static final JPrimitiveTypeJType instance for a int (Integer).static final JPrimitiveTypeJType instance for a long (Long).static final JPrimitiveTypeJType instance for a short (Short). -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedJPrimitiveType(String name, String wrapperName) Creates a new JPrimitiveType for a primitive with the given name and wrapper name. -
Method Summary
Modifier and TypeMethodDescriptionReturn the name of the wrapper object for a primitive type, null for non-primitive types.toString()
Returns the String representation of this JType.Methods inherited from class JType
getLocalName, getName, isArray, isPrimitive, setNameModifier and TypeMethodDescriptionfinal StringReturns the unqualified Java type name (i.e.final StringgetName()Returns the qualified Java type name.final booleanisArray()Returns true if this type represents an Array.final booleanReturns true if this type represents a Java primitive type.protected voidSets the qualified name of this type.
-
Constructor Details
-
JPrimitiveType
Creates a new JPrimitiveType for a primitive with the given name and wrapper name. This constructor is protected so it can only be used by the primitives defined at JType.- Parameters:
name- The name of the type.wrapperName- The name of the wrapper Object type for this primitive type.
-
-
Method Details
-
getWrapperName
Return the name of the wrapper object for a primitive type, null for non-primitive types.- Returns:
- The name of the wrapper object for a primitive type, null for non-primitive types.
-
toString
-