All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.sun.install.tasks.ComponentDependencyTask

java.lang.Object
   |
   +----com.sun.wizards.core.Task
           |
           +----com.sun.install.tasks.ComponentDependencyTask

public class ComponentDependencyTask
extends Task
implements Serializable
The ComponentDependencyTask is used on product-level install wizards to remove components or set their default installation state. You might add this task to a sequence that is executed on a state change, perhaps adding or removing different components based on the state change. In this examle, this task will remove components comp1, comp2, and comp3 from the components scheduled to be installed for this archive.
Vector compIDs = new Vector(); compIDs.addElement("comp1"); compIDs.addElement("comp2"); compIDs.addElement("comp3"); ComponentDependencyTask removeTask = new ComponentDependencyTask(compIDs, ComponentDependencyTask.REMOVE); Sequence removeSequence = new Sequence(); removeSequence.addTask(removeTask);
In order to use this task, you must include it in a Sequence and register it at buildtime with the WizardState, and then call on it during runtime at the desired time.


Variable Index

 o DESELECT
A value indicating that the specified components should be deselected.
 o REMOVE
A value indicating that the specified components should be removed.
 o SELECT
A value indicating that the specified components should be selected.

Constructor Index

 o ComponentDependencyTask(Vector, int)
Create a ComponentDependency task that performs the specified action on the specified components.

Method Index

 o addRuntimeResources(Vector)
Add the runtime class requirements to the specified vector.
 o perform()
Perform this Task.

Variables

 o REMOVE
 public static final transient int REMOVE
A value indicating that the specified components should be removed.

 o DESELECT
 public static final transient int DESELECT
A value indicating that the specified components should be deselected.

 o SELECT
 public static final transient int SELECT
A value indicating that the specified components should be selected.

Constructors

 o ComponentDependencyTask
 public ComponentDependencyTask(Vector componentIDs,
                                int action)
Create a ComponentDependency task that performs the specified action on the specified components. Valid actions are: REMOVE, DESELECT, and SELECT.

Parameters:
componentIDs - The IDs referring to components to be affected by this task.
action - The action to perform on the specified components.

Methods

 o perform
 public void perform()
Perform this Task. This method is used to remove, delelect, or select product components.

Overrides:
perform in class Task
 o addRuntimeResources
 public void addRuntimeResources(Vector resourceVector)
Add the runtime class requirements to the specified vector.

Parameters:
resourceVector - The vector containing all runtime resources for this wizard.
Overrides:
addRuntimeResources in class Task

All Packages  Class Hierarchy  This Package  Previous  Next  Index