public class Architecture extends Variable
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
ARCHITECTURE_TYPE |
Constructor and Description |
---|
Architecture(java.lang.String name) |
Modifier and Type | Method and Description |
---|---|
void |
addAllClasses(java.util.Set<Class> classes) |
void |
addAllInterfaces(java.util.Set<Interface> interfaces) |
void |
addAllPackages(java.util.Set<Package> packages) |
void |
addClassOrInterface(Element klass,
Package pkg) |
void |
addElement(Element element) |
void |
addExternalClass(Class klass)
Adiciona uma classe na lista de classes.
|
void |
addExternalInterface(Interface interface_) |
boolean |
addImplementedInterface(Interface supplier,
Class client) |
boolean |
addImplementedInterface(Interface supplier,
Package client) |
void |
addPackage(Package p)
Adiciona um pacote na lista de pacotes
|
boolean |
addRelationship(Relationship relationship) |
void |
addRequiredInterface(Interface supplier,
Class client) |
void |
addRequiredInterface(Interface supplier,
Package client) |
void |
clearArchitecture() |
Class |
createClass(java.lang.String klassName,
boolean isAbstract) |
Interface |
createInterface(java.lang.String interfaceName) |
Interface |
createInterface(java.lang.String interfaceName,
java.lang.String id) |
Package |
createPackage(java.lang.String packageName) |
Package |
createPackage(java.lang.String packageName,
java.lang.String id) |
Architecture |
deepClone() |
Variable |
deepCopy()
Create an exact copy of the
Architecture object. |
void |
deleteClassRelationships(Class class_) |
Element |
findAttributeById(java.lang.String xmiId) |
Class |
findClassById(java.lang.String idClass) |
java.util.List<Class> |
findClassByName(java.lang.String className)
Recupera uma classe por nome.
|
Class |
findClassOfAttributeByID(java.lang.String id) |
Class |
findClassOfMethodByID(java.lang.String id) |
Element |
findClassOrInterfaceOfMethodByID(java.lang.String id) |
Concern |
findConcernByName(java.lang.String name) |
Element |
findElementById(java.lang.String xmiId)
Procura um elemento por ID.
Este método busca por elementos diretamente no primeiro nível da arquitetura (Ex: classes que não possuem pacotes) , e também em pacotes. |
Element |
findElementByName(java.lang.String elementName)
Busca elemento por nome.
|
Element |
findElementByName(java.lang.String name,
java.lang.String type)
Busca elemento por nome.
|
Element |
findElementByNameInPackageAndSubPackage(java.lang.String elementName) |
java.util.List<Element> |
findElementByNumberId(java.lang.Double idElem) |
Interface |
findInterfaceById(java.lang.String idClass) |
Interface |
findInterfaceByName(java.lang.String interfaceName) |
Interface |
findInterfaceOfOperationByID(java.lang.String id) |
Element |
findMethodById(java.lang.String xmiId)
Procura um Method por ID.
Este método busca por elementos diretamente no primeiro nível da arquitetura (Ex: classes que não possuem pacotes) , e também em pacotes. |
Package |
findPackageByID(java.lang.String id) |
Package |
findPackageByName(java.lang.String packageName)
Busca um pacote por nome.
|
Package |
findPackageOfClass(Class targetClass) |
Package |
findPackageOfElementID(java.lang.String id) |
Package |
findPackageOfInterface(Interface targetInterface) |
TypeSmarty |
findReturnTypeSMartyByName(java.lang.String name) |
TypeSmarty |
findTypeSMartyByID(java.lang.String id) |
TypeSmarty |
findTypeSMartyByName(java.lang.String name) |
OperationsOverAbstraction |
forAbstraction() |
OperationsOverGeneralization |
forGeneralization() |
OperationsOverUsage |
forUsage() |
java.util.List<Attribute> |
getAllAtributtes() |
java.util.Set<Class> |
getAllClasses()
Retorna todas as classes que existem na arquiteutra.
|
java.util.List<java.lang.String> |
getAllComments() |
java.util.List<Concern> |
getAllConcerns()
Retorna um Map imutável.
|
java.util.Set<Interface> |
getAllInterfaces()
Retorna todas as interfaces que existem na arquiteutra.
|
java.util.List<Method> |
getAllMethods() |
java.util.Set<Class> |
getAllModifiableClasses() |
java.util.Set<Interface> |
getAllModifiableInterfaces() |
java.util.Set<Package> |
getAllPackages()
Retorna um Map imutável.
|
java.util.List<Package> |
getAllPackagesAllowedMofification() |
java.util.List<Variability> |
getAllVariabilities()
return a list of variability.
|
java.util.List<Variant> |
getAllVariants() |
java.util.List<VariationPoint> |
getAllVariationPoints() |
java.util.Set<Class> |
getClasses()
Retorna classes que não tem nenhum pacote.
|
java.util.ArrayList<Concern> |
getConcerns() |
java.lang.String |
getDetailedString() |
java.lang.String |
getDetailedString(boolean withAttrs) |
java.lang.String |
getDiagramID() |
java.lang.String |
getDiagramName() |
java.util.ArrayList<Interface> |
getDuplicateInterface()
get a list of duplicated interfaces if has
|
java.util.Set<Class> |
getEditableListClasses() |
java.util.Set<Interface> |
getEditableListInterfaces() |
java.util.Set<Package> |
getEditableListPackages()
Retorna um Map mutável.
|
java.util.List<Element> |
getElements() |
java.util.List<Element> |
getElementsWithPackages() |
java.util.List<Element> |
getFreezedElements() |
java.util.Set<Interface> |
getInterfaces()
Retorna interfaces que não tem nenhum pacote.
|
static org.apache.log4j.Logger |
getLOGGER() |
java.lang.String |
getName() |
java.lang.String |
getProjectID() |
java.lang.String |
getProjectName() |
java.lang.String |
getProjectVersion() |
RelationshipsHolder |
getRelationshipHolder() |
java.util.ArrayList<TypeSmarty> |
getTypes() |
boolean |
isAppliedPatterns() |
boolean |
isSMarty() |
boolean |
isToSMarty() |
void |
matchRequiredAndImplementedInterface() |
static java.lang.Double |
mean(java.util.List<java.lang.Integer> values) |
static java.lang.Double |
median(java.util.List<java.lang.Integer> values) |
void |
moveElementToPackage(Element klass,
Package pkg) |
void |
movePackageToParent(java.lang.String packageID,
java.lang.String parentID)
move a package to other package
|
void |
openTempArchitecture() |
void |
removeAllPackages() |
void |
removeAttributeByID(java.lang.String id) |
void |
removeClass(Element klass) |
void |
removeClassByID(java.lang.String id) |
void |
removeImplementedInterface(Class foo,
Interface inter) |
void |
removeImplementedInterface(Interface inter,
Package pacote) |
void |
removeInterface(Interface interfacee) |
void |
removeInterfaceByID(java.lang.String id) |
void |
removeMethodByID(java.lang.String id) |
void |
removeMethodOfClassByID(java.lang.String id) |
boolean |
removeOnlyElement(Element element) |
void |
removeOperationOfInterfaceByID(java.lang.String id) |
void |
removePackage(Package p) |
void |
removePackageByID(java.lang.String id) |
boolean |
removeRelationship(Relationship as) |
void |
removeRequiredInterface(Interface supplier,
Class client) |
void |
removeRequiredInterface(Interface supplier,
Package client) |
void |
removeSubPackageByID(Package subPkg,
java.lang.String id) |
void |
save(Architecture architecture,
java.lang.String pathToSave,
java.lang.String i)
save an architecture to output
if toSMarty is true, save to .smty format, else save to .uml
|
void |
saveToSMarty(Architecture architecture,
java.lang.String pathToSave)
save an architecture in .smty format without consider the format of input architecture
|
void |
setAppliedPatterns(boolean b) |
void |
setCloner(com.rits.cloning.Cloner cloner) |
void |
setConcerns(java.util.ArrayList<Concern> concerns) |
void |
setDiagramID(java.lang.String diagramID) |
void |
setDiagramName(java.lang.String diagramName) |
void |
setName(java.lang.String name) |
void |
setProjectID(java.lang.String projectID) |
void |
setProjectName(java.lang.String projectName) |
void |
setProjectVersion(java.lang.String projectVersion) |
void |
setSMarty(boolean SMarty) |
void |
setToSMarty(boolean toSMarty) |
void |
setTypes(java.util.ArrayList<TypeSmarty> types) |
static java.lang.Double |
sum(java.util.List<java.lang.Integer> values) |
java.lang.String |
toString() |
java.lang.String |
toStringFreezedElements() |
java.util.ArrayList<java.lang.String> |
verifyClassWithoutRelationship() |
java.util.ArrayList<java.lang.String> |
verifyInterfaceWithoutRelationship() |
getLowerBound, getUpperBound, getValue, getVariableType, setLowerBound, setUpperBound, setValue
public java.util.ArrayList<java.lang.String> verifyClassWithoutRelationship()
public java.util.ArrayList<java.lang.String> verifyInterfaceWithoutRelationship()
public void clearArchitecture()
public void matchRequiredAndImplementedInterface()
public void removeAllPackages()
public void removePackageByID(java.lang.String id)
public void removeMethodByID(java.lang.String id)
public void removeMethodOfClassByID(java.lang.String id)
public void removeOperationOfInterfaceByID(java.lang.String id)
public void removeAttributeByID(java.lang.String id)
public Element findClassOrInterfaceOfMethodByID(java.lang.String id)
public Class findClassOfMethodByID(java.lang.String id)
public Interface findInterfaceOfOperationByID(java.lang.String id)
public Class findClassOfAttributeByID(java.lang.String id)
public void removeClassByID(java.lang.String id)
public java.util.ArrayList<Concern> getConcerns()
public void setConcerns(java.util.ArrayList<Concern> concerns)
public Concern findConcernByName(java.lang.String name)
public java.util.ArrayList<Interface> getDuplicateInterface()
public java.util.ArrayList<TypeSmarty> getTypes()
public void setTypes(java.util.ArrayList<TypeSmarty> types)
public TypeSmarty findTypeSMartyByID(java.lang.String id)
public TypeSmarty findTypeSMartyByName(java.lang.String name)
public TypeSmarty findReturnTypeSMartyByName(java.lang.String name)
public boolean isSMarty()
public void setSMarty(boolean SMarty)
public boolean isToSMarty()
public void setToSMarty(boolean toSMarty)
public java.lang.String getProjectID()
public void setProjectID(java.lang.String projectID)
public java.lang.String getProjectName()
public void setProjectName(java.lang.String projectName)
public java.lang.String getProjectVersion()
public void setProjectVersion(java.lang.String projectVersion)
public java.lang.String getDiagramID()
public void setDiagramID(java.lang.String diagramID)
public java.lang.String getDiagramName()
public void setDiagramName(java.lang.String diagramName)
public Element findElementByNameInPackageAndSubPackage(java.lang.String elementName)
public java.lang.String getName()
public void setName(java.lang.String name)
public java.util.List<Element> getElements()
public java.util.List<Element> getElementsWithPackages()
public java.util.List<Element> findElementByNumberId(java.lang.Double idElem)
public java.util.List<Concern> getAllConcerns()
public java.util.List<java.lang.String> getAllComments()
public java.util.Set<Package> getAllPackages()
Set
public java.util.Set<Package> getEditableListPackages()
Set
public java.util.List<Attribute> getAllAtributtes()
public java.util.List<Method> getAllMethods()
public java.util.List<Package> getAllPackagesAllowedMofification()
public java.util.Set<Interface> getInterfaces()
Retorna um Set imutável. É feito isso para garantir que nenhum modificação seja feita diretamente na lista.
public java.util.Set<Interface> getEditableListInterfaces()
public java.util.Set<Interface> getAllInterfaces()
public java.util.Set<Class> getClasses()
Retorna um Set imutável. É feito isso para garantir que nenhum modificação seja feita diretamente na lista
public java.util.Set<Class> getEditableListClasses()
public java.util.Set<Class> getAllClasses()
public Element findElementByName(java.lang.String name, java.lang.String type)
No momento busca por class, interface ou package
TODO refatorar para buscar todo tipo de elemento
name
- - Nome do elementopublic java.util.List<Class> findClassByName(java.lang.String className)
className
- Class
public Element findElementByName(java.lang.String elementName)
elementName
- public Interface findInterfaceByName(java.lang.String interfaceName)
public Package findPackageByName(java.lang.String packageName)
packageName
- public void removeInterfaceByID(java.lang.String id)
public Package findPackageByID(java.lang.String id)
public Package createPackage(java.lang.String packageName)
public Package createPackage(java.lang.String packageName, java.lang.String id)
public void removePackage(Package p)
public Interface createInterface(java.lang.String interfaceName)
public Interface createInterface(java.lang.String interfaceName, java.lang.String id)
public Class createClass(java.lang.String klassName, boolean isAbstract)
public void removeInterface(Interface interfacee)
public void removeClass(Element klass)
public java.util.List<VariationPoint> getAllVariationPoints()
public java.util.List<Variant> getAllVariants()
public java.util.List<Variability> getAllVariabilities()
public Class findClassById(java.lang.String idClass)
public Interface findInterfaceById(java.lang.String idClass)
public void addExternalInterface(Interface interface_)
public void movePackageToParent(java.lang.String packageID, java.lang.String parentID)
packageID
- - id of package that will be movedparentID
- - id of destiny package to be movedpublic void removeSubPackageByID(Package subPkg, java.lang.String id)
public OperationsOverGeneralization forGeneralization()
public OperationsOverAbstraction forAbstraction()
public boolean removeRelationship(Relationship as)
public OperationsOverUsage forUsage()
public Variable deepCopy()
Architecture
object.public Architecture deepClone()
public void deleteClassRelationships(Class class_)
public boolean addRelationship(Relationship relationship)
public Package findPackageOfElementID(java.lang.String id)
public void save(Architecture architecture, java.lang.String pathToSave, java.lang.String i)
architecture
- - target architecturepathToSave
- - name of the output filei
- -public void saveToSMarty(Architecture architecture, java.lang.String pathToSave)
architecture
- - target architecturepathToSave
- - name of output filepublic void openTempArchitecture()
public Element findElementById(java.lang.String xmiId)
xmiId
- public Element findMethodById(java.lang.String xmiId)
xmiId
- public Element findAttributeById(java.lang.String xmiId)
public void addPackage(Package p)
{@link
- Package}public void addExternalClass(Class klass)
{@link
- Class}public boolean removeOnlyElement(Element element)
public void setCloner(com.rits.cloning.Cloner cloner)
public RelationshipsHolder getRelationshipHolder()
public boolean isAppliedPatterns()
public void setAppliedPatterns(boolean b)
public void addAllClasses(java.util.Set<Class> classes)
public void addAllPackages(java.util.Set<Package> packages)
public void addAllInterfaces(java.util.Set<Interface> interfaces)
public java.lang.String toString()
toString
in class java.lang.Object
public static java.lang.Double median(java.util.List<java.lang.Integer> values)
public static java.lang.Double mean(java.util.List<java.lang.Integer> values)
public static java.lang.Double sum(java.util.List<java.lang.Integer> values)
public java.lang.String getDetailedString()
public java.lang.String getDetailedString(boolean withAttrs)
public java.util.List<Element> getFreezedElements()
public java.lang.String toStringFreezedElements()
public void addElement(Element element)
public static org.apache.log4j.Logger getLOGGER()
public java.util.Set<Interface> getAllModifiableInterfaces()
public java.util.Set<Class> getAllModifiableClasses()