|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--cb.util.PetalObjectFactory
Create empty Petal objects with just some initial properties (the quid in particular) set up. The user can then add them to model, i.e. PetalFile object. Some objects are created by reading serialized templates from the templates directory. init() is called on them usually automagically when they're added to the model.
PetalFile
Constructor Summary | |
protected |
PetalObjectFactory()
|
Method Summary | |
AssocAttachView |
createAssocAttachView()
|
Association |
createAssociation(Class clazz1,
Class clazz2)
Create association without explicit name, it will have an invisible anonymous name. |
Association |
createAssociation(Class clazz,
UseCase caze)
|
Association |
createAssociation(java.lang.String name,
Class clazz1,
Class clazz2)
Create Association between two classes. |
Association |
createAssociation(java.lang.String name,
Class clazz,
UseCase caze)
|
Association |
createAssociation(java.lang.String name,
UseCase case1,
UseCase case2)
Create Association between two use cases. |
Association |
createAssociation(UseCase case1,
UseCase case2)
Create association without explicit name, it will have an invisible anonymous name. |
AssociationViewNew |
createAssociationView(Association assoc)
|
AssociationViewNew |
createAssociationView(Association assoc,
boolean show_label)
Creates view for given association. |
AttachView |
createAttachView()
|
Class |
createClass(java.lang.String name)
Creates empty class object with just the name and the quid set. |
ClassAttribute |
createClassAttribute(java.lang.String name,
java.lang.String type)
Creates new class attribute (aka field) |
ClassUtility |
createClassUtility(java.lang.String name)
Creates empty utility class object with just the name and the quid set. |
ClassView |
createClassView(Class clazz)
Creates class view for given class and sets the qualified name and quidu for the referenced class accordingly. |
InheritanceRelationship |
createInheritanceRelationship(Inheritable clazz,
Inheritable super_class)
Create InheritanceRelationship between two classes, this method is called by Class.addSuperClass(). |
java.util.List |
createInheritViews(Inheritable clazz)
|
Class |
createInterface(java.lang.String name)
Just like createClass() except that it sets the stereotype to "Interface". |
ItemLabel |
createItemLabel(java.lang.String text)
|
LogicalCategory |
createLogicalCategory(java.lang.String name)
Creates empty class category (logical view). |
PetalFile |
createModel()
Creates empty model. |
NoteView |
createNoteView(java.lang.String text)
|
Operation |
createOperation(java.lang.String name,
java.lang.String result,
List params)
Creates new operation (aka method) |
RealizeRelationship |
createRealizeRelationship(Class clazz,
Class inter)
Create RealizeRelationship between class and an interface, called by Class.addImplementedInterface(). |
java.util.List |
createRealizeViews(Class clazz)
|
SegLabel |
createSegLabel(java.lang.String text)
|
UseCase |
createUseCase(java.lang.String name)
Creates use case object with just the name and the quid set. |
UseCaseCategory |
createUseCaseCategory(java.lang.String name)
Creates empty class category (use case view). |
UseCaseView |
createUseCaseView(UseCase caze)
Creates use case view for given class and sets the qualified name and quidu for the referenced class accordingly. |
UsesRelationship |
createUsesRelationship(Class clazz,
Class clazz2)
Create UsesRelationship between class and an interface, called by Class.addUsedClass(). |
java.util.List |
createUsesViews(Class clazz)
|
java.lang.String |
getAnonymousName()
|
static PetalObjectFactory |
getInstance()
|
protected static PetalNode |
getTemplate(java.lang.String name)
Read object from templates directory |
static void |
setInstance(PetalObjectFactory inst)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
protected PetalObjectFactory()
Method Detail |
public static PetalObjectFactory getInstance()
public static void setInstance(PetalObjectFactory inst)
protected static PetalNode getTemplate(java.lang.String name)
public PetalFile createModel()
public Class createClass(java.lang.String name)
ClassCategory.addToModel(cb.petal.Class)
public UseCase createUseCase(java.lang.String name)
UseCaseCategory.addToModel(UseCase)
public Class createInterface(java.lang.String name)
public ClassUtility createClassUtility(java.lang.String name)
ClassCategory.addToModel(cb.petal.Class)
public Operation createOperation(java.lang.String name, java.lang.String result, List params)
Class.addOperation(cb.petal.Operation)
public ClassAttribute createClassAttribute(java.lang.String name, java.lang.String type)
Class.addClassAttribute(cb.petal.ClassAttribute)
public UseCaseCategory createUseCaseCategory(java.lang.String name)
public LogicalCategory createLogicalCategory(java.lang.String name)
LogicalCategory.addToModel(cb.petal.LogicalCategory)
public InheritanceRelationship createInheritanceRelationship(Inheritable clazz, Inheritable super_class)
Inheritable.addSuperClassifier(cb.petal.Inheritable)
public RealizeRelationship createRealizeRelationship(Class clazz, Class inter)
Class.addImplementedInterface(cb.petal.Class)
public UsesRelationship createUsesRelationship(Class clazz, Class clazz2)
Class.addUsedClass(cb.petal.Class)
public final java.lang.String getAnonymousName()
public Association createAssociation(java.lang.String name, Class clazz1, Class clazz2)
public Association createAssociation(Class clazz1, Class clazz2)
public Association createAssociation(java.lang.String name, UseCase case1, UseCase case2)
public Association createAssociation(java.lang.String name, Class clazz, UseCase caze)
public Association createAssociation(Class clazz, UseCase caze)
public Association createAssociation(UseCase case1, UseCase case2)
public ClassView createClassView(Class clazz)
These properties/view objects will be set (if defined in given class): quidu, label, stereotype, QualifiedNameParameter
Diagram.addToView(ClassView)
public NoteView createNoteView(java.lang.String text)
public AttachView createAttachView()
public ItemLabel createItemLabel(java.lang.String text)
public SegLabel createSegLabel(java.lang.String text)
public AssocAttachView createAssocAttachView()
public java.util.List createInheritViews(Inheritable clazz)
ClassDiagram.addToView(cb.petal.InheritView)
public java.util.List createRealizeViews(Class clazz)
ClassDiagram.addToView(cb.petal.RealizeView)
public java.util.List createUsesViews(Class clazz)
ClassDiagram.addToView(cb.petal.UsesView)
public AssociationViewNew createAssociationView(Association assoc, boolean show_label)
show_label
- show association nameDiagram.addToView(cb.petal.ClassView)
public AssociationViewNew createAssociationView(Association assoc)
public UseCaseView createUseCaseView(UseCase caze)
UseCaseDiagram.addToView(UseCaseView)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |