org.exolab.javasource
Class JType
java.lang.Object
org.exolab.javasource.JType
public class JType
extends java.lang.Object
$Revision: 1.1.1.1 $ $Date: 2003/03/03 07:09:57 $
JType(String name) - Creates a new JType with the given name
|
protected void | changePackage(String newPackage) - Allows subtypes, such as JClass to alter the package to which
this JType belongs
|
JType | createArray() - Creates a JType Object representing an array of the current
JType.
|
JType | getComponentType() - If this JType is an array this method will returns the component type
of the array, otherwise null will be returned.
|
String | getLocalName()
|
String | getName()
|
boolean | isArray() - Checks to see if this JType represents an array.
|
boolean | isPrimitive() - Checks to see if this JType represents a primitive
|
String | toString() - Returns the String representation of this JType, which is
simply the name of this type.
|
Boolean
public static final JType Boolean
Byte
public static final JType Byte
Char
public static final JType Char
Double
public static final JType Double
Float
public static final JType Float
Int
public static final JType Int
Long
public static final JType Long
Short
public static final JType Short
JType
protected JType(String name)
Creates a new JType with the given name
changePackage
protected void changePackage(String newPackage)
Allows subtypes, such as JClass to alter the package to which
this JType belongs
newPackage
- the new package to which this JType belongs
Note: The package name cannot be changed on a primitive type.
createArray
public final JType createArray()
Creates a JType Object representing an array of the current
JType.
- the new JType which is represents an array.
getComponentType
public JType getComponentType()
If this JType is an array this method will returns the component type
of the array, otherwise null will be returned.
- the component JType if this JType is an array, otherwise null.
getLocalName
public String getLocalName()
getName
public String getName()
isArray
public final boolean isArray()
Checks to see if this JType represents an array.
- true if this JType represents an array, otherwise false
isPrimitive
public boolean isPrimitive()
Checks to see if this JType represents a primitive
- true if this JType represents a primitive, otherwise false
toString
public String toString()
Returns the String representation of this JType, which is
simply the name of this type.
- the String representation of this JType
Intalio Inc. (C) 1999-2003. All rights reserved http://www.intalio.com