public interface IlvConstraint
IlvConstraint
defines the abstract behavior of a constraint
between two IlvActivity
objects. Each constraint is defined by a
type, its From activity, and its To activity.
IlvConstraint
implementations are expected to route their
property change events to the Gantt data model
.
Therefore, although there is no accessor to the data model in this interface,
the constraint implementation must have some method of obtaining the model it
belongs to. Here is an example of how the IlvConstraint
implementation should fire its property change events:
void fireEvent (ConstraintEvent event) { IlvGanttModel model = ..... if (model != null) model.fireConstraintEvent(event); }
Modifier and Type | Method and Description |
---|---|
IlvActivity |
getFromActivity()
Returns the source or From activity for this constraint.
|
IlvActivity |
getToActivity()
Returns the target or To activity for this constraint.
|
IlvConstraintType |
getType()
Returns the type of this constraint.
|
void |
setGanttModelImpl(IlvGanttModel model)
This method is invoked by the
IlvGanttModel when the constraint
is added or removed. |
void |
setType(IlvConstraintType type)
Sets the type of this constraint.
|
IlvConstraintType getType()
void setType(IlvConstraintType type)
type
- The constraint type.IlvActivity getFromActivity()
IlvActivity getToActivity()
void setGanttModelImpl(IlvGanttModel model)
IlvGanttModel
when the constraint
is added or removed.
Warning: This method is considered to be part of an
IlvConstraint
's internal implementation and is not a public
API.
You should only invoke this method directly if you have created your own
IlvGanttModel
implementation.
model
- The data model that this constraint has been added to, or
null
if this constraint has been removed from the data model.© Copyright Rogue Wave Software, Inc. 1997, 2018. All Rights Reserved.