de.uni_paderborn.fujaba.uml.utility
Class UMLClassDiagramUtility

java.lang.Object
  extended byde.uni_paderborn.fujaba.asg.ASGUtility
      extended byde.uni_paderborn.fujaba.uml.utility.UMLClassDiagramUtility

public class UMLClassDiagramUtility
extends ASGUtility

Utility class for reusable UMLClassDiagram methodes.

Version:
$Revision: 1.20 $
Author:
$Author: fklar $

Constructor Summary
UMLClassDiagramUtility(ASGDiagram diagram)
          Constructor for abstract class ASGUtility
 
Method Summary
static de.upb.tools.fca.FTreeSet calculatePossibleAssocs(UMLClass class1, UMLClass class2)
          Calculates all associations between two classes and returns the list of associations.
static de.upb.tools.fca.FTreeSet calculatePossibleAssocsViaASGElementRef(UMLClass refClass, UMLClass elemClass)
          Calculates all associations between two classes via ASGElementRef and returns the list of associations.
static UMLAssoc getAssoc(java.lang.String assocName)
          returns the association for a given association name.
static boolean isDerivedfrom(UMLClass cls, java.lang.String superClsName)
           
static void removeMethodBySameName(UMLClass cls, UMLMethod method)
          removes tmpMethod with has the same name (not signature!)
static UMLAssoc searchForAssoc(UMLClass class1, UMLClass class2, java.lang.String assocName)
          No comment provided by developer, please add a comment to improve documentation.
static java.util.Set setOfAssociations(UMLClass class1, UMLClass class2)
          Only for tests, will be removed.
 
Methods inherited from class de.uni_paderborn.fujaba.asg.ASGUtility
getDiagram, setDiagram
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UMLClassDiagramUtility

public UMLClassDiagramUtility(ASGDiagram diagram)
Constructor for abstract class ASGUtility

Parameters:
diagram - No description provided
Method Detail

setOfAssociations

public static java.util.Set setOfAssociations(UMLClass class1,
                                              UMLClass class2)
Only for tests, will be removed.

Parameters:
class1 - The new ofAssociations value
class2 - The new ofAssociations value
Returns:
No description provided

calculatePossibleAssocs

public static de.upb.tools.fca.FTreeSet calculatePossibleAssocs(UMLClass class1,
                                                                UMLClass class2)
                                                         throws java.lang.IllegalArgumentException
Calculates all associations between two classes and returns the list of associations. Inherited assocs will be also considered.

Parameters:
class1 - the first class.
class2 - the second class.
Returns:
An FTreeSet containing all possible associations between the specified classes.
Throws:
java.lang.IllegalArgumentException - If at least one of the parameters is null.

calculatePossibleAssocsViaASGElementRef

public static de.upb.tools.fca.FTreeSet calculatePossibleAssocsViaASGElementRef(UMLClass refClass,
                                                                                UMLClass elemClass)
Calculates all associations between two classes via ASGElementRef and returns the list of associations.

Parameters:
refClass - No description provided
elemClass - No description provided
Returns:
No description provided

isDerivedfrom

public static boolean isDerivedfrom(UMLClass cls,
                                    java.lang.String superClsName)
Parameters:
cls - No description provided
superClsName - No description provided
Returns:
The derivedfrom value

getAssoc

public static UMLAssoc getAssoc(java.lang.String assocName)
returns the association for a given association name.

Parameters:
assocName - No description provided
Returns:
The associations value

searchForAssoc

public static UMLAssoc searchForAssoc(UMLClass class1,
                                      UMLClass class2,
                                      java.lang.String assocName)
No comment provided by developer, please add a comment to improve documentation.

Parameters:
class1 - No description provided
class2 - No description provided
assocName - No description provided
Returns:
No description provided

removeMethodBySameName

public static void removeMethodBySameName(UMLClass cls,
                                          UMLMethod method)
removes tmpMethod with has the same name (not signature!) as UMLMethod method

Parameters:
cls - No description provided
method - No description provided