com.dlsc.flexgantt.policy.layer
Interface IEditActivityObjectPolicy

All Superinterfaces:
IPolicy
All Known Implementing Classes:
DefaultEditActivityObjectPolicy

public interface IEditActivityObjectPolicy
extends IPolicy

A policy that is used for making decisions regarding the editing behaviour of activity objects. Activity objects (IActivityObject) extend timeline objects (ITimelineObject) with the percentage complete attribute (0% <= percentage complete <= 100%).

Since:
1.0
Author:
Dirk Lemmermann
See Also:
IActivityObject, DefaultActivityObject

Method Summary
 ICommand getChangePercentageCommand(java.lang.Object node, java.lang.Object activityObject, IGanttChartModel model, double percentage)
          Returns a command object that will perform the actual change of the percentage complete value.
 boolean isPercentageChangeable(java.lang.Object node, java.lang.Object activityObject, IGanttChartModel model)
          Decides whether or not the percentage complete value of the given activity object can be edited.
 

Method Detail

isPercentageChangeable

boolean isPercentageChangeable(java.lang.Object node,
                               java.lang.Object activityObject,
                               IGanttChartModel model)
Decides whether or not the percentage complete value of the given activity object can be edited.

Parameters:
node - the tree node that owns the capacity object
activityObject - the activity object that gets checked for its editing ability
model - the data source of the tree node and the activity object
Returns:
TRUE if the percentage complete value can be edited
Since:
1.0

getChangePercentageCommand

ICommand getChangePercentageCommand(java.lang.Object node,
                                    java.lang.Object activityObject,
                                    IGanttChartModel model,
                                    double percentage)
Returns a command object that will perform the actual change of the percentage complete value.

Parameters:
node - the tree node that owns the capacity object
activityObject - the activity object that gets checked for its editing ability
model - the data source of the tree node and the activity object
percentage -
Returns:
the command that will change the percentage complete value
Since:
1.0