org.jfree.xml.generator.model

Class DescriptionModel


public class DescriptionModel
extends java.lang.Object

A model containing class descriptions.

Constructor Summary

DescriptionModel()
Creates a new class description model.

Method Summary

void
addClassDescription(ClassDescription cd)
Adds a class description to the model.
void
addIncludeComment(String source, Comments comments)
Adds an include comment.
void
addSource(String source)
Adds a source to the model description.
ClassDescription
get(Class key)
Returns a class description for the given class name.
ClassDescription
get(int index)
Returns a class description.
Comments
getIncludeComment(String source)
Returns the include comment for the specified source.
MappingModel
getMappingModel()
Returns the mapping model.
Comments
getModelComments()
Returns the model comments.
String[]
getSources()
Returns the sources for the model description.
void
prune()
Removes any class descriptions that are not fully defined.
void
removeClassDescription(ClassDescription cd)
Removes a class description from the model.
void
setModelComments(Comments modelComments)
Sets the model comments.
int
size()
Returns the number of classes in the model.

Constructor Details

DescriptionModel

public DescriptionModel()
Creates a new class description model.

Method Details

addClassDescription

public void addClassDescription(ClassDescription cd)
Adds a class description to the model.
Parameters:
cd - the class description.

addIncludeComment

public void addIncludeComment(String source,
                              Comments comments)
Adds an include comment.
Parameters:
source - the source.
comments - the comments.

addSource

public void addSource(String source)
Adds a source to the model description.
Parameters:
source - the source.

get

public ClassDescription get(Class key)
Returns a class description for the given class name.
Parameters:
key - the class name.
Returns:
the class description.

get

public ClassDescription get(int index)
Returns a class description.
Parameters:
index - the description index (zero-based).
Returns:
a class description.

getIncludeComment

public Comments getIncludeComment(String source)
Returns the include comment for the specified source.
Parameters:
source - the source.
Returns:
The include comment.

getMappingModel

public MappingModel getMappingModel()
Returns the mapping model.
Returns:
the mapping model.

getModelComments

public Comments getModelComments()
Returns the model comments.
Returns:
The model comments.

getSources

public String[] getSources()
Returns the sources for the model description.
Returns:
The sources.

prune

public void prune()
Removes any class descriptions that are not fully defined.

removeClassDescription

public void removeClassDescription(ClassDescription cd)
Removes a class description from the model.
Parameters:
cd - the class description.

setModelComments

public void setModelComments(Comments modelComments)
Sets the model comments.
Parameters:
modelComments - the model comments.

size

public int size()
Returns the number of classes in the model.
Returns:
the number of classes in the model.