public interface IRelationshipPolicy extends IPolicy
Modifier and Type | Method and Description |
---|---|
ICommand |
getCreateRelationshipCommand(TimelineObjectPath sourcePath,
TimelineObjectPath targetPath,
RelationshipType type,
IGanttChartModel model)
Returns a command object that will perform the actual linking of the
source and target timeline objects by making the appropriate changes in
the model.
|
ICommand |
getDeleteRelationshipsCommand(Collection<IRelationship> relationships,
IGanttChartModel model)
Returns a command object that will perform the actual deletion of several
relationship objects from the given model.
|
RelationshipType[] |
getSupportedRelationshipTypes(TimelineObjectPath path,
IGanttChartModel model)
Determines the types of relationships that are supported by the given
timeline object (end to start, start to end, start to start, end to end).
|
boolean |
isDeletable(IRelationship relationship,
IGanttChartModel model)
Determines whether the given relationship object is deletable.
|
boolean |
isRelationshipSource(TimelineObjectPath path,
IGanttChartModel model)
Determines whether the given timeline object can be used for creating a
relationship to another object.
|
boolean |
isRelationshipTarget(TimelineObjectPath sourcePath,
TimelineObjectPath targetPath,
IGanttChartModel model)
Determines whether the given source timeline object can be linked to the
given target timeline object.
|
boolean isRelationshipSource(TimelineObjectPath path, IGanttChartModel model)
path
- the source timeline object pathmodel
- the model of the node and timeline objectisRelationshipTarget(TimelineObjectPath, TimelineObjectPath,
IGanttChartModel)
boolean isRelationshipTarget(TimelineObjectPath sourcePath, TimelineObjectPath targetPath, IGanttChartModel model)
sourcePath
- the source timeline objecttargetPath
- the target timeline objectmodel
- the model of the nodes and timeline objectsisRelationshipSource(TimelineObjectPath, IGanttChartModel)
RelationshipType[] getSupportedRelationshipTypes(TimelineObjectPath path, IGanttChartModel model)
path
- the path to the timeline objecttargetPath
- the target tree nodemodel
- the model of the nodes and timeline objectsboolean isDeletable(IRelationship relationship, IGanttChartModel model)
IRelationship.isDeletable()
.relationship
- the relationship to checkmodel
- the model to which the relationship belongsICommand getCreateRelationshipCommand(TimelineObjectPath sourcePath, TimelineObjectPath targetPath, RelationshipType type, IGanttChartModel model)
sourcePath
- the path to the source timeline objecttargetPath
- the path to the target timeline objecttype
- the type of relationship that the user wants to create (end to
start, start to end, start to start, end to end)model
- the source model of the node and timeline objectIRelationship
,
DefaultCreateRelationshipCommand
ICommand getDeleteRelationshipsCommand(Collection<IRelationship> relationships, IGanttChartModel model)
relationships
- the relationships to deletemodel
- the model to which the relationship belongs objectsIRelationship
,
DefaultDeleteMultipleRelationshipsCommand
Copyright © 2006–2020 Dirk Lemmermann Software & Consulting. All rights reserved.