|
![]() |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
T_Key
- The TargetKey type.T_ItemKey
- The ItemKey type.public interface DependencyElement<T_Key,T_ItemKey>
Represents a dependency target.
Method Summary | |
---|---|
DependencyElement<T_Key,T_ItemKey> |
addAffects(T_Key key)
Declares a direct dependency between this element and the one with the given key so that this element will be sequentially before the one with the given key. |
DependencyElement<T_Key,T_ItemKey> |
addDepends(T_Key key)
Declares a direct dependency between this target and the one with the given key so that this target will be sequentially after the one with the given key. |
DependencyItem<T_ItemKey> |
addInput(T_ItemKey key)
Declares an indirect dependency between this target and the item with the given key so that this target will be sequentially after all targets that declares item as its output. |
DependencyItem<T_ItemKey> |
addOutput(T_ItemKey key)
Declares an indirect dependency between this target and the item with the given key so that this target will be sequentially before all targets that declares item as its input. |
void |
addPropertyChangeListener(DependencyElementProperty property,
PropertyChangeListener listener)
Add a PropertyChangeListener for a specific property. |
void |
addPropertyChangeListener(PropertyChangeListener listener)
Add a PropertyChangeListener to the listener list. |
boolean |
affects(T_Key key)
Indicates whether this target is declared to affect the target with the given key. |
boolean |
depends(T_Key key)
Indicates whether this target is declared to depend on the target with the given key. |
int |
getDeclarationOrder()
|
Collection<DependencyElement<T_Key,T_ItemKey>> |
getImpactedTargets()
Gets all targets that are impacted by this target. |
Integer |
getIndex()
Gets the sequential index of this target. |
T_Key |
getKey()
Gets the key of this target. |
Collection<DependencyElement<T_Key,T_ItemKey>> |
getRequiredTargets()
Gets all targets that are required by this target by this target. |
Object |
getUserObject()
Gets the associated user object. |
boolean |
impacts(T_Key target)
Indicates whether this target impacts the target with the given value. |
boolean |
isInput(T_ItemKey key)
Indicates whether the item with the given key is declared as input of this target. |
boolean |
isOutput(T_ItemKey key)
Indicates whether the item with the given key is declared as output of this target. |
DependencyElement<T_Key,T_ItemKey> |
removeAffects(T_Key key)
Removes a direct dependency declaration previously declared by addAffects(T_Key) . |
DependencyElement<T_Key,T_ItemKey> |
removeDepends(T_Key key)
Removes a direct dependency declaration previously declared by addDepends(T_Key) . |
DependencyItem<T_ItemKey> |
removeInput(T_ItemKey key)
Removes an input declaration. |
DependencyItem<T_ItemKey> |
removeOutput(T_ItemKey key)
Removes an output declaration. |
void |
removePropertyChangeListener(DependencyElementProperty property,
PropertyChangeListener listener)
Remove a PropertyChangeListener for a specific property. |
void |
removePropertyChangeListener(PropertyChangeListener listener)
Remove a PropertyChangeListener from the listener list. |
boolean |
requires(T_Key target)
Indicates whether this target requires the target with the given value. |
void |
setUserObject(Object userObject)
Associates an arbitrary user object with this item. |
Method Detail |
---|
DependencyElement<T_Key,T_ItemKey> addAffects(T_Key key) throws DependencyException
key
- Key of the "other" element.
DependencyException
- If key refers to this element or a element, that is
already declared to be sequentially before this element.DependencyElement<T_Key,T_ItemKey> addDepends(T_Key key) throws DependencyException
key
- Key of the "other" target.
DependencyException
- If key refers to this target or a target, that is
already declared to be sequentially after this target.DependencyItem<T_ItemKey> addInput(T_ItemKey key) throws DependencyException
key
- Key of the item.
DependencyException
- If key refers to an item, that is
already declared as output of this target.DependencyItem<T_ItemKey> addOutput(T_ItemKey key) throws DependencyException
key
- Key of the item.
DependencyException
- If key refers to an item, that is
already declared as input of this target.void addPropertyChangeListener(PropertyChangeListener listener)
listener
is null, no exception is thrown and no action
is taken.
listener
- The PropertyChangeListener to be addedvoid addPropertyChangeListener(DependencyElementProperty property, PropertyChangeListener listener)
property
- The property to listen on.listener
- The PropertyChangeListener to be addedboolean affects(T_Key key)
key
- The "other" target.
boolean depends(T_Key key)
key
- The "other" target.
Integer getIndex()
T_Key getKey()
Object getUserObject()
Collection<DependencyElement<T_Key,T_ItemKey>> getImpactedTargets()
Dependencies
' object isDeepDependencyCheck
property:
isDeepDependencyCheck
returns false
, a target <i>T</i>
returns all targets <i>T'</i>
, that
fulfills at least one of the following conditions:
<i>T</i>
declares that it affects <i>T'</i>
: <i>T</i>.addAffects(<i>T'</i>.getKey())
.<i>T'</i>
declares that it depends on <i>T</i>
: <i>T'</i>.addDepends(<i>T</i>.getKey())
.<i>T</i>
declares an item with the key <i>I</i>
as output that is declared as input of <i>T'</i>
:<i>T</i>.addOutput(<i>I</i>);<i>T'</i>.addInput(<i>I</i>)
.isDeepDependencyCheck
returns true
, <i>T</i>
returns all the targets
of the other case plus the result of <i>T'</i>.getImpactedTargets()
for all <i>T'</i>
and so on.
int getDeclarationOrder()
boolean impacts(T_Key target)
getImpactedTargets().contains(getTarget(target))
.
For two targets T
and <i>T'</i>
, it is guaranteed that
<i>T</i>.impacts(<i>T'</i>.getKey())==<i>T'</i>.requires(<i>T</i>.getKey())
is allways true
.
target
- The "other" target.
getImpactedTargets()
boolean isInput(T_ItemKey key)
key
- The item's key.
boolean isOutput(T_ItemKey key)
key
- The item's key.
DependencyElement<T_Key,T_ItemKey> removeAffects(T_Key key)
addAffects(T_Key)
.
key
- The "other" target's key.
DependencyElement<T_Key,T_ItemKey> removeDepends(T_Key key)
addDepends(T_Key)
.
key
- The "other" target's key.
DependencyItem<T_ItemKey> removeInput(T_ItemKey key)
key
- The item's key.
DependencyItem<T_ItemKey> removeOutput(T_ItemKey key)
key
- The item's key.
void removePropertyChangeListener(PropertyChangeListener listener)
listener
was added more than once to the same event
source, it will be notified one less time after being removed.
If listener
is null, or was never added, no exception is
thrown and no action is taken.
listener
- The PropertyChangeListener to be removedvoid removePropertyChangeListener(DependencyElementProperty property, PropertyChangeListener listener)
listener
was added more than once to the same event
source for the specified property, it will be notified one less time
after being removed.
If listener
is null, or was never added for the specified
property, no exception is thrown and no action is taken.
property
- The property that was listened on.listener
- The PropertyChangeListener to be removedCollection<DependencyElement<T_Key,T_ItemKey>> getRequiredTargets()
Dependencies
' object isDeepDependencyCheck
property:
isDeepDependencyCheck
returns false
, a target <i>T</i>
returns all targets <i>T'</i>
, that
fulfills at least one of the following conditions:
<i>T</i>
declares that it depends on <i>T'</i>
: <i>T</i>.addDepends(<i>T'</i>.getKey())
.<i>T'</i>
declares that it affects <i>T</i>
: <i>T'</i>.addAffects(<i>T</i>.getKey())
.<i>T</i>
declares an item with the key <i>I</i>
as input that is declared as output of <i>T'</i>
:<i>T</i>.addInput(<i>I</i>);<i>T'</i>.addOutput(<i>I</i>)
.isDeepDependencyCheck
returns true
, <i>T</i>
returns all the targets
of the other case plus the result of <i>T'</i>.getRequiredTargets()
for all <i>T'</i>
and so on.
getImpactedTargets()
,
requires(T_Key)
boolean requires(T_Key target)
getRequiredTargets().contains(getTarget(target))
.
For two targets <i>T</i>
and <i>T'</i>
, it is guaranteed that
<i>T</i>.impacts(<i>T'</i>.getKey())==<i>T'</i>.requires(<i>T</i>.getKey())
is allways true
.
target
- The "other" target.
getRequiredTargets()
,
getImpactedTargets()
,
impacts(T_Key)
void setUserObject(Object userObject)
userObject
- Object to associate with this item.
|
![]() |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |