OptimalTrace
5.2

com.compuware.optimaltrace.framework.relations
Interface ParentIfc

All Superinterfaces:
RelationIfc
All Known Subinterfaces:
AbstractRequirementIfc, AbstractStepIfc, AlternativeScenarioIfc, BizObjectIfc, com.compuware.optimaltrace.tools.common.bizobjectslocal.ClearableSuspectLinkIfc, CustomPropertyTemplateIfc, CustomPropertyTemplateListIfc, GoalLevelIfc, GoalLevelsIfc, ItemIfc, ItemListIfc, MainSuccessScenarioIfc, ProjectIfc, RefinementIfc, ScenarioIfc, SimpleRequirementIfc, StepIfc, TableHolderListContainerIfc, ToolSettingsIfc, UseCaseIfc, UseCasePackageIfc
All Known Implementing Classes:
com.compuware.optimaltrace.framework.business.AbstractBizObject, com.compuware.optimaltrace.tools.common.bizobjects.AbstractStep, ProjectContainer, Step

public interface ParentIfc
extends RelationIfc

Interface ParentIfc


Method Summary
 boolean addChild(ChildIfc child)
          Adds the child.
 boolean addChildAt(ChildIfc child, int position)
          Adds the child at the specific position.
 void addParentListener(com.compuware.optimaltrace.framework.relations.ParentListenerIfc listener)
          Adds the parent listener.
 ChildIfc decrementChildPosition(ChildIfc child)
          Moves the child's position 1 towards the back of the List.
 void fireChildEvent(ChildIfc child, int index, int oldIndex, long eventType)
          Fires the child event.
 void fireChildEvent(java.util.List children, long eventType)
          Fires the child event.
 ChildIfc getChild(java.lang.Class childClass)
          Gets the child.
 ChildIfc getChild(java.lang.String name, java.lang.Class childClass)
          Gets the child.
 ChildIfc getChildById(long id)
          Gets the child by id.
 java.util.List getChildren()
          Gets the children.
 java.util.List getChildren(java.lang.Class childClass)
          Gets the children.
 java.util.List getChildren(java.lang.String name, java.lang.Class childClass)
          Gets the children.
 ChildIfc getNextChild(ChildIfc child)
          Gets the next child, or null if none such can be found
 java.util.List getParentListeners()
          Gets the parent listeners.
 ChildIfc getPreviousChild(ChildIfc child)
          Gets the previous child, or null if none such can be found
 boolean hasChild(ChildIfc child)
          Checks if it has the child.
 boolean hasChildById(long childId)
          Checks if it has the child by id.
 ChildIfc incrementChildPosition(ChildIfc child)
          Moves the child's position 1 towards the top of the List.
 boolean moveChild(ChildIfc child, int newPosition)
          Moves the child's position to the new position.
 int numChildren()
          Gets the number of children.
 void reInitialiseListeners()
          Re-initializes the listener list.
 boolean removeChild(ChildIfc child)
          Removes the child.
 void removeParentListener(com.compuware.optimaltrace.framework.relations.ParentListenerIfc listener)
          Removes the parent listener.
 boolean silentlyAddChild(ChildIfc child)
          Adds the dhild silently.
 boolean silentlyAddChildAt(ChildIfc child, int index)
          Adds the child at the specific position silently.
 boolean silentlyRemoveChild(ChildIfc child)
          Adds the child silently.
 

Method Detail

addChild

boolean addChild(ChildIfc child)
Adds the child.

Parameters:
child -
Returns:
boolean

addChildAt

boolean addChildAt(ChildIfc child,
                   int position)
Adds the child at the specific position.

Parameters:
child -
position -
Returns:
boolean

silentlyAddChild

boolean silentlyAddChild(ChildIfc child)
Adds the dhild silently.

Parameters:
child -
Returns:
boolean

silentlyAddChildAt

boolean silentlyAddChildAt(ChildIfc child,
                           int index)
Adds the child at the specific position silently.

Parameters:
child -
Returns:
boolean

removeChild

boolean removeChild(ChildIfc child)
Removes the child.

Parameters:
child -
Returns:
boolean

silentlyRemoveChild

boolean silentlyRemoveChild(ChildIfc child)
Adds the child silently.

Parameters:
child -
Returns:
boolean

getChildren

java.util.List getChildren()
Gets the children.

Returns:
List

getChildren

java.util.List getChildren(java.lang.Class childClass)
Gets the children.

Parameters:
childClass -
Returns:
List

getChildren

java.util.List getChildren(java.lang.String name,
                           java.lang.Class childClass)
Gets the children.

Parameters:
name -
childClass -
Returns:
List

getChild

ChildIfc getChild(java.lang.String name,
                  java.lang.Class childClass)
Gets the child.

Parameters:
name -
childClass -
Returns:
ChildIfc

getChild

ChildIfc getChild(java.lang.Class childClass)
Gets the child.

Parameters:
childClass -
Returns:
ChildIfc

getNextChild

ChildIfc getNextChild(ChildIfc child)
Gets the next child, or null if none such can be found

Parameters:
child -
Returns:
ChildIfc

getPreviousChild

ChildIfc getPreviousChild(ChildIfc child)
Gets the previous child, or null if none such can be found

Parameters:
child -
Returns:
ChildIfc

getChildById

ChildIfc getChildById(long id)
Gets the child by id.

Parameters:
id -
Returns:
ChildIfc

addParentListener

void addParentListener(com.compuware.optimaltrace.framework.relations.ParentListenerIfc listener)
Adds the parent listener.

Parameters:
listener -

removeParentListener

void removeParentListener(com.compuware.optimaltrace.framework.relations.ParentListenerIfc listener)
Removes the parent listener.

Parameters:
listener -

hasChild

boolean hasChild(ChildIfc child)
Checks if it has the child.

Parameters:
child -
Returns:
boolean

hasChildById

boolean hasChildById(long childId)
Checks if it has the child by id.

Parameters:
childId -
Returns:
boolean

numChildren

int numChildren()
Gets the number of children.

Returns:
int

incrementChildPosition

ChildIfc incrementChildPosition(ChildIfc child)
Moves the child's position 1 towards the top of the List.

Parameters:
child -
Returns:
ChildIfc

decrementChildPosition

ChildIfc decrementChildPosition(ChildIfc child)
Moves the child's position 1 towards the back of the List.

Parameters:
child -
Returns:
ChildIfc indicating success or failure

moveChild

boolean moveChild(ChildIfc child,
                  int newPosition)
Moves the child's position to the new position.

Parameters:
child -
newPosition -
Returns:
boolean

getParentListeners

java.util.List getParentListeners()
Gets the parent listeners.


reInitialiseListeners

void reInitialiseListeners()
Re-initializes the listener list. This is necessary for Undo/Redo in cases where the UI has not detached itself correctly from bizObjects that have been deleted.


fireChildEvent

void fireChildEvent(ChildIfc child,
                    int index,
                    int oldIndex,
                    long eventType)
Fires the child event.

Parameters:
child -
index -
oldIndex -
eventType -

fireChildEvent

void fireChildEvent(java.util.List children,
                    long eventType)
Fires the child event.

Parameters:
children -
eventType -

OptimalTrace
5.2

Compuware Corporation

OptimalTrace is a trademark or registered trademark of Compuware Corporation in the US and other countries.
Copyright 2008-2009 Compuware Corporation. One Campus Martius,
Detroit, Michigan, 48226, U.S.A. All Rights Reserved.