All Packages Class Hierarchy This Package Previous Next Index
Class com.sun.install.products.PlatformDependency
java.lang.Object
|
+----com.sun.install.products.InstallComponent
|
+----com.sun.install.products.InstallNode
|
+----com.sun.install.products.PlatformDependency
- public class PlatformDependency
- extends InstallNode
This is a sample of a product dependency that depends on the runtime
platform of the wizard.
PlatformDependency is a generic InstallNode that you can insert into
a product tree to affect what is visible below it. Calling upon the
refresh() method with a target of "nodeIsActive" will make the dependency
enforce its rules by checking its dependency, and turning on or off its children.
-
invert
- A flag indicating this dependency should be inverted (equivelent to the
boolean operation 'not')
Deprecated.
-
platform
- The platform this dependency is configured with.
-
PlatformDependency()
- Constructs a new PlatformDependency with no configured platforms.
-
PlatformDependency(Platform, boolean)
- Constructs a new platform dependency with required information, including inversion.
-
addRuntimeResources(Vector)
- Add the required resources when this object is used in the Product Tree.
-
getInvert()
- Gets the invert state of this InstallComponent
-
initialize(WizardState)
- Initialize this object.
-
refresh(Vector, String)
-
Update this dependency.
-
setInvert(boolean)
- Sets the invert state of this InstallComponent
invert
protected boolean invert
- Note: invert is deprecated.
use set/getInvert()
- A flag indicating this dependency should be inverted (equivelent to the
boolean operation 'not')
platform
protected Platform platform
- The platform this dependency is configured with. This determines whether
the children of this dependency participate in tree operations or not.
PlatformDependency
public PlatformDependency()
- Constructs a new PlatformDependency with no configured platforms.
PlatformDependency
public PlatformDependency(Platform platform,
boolean inverted)
- Constructs a new platform dependency with required information, including inversion.
- Parameters:
- platform - The platform this dependency depends on. Children of this node will not
be allowed to participate in installs if this platform is not the runtime
platform, unless inverted is true.
- inverted - A flag indicating this dependency should invert its results. If this is false, the
dependency does not allow participation of its children if the runtime platform
does not match the supplied platform
getInvert
public boolean getInvert()
- Gets the invert state of this InstallComponent
- Returns:
- The invert state of this component
setInvert
public void setInvert(boolean invert)
- Sets the invert state of this InstallComponent
- Parameters:
- invert - The new invert state
refresh
public boolean refresh(Vector targets,
String sharedPoolKey)
- Update this dependency. For example, if we
are on a Windows-based platform and this InstallComponent has
some children that should only be installed on SPARC-based
platforms, this would omit the inactive InstallComponent's information
(Destination table, whether it will install or not). In effect,
it halts any data-gathering operation that might otherwise be passed
down to its children. For a SoftwareComponent, this method searches
for it being "selected" by the user, and turns itself "off" if it is not
selected.
- Parameters:
- targets - The target properties (set via
setProperty()) to update.
- sharedPoolKey - the key used to access the list of already-visited shared components.
- Returns:
-
true if the refresh was sucessful, falseotherwise.
- Overrides:
- refresh in class InstallNode
addRuntimeResources
public void addRuntimeResources(Vector resourceVector)
- Add the required resources when this object is used in the Product Tree.
- Parameters:
- resourceVector - The vector containing all of the required resources
for this class
- Overrides:
- addRuntimeResources in class InstallNode
initialize
public boolean initialize(WizardState state)
- Initialize this object. For Platform Dependencies, all we have to do is check
the dependency in order to initialize.
- Parameters:
- state - The WizardState this object belongs to.
- Returns:
- Whether the initialization was successful or not.
- Overrides:
- initialize in class InstallNode
All Packages Class Hierarchy This Package Previous Next Index