FRAMES NO FRAMES

Class IlcActivityDeltaIterator

Definition file: ilsched/schedule.h
Include file: <ilsched/ilsched.h>

An instance of this class traverses a delta set of activities, for example, the new direct predecessors of a given activity. This iterator is only available during the search.

See Also:

Constructor and Destructor Summary
public IlcActivityDeltaIterator(IlcActivity act, IlcActivityIteratorFilter filter)
Method Summary
public IlcBoolok() const
public IlcActivityoperator*() const
public IlcActivityDeltaIterator &operator++()
Constructor and Destructor Detail

IlcActivityDeltaIterator

public IlcActivityDeltaIterator(IlcActivity act, IlcActivityIteratorFilter filter)

This constructor creates a delta iterator to traverse the elements of the subset of activities specified by filter whose status has changed with respect to act.

The possible filters are IlcDirectPredecessors, IlcDirectSuccessors, IlcPredecessors, and IlcSuccessors.

The possible statuses of an activity with respect to act are: unranked, direct predecessor, direct successor, indirect predecessor, indirect successor.

Thus, with the filters IlcDirectSuccessors or IlcDirectPredecessors, the delta iterator traverses the set of new direct successors or new direct predecessors of act.

With the filters IlcSuccessors or IlcPredecessors, the delta iterator traverses the union of the set of new direct successors and the set of new indirect successors of act or the union of the set of new direct predecessors and the set of new indirect predecessors of act. Note that this delta set is a superset of the set of new successors or new predecessors of act.

The delta sets of activities are emptied once all the demons attached to the precedence graph events of an activity have been executed. Thus, any attempt to traverse a delta set of activities outside the execution of such a demon may lead to unexpected behavior.

This constructor can be used only if a schedule precedence graph is associated with the schedule of activity act. If the schedule is not associated with a precedence graph, this constructor raises an error.


Method Detail

ok

public IlcBool ok() const

This member function returns IlcTrue if the current position of the iterator is a valid one. It returns IlcFalse if all the activities have been scanned by the iterator.


operator*

public IlcActivity operator*() const

This operator returns the current instance of IlcActivity, the one to which the invoking iterator points. If the iterator is set past the end position, then this operator returns an empty handle.


operator++

public IlcActivityDeltaIterator & operator++()

This left-increment operator shifts the current position of the iterator to the next delta instance of IlcActivity.