All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.sun.install.tasks.DesktopTask

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

public class DesktopTask
extends Task
implements Serializable
DesktopTask will add icons (shortcuts) to the user's desktop, using a product tree to gather the information.

An item will be added for each product tree component that has a property called "DesktopItems". That property must be a Vector of String[]s with 4 elements:


Constructor Index

 o DesktopTask()
Creates a new DesktopTask.
 o DesktopTask(String)
This constructor is used by the builder.

Method Index

 o addRuntimeResources(Vector)
Add the runtime class requirements to the specified vector.
 o expandKeywords(String)
Looks for commands of the form {statekey}, and replaces them with the variable stored under the specified key.
 o perform()
Add the icons

Constructors

 o DesktopTask
 public DesktopTask()
Creates a new DesktopTask.

 o DesktopTask
 public DesktopTask(String componentKey)
This constructor is used by the builder.

Parameters:
componentKey - The WizardState key identifying the product component this DesktopTask installs desktop items for.

Methods

 o perform
 public void perform()
Add the icons

Overrides:
perform in class Task
 o expandKeywords
 public String expandKeywords(String command)
Looks for commands of the form {statekey}, and replaces them with the variable stored under the specified key. For instance, assume that one has called the WizardState's setData("mylocation", "/opt"); statement. Then this method would replace the String "{mylocation}/bin/runme" with the String "/opt/bin/runme".

Parameters:
command - The string with the unresolved variables in it. Nested braces are not allowed.
Returns:
The same string passed in, execept and variable instances of the form {statekey} are replaced with the values under that state key
 o addRuntimeResources
 public void addRuntimeResources(Vector resourceVector)
Add the runtime class requirements to the specified vector.

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

All Packages  Class Hierarchy  This Package  Previous  Next  Index