Poseidon for UMLTM
  UMLdoc
 PREV  CLASSIFIER    NEXT  CLASSIFIER     FRAMES    NO FRAMES      
SUMMARY:   INNER | ATTR | ASSOC | CONSTR | METHOD     DETAIL:   INNER | ATTR | ASSOC | CONSTR | METHOD     DIAGRAMS:   COLLAB | SEQ | STATE | ACTIV

com.gentleware.jboogie.model_management

Class DiHelpers

com.gentleware.jboogie.model_management.DiHelpers

public final class DiHelpers


Static helper methods to modify MDR model elements

Created : sturm, Dec 11, 2002, 5:59:51 PM

Authors:
sturm


 Association Summary
private final Project  _project
 
public ProjectImpl  projectImpl
 
arrow_up
 

 Constructor Summary
public   DiHelpers(Project project)
 
arrow_up
 

 Method Summary
private Point2D   addBase(Point2D base, Point diPoint)
 
private Point2D   addBase(Point2D base, double x, double y)
 
public List   diIdListToElementList(Collection elements)
Produces a list of Elements that reflects the list of given DiIds. 
public List   elementListToDiIdList(Collection elements)
Produces a list of DiIds that reflects the list of given elements. 
public Rectangle   getFullBounds(GraphElement container)
 
private Rectangle   getFullBounds(DiagramElement diagramElement, Rectangle bounds, Point2D coordBase)
 
public boolean   hasPresentationIn(GraphElement container, RefObject modelElement)
checks wether the container contains (recursively) any element that is associated to the modelelement. 
public boolean   hasPresentationIn(GraphElement container, RefObject modelElement, DiPredicate filterPredicate)
checks wether the container contains (recursively) any element that is associated to the modelelement. 
public boolean   isContainedIn(DiagramElement contained, DiagramElement container)
 
public boolean   isDiagramElementStillValid(DiagramElement element)
 
public boolean   isElementInContainer(GraphElement container, DiagramElementImpl element)
Tests, if an element with the same properties as the given element is already contained in the given container. 
public Point   localToAncestor(GraphElement local, Point localPoint, GraphElement ancestor)
Translates a point  
public static Point2D   toJavaPoint(Point input)
 
arrow_up
 

Tagged Values
static false
 

 Association Detail

_project

private Project _project

arrow_up


projectImpl

public ProjectImpl projectImpl

arrow_up
 Constructor Detail

DiHelpers

public DiHelpers DiHelpers(Project project)

Parameters:
project -
Returns:
arrow_up
 Method Detail

addBase

private Point2D addBase(Point2D base, Point diPoint)

Parameters:
base -
diPoint -
Returns:
arrow_up


addBase

private Point2D addBase(Point2D base, double x, double y)

Parameters:
base -
x -
y -
Returns:
arrow_up


diIdListToElementList

public List diIdListToElementList(Collection elements)


Produces a list of Elements that reflects the list of given DiIds.  
Parameters:
elements -
Returns:
arrow_up


elementListToDiIdList

public List elementListToDiIdList(Collection elements)


Produces a list of DiIds that reflects the list of given elements.  
Parameters:
elements -
Returns:
arrow_up


getFullBounds

public Rectangle getFullBounds(GraphElement container)

Parameters:
container -
Returns:
arrow_up


getFullBounds

private Rectangle getFullBounds(DiagramElement diagramElement, Rectangle bounds, Point2D coordBase)

Parameters:
diagramElement -
bounds -
coordBase -
Returns:
arrow_up


hasPresentationIn

public boolean hasPresentationIn(GraphElement container, RefObject modelElement)


checks wether the container contains (recursively) any element that is associated to the modelelement. excluded are all kinds of Name-notation-elements, that means if you are checking wether your classdiagram has a representation of ClassA, and ClassA only appears as the type of another attribute, then the method will return "false". You can use the other hasPresentation()-method with a DiPredicate filter of null if you really are interested in all sorts of presentations  
Parameters:
container -
modelElement -
Returns:
arrow_up


hasPresentationIn

public boolean hasPresentationIn(GraphElement container, RefObject modelElement, DiPredicate filterPredicate)


checks wether the container contains (recursively) any element that is associated to the modelelement. You can pass a filter, or if you leave the filter null, then you will get ALL sorts of presentations, you will even get true for a umlclass that only appears as an attributes type  
Parameters:
container -
modelElement -
filterPredicate -
Returns:
arrow_up


isContainedIn

public boolean isContainedIn(DiagramElement contained, DiagramElement container)

Parameters:
contained -
container -
Returns:
arrow_up


isDiagramElementStillValid

public boolean isDiagramElementStillValid(DiagramElement element)

Parameters:
element -
Returns:
arrow_up


isElementInContainer

public boolean isElementInContainer(GraphElement container, DiagramElementImpl element)


Tests, if an element with the same properties as the given element is already contained in the given container. The test is a shallow test (no recursion to contained containers).  
Parameters:
container - Container to search in.
element - Element to look up.
Returns:
True, if an identical element is found, otherwise false.
arrow_up


localToAncestor

public Point localToAncestor(GraphElement local, Point localPoint, GraphElement ancestor)


Translates a point  
Parameters:
local -
localPoint -
ancestor -
Returns:
arrow_up


toJavaPoint

public static Point2D toJavaPoint(Point input)

Parameters:
input -
Returns:
arrow_up
Created  2004 - 10 - 21

    Poseidon for UMLTM
  UMLdoc
 PREV  CLASSIFIER    NEXT  CLASSIFIER     FRAMES    NO FRAMES      
SUMMARY:   INNER | ATTR | ASSOC | CONSTR | METHOD     DETAIL:   INNER | ATTR | ASSOC | CONSTR | METHOD     DIAGRAMS:   COLLAB | SEQ | STATE | ACTIV

Generated with Poseidon for UMLTM.
Poseidon is a registered trademark of Gentleware AG in Germany, USA and other countries. Copyright 2003-2004 Gentleware AG, Schanzenstr. 70, 20357 Hamburg, Germany. All Rights Reserved.

UML is a trademark or registered trademark of Object Management Group, Inc. in the U.S. and other countries.