|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface JavaModel
A JavaModel instance bundles a number of JavaType instances and provides methods to retrieve JavaType instance by their name. A type name must be unique must be unique within a JavaModel instance. If the JavaType represents a class or an interface its type name is the fully qualified name. The model supports multiple classes or interfaces having the same fully qualified name by different JavaModel instances.
Method Summary | |
---|---|
JavaModel[] |
getChildren()
Returns a collection of child JavaModel instances in the form of an array. |
java.io.InputStream |
getInputStreamForResource(java.lang.String resourceName)
Finds a resource with a given name. |
JavaType |
getJavaType(java.lang.Class clazz)
The method returns the JavaType instance for the type name of the specified class object. |
JavaType |
getJavaType(java.lang.String name)
The method returns the JavaType instance for the specified type name. |
JDOModel |
getJDOModel()
Returns the corresponding JDOModel instance. |
JavaModel |
getParent()
Returns the parent JavaModel instance of this JavaModel. |
void |
setJDOModel(JDOModel jdoModel)
Sets the corresponding JDOModel instance. |
void |
setParent(JavaModel parent)
Set the parent JavaModel for this JavaModel. |
Method Detail |
---|
JavaType getJavaType(java.lang.String name)
null
if this model instance does not
know a type with the specified name.
name
- the name of the type
null
if not present in this model instance.JavaType getJavaType(java.lang.Class clazz)
getJavaType(clazz.getName())
. The major difference
between this method and getJavaType taking a type name is that this
method is supposed to return a non-null value. The
specified class object describes an existing type.
- Parameters:
clazz
- the Class instance representing the type
- Returns:
- a JavaType instance for the name of the specified class
object.
java.io.InputStream getInputStreamForResource(java.lang.String resourceName)
null
if no resource with this name is found or if the
caller doesn't have adequate privileges to get the resource.
resourceName
- the resource name
null
if the resource could not be found or if the caller doesn't have
adequate privileges to get the resource.JavaModel getParent()
void setParent(JavaModel parent) throws ModelException
parent
- the parent JavaModel
ModelException
- if impossibleJavaModel[] getChildren()
JDOModel getJDOModel()
void setJDOModel(JDOModel jdoModel) throws ModelException
jdoModel
- the JDOModel instance
ModelException
- if impossible
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |