public class Policy extends Object
Modifier and Type | Field and Description |
---|---|
static int |
RESTART_POLICY_FORCE
A constant indicating that restart should be forced (without
confirmation) immediately after completion of a provisioning operation.
|
static int |
RESTART_POLICY_FORCE_APPLY
A constant indicating that the changes should be applied dynamically
to the profile (without confirmation) immediately after completion of
a provisioning operation.
|
static int |
RESTART_POLICY_PROMPT
A constant indicating that the user should be prompted to
restart after completion of a provisioning operation.
|
static int |
RESTART_POLICY_PROMPT_RESTART_OR_APPLY
A constant indicating that, where possible, the user should
be given the option to restart or dynamically apply the changes
after completion of a provisioning operation.
|
static int |
UPDATE_STYLE_MULTIPLE_IUS
A constant indicating that the user should be presented with an
update wizard that shows a list of IUs that can be updated.
|
static int |
UPDATE_STYLE_SINGLE_IUS
A constant indicating that the user should be presented with an
update wizard that shows detail about a single IU that can be
updated.
|
Constructor and Description |
---|
Policy() |
Modifier and Type | Method and Description |
---|---|
boolean |
continueWorkingWithOperation(ProfileChangeOperation operation,
Shell shell)
Answer a boolean indicating whether the caller should continue to work with the
specified operation.
|
boolean |
getContactAllSites()
Get a boolean value indicating whether to contact all sites.
|
boolean |
getFilterOnEnv()
Return a boolean value indicating whether or not the list of available
software should be filtered based on the environment settings of the profile.
|
boolean |
getGroupByCategory()
Return a boolean indicating whether available software should be
grouped by category.
|
boolean |
getHideAlreadyInstalled()
Get a boolean value indicating whether to hide already installed units.
|
IStatus |
getNoProfileChosenStatus()
Return a status that can be used to describe the failure to
retrieve a profile.
|
boolean |
getRepositoriesVisible()
Return a boolean indicating whether the repositories should
be visible to the user, such that the user can add, remove, and
otherwise manipulate the software site list.
|
String |
getRepositoryPreferencePageId()
Get the id of the preference page that should be used to link to the
software sites page.
|
String |
getRepositoryPreferencePageName()
Get the localized name of the preference page that should be displayed in
links to the software sites page.
|
int |
getRestartPolicy()
Get the restart policy that should be used when the provisioning UI
determines that a restart is required.
|
boolean |
getShowDrilldownRequirements()
Return a boolean indicating whether the user should be allowed drill
down from a visible update or installed item into the requirements.
|
boolean |
getShowLatestVersionsOnly()
Return a boolean indicating whether only the latest versions of
updates and available software should be shown to the user.
|
Point |
getUpdateDetailsPreferredSize()
Get a point describing the preferred size of the details area
shown in single IU update wizards.
|
int |
getUpdateWizardStyle()
Get the update wizard style that should be used to determine
what to show the user when updates are available.
|
IQuery<IInstallableUnit> |
getVisibleAvailableIUQuery()
Return a query that can be used to obtain the IInstallableUnits that
should be presented to the user from the software repositories.
|
IQuery<IInstallableUnit> |
getVisibleInstalledIUQuery()
Return a query that can be used to obtain the IInstallableUnits in
the profile that should be presented to the user.
|
void |
setContactAllSites(boolean contactAll)
Set a boolean indicating whether all sites need to be contacted.
|
void |
setFilterOnEnv(boolean filterOnEnv)
Set a boolean value indicating whether or not the list of available
software should be filtered based on the environment settings of the profile.
|
void |
setGroupByCategory(boolean group)
Set a boolean indicating whether available software should be
grouped by category.
|
void |
setHideAlreadyInstalled(boolean hide)
Set a boolean indicating whether to hide already installed units.
|
void |
setRepositoriesVisible(boolean visible)
Set a boolean indicating whether the repositories should
be visible to the user, such that the user can add, remove, and
otherwise manipulate the software site list.
|
void |
setRepositoryPreferencePageId(String id)
Set the id of the preference page that should be used to link to the
software sites page.
|
void |
setRepositoryPreferencePageName(String name)
Set the localized name of the preference page that should be displayed in
links to the software sites page.
|
void |
setRestartPolicy(int restartPolicy)
Set the restart policy that should be used when the provisioning UI
determines that a restart is required.
|
void |
setShowDrilldownRequirements(boolean drilldown)
Set a boolean indicating whether the user should be allowed drill
down from a visible update or installed item into the requirements.
|
void |
setShowLatestVersionsOnly(boolean showLatest)
Set a boolean indicating whether only the latest versions of
updates and available software should be shown to the user.
|
void |
setUpdateDetailsPreferredSize(Point preferredSize)
Set the preferred size of the details area shown in update wizards which
notify the user of a single update.
|
void |
setUpdateWizardStyle(int updateWizardStyle)
Get the update wizard style that should be used to determine
what to show the user when updates are available.
|
void |
setVisibleAvailableIUQuery(IQuery<IInstallableUnit> query)
Set the query that can be used to obtain the IInstallableUnits that
should be presented to the user.
|
void |
setVisibleInstalledIUQuery(IQuery<IInstallableUnit> query)
Set the query that can be used to obtain the IInstallableUnits in
the profile that should be presented to the user.
|
public static final int RESTART_POLICY_FORCE
public static final int RESTART_POLICY_FORCE_APPLY
public static final int RESTART_POLICY_PROMPT
public static final int RESTART_POLICY_PROMPT_RESTART_OR_APPLY
public static final int UPDATE_STYLE_MULTIPLE_IUS
public static final int UPDATE_STYLE_SINGLE_IUS
public boolean continueWorkingWithOperation(ProfileChangeOperation operation, Shell shell)
operation
- the operation in question. It must already be resolved.shell
- the shell to use for any interaction with the usertrue
if processing of the operation should continue, false
if
not. It is up to the implementor to report any errors to the user when answering false
.public IStatus getNoProfileChosenStatus()
null
if there is no such status.public IQuery<IInstallableUnit> getVisibleAvailableIUQuery()
public void setVisibleAvailableIUQuery(IQuery<IInstallableUnit> query)
query
- the query used to retrieve user visible available IUspublic IQuery<IInstallableUnit> getVisibleInstalledIUQuery()
public void setVisibleInstalledIUQuery(IQuery<IInstallableUnit> query)
query
- the query used to retrieve user visible installed IUspublic int getRestartPolicy()
RESTART_POLICY_FORCE
,
RESTART_POLICY_FORCE_APPLY
,
RESTART_POLICY_PROMPT
,
RESTART_POLICY_PROMPT_RESTART_OR_APPLY
public void setRestartPolicy(int restartPolicy)
restartPolicy
- an integer constant describing the restart policyRESTART_POLICY_FORCE
,
RESTART_POLICY_FORCE_APPLY
,
RESTART_POLICY_PROMPT
,
RESTART_POLICY_PROMPT_RESTART_OR_APPLY
public boolean getRepositoriesVisible()
true
if repositories are visible to the end
user, false
if they are not.public void setRepositoriesVisible(boolean visible)
visible
- true
if repositories are visible to the end
user, false
if they are not.public boolean getShowLatestVersionsOnly()
true
if only the latest versions are shown,
false
if all versions should be shown.public void setShowLatestVersionsOnly(boolean showLatest)
showLatest
- true
if only the latest versions are shown,
false
if all versions should be shown.public boolean getShowDrilldownRequirements()
true
if drilldown is allowed,
false
if it is not.public void setShowDrilldownRequirements(boolean drilldown)
drilldown
- true
if drilldown is allowed,
false
if it is not.public boolean getFilterOnEnv()
true
if the results should be filtered
and false
otherwise.public void setFilterOnEnv(boolean filterOnEnv)
filterOnEnv
- true
if the results should be filtered
and false
otherwise.public boolean getGroupByCategory()
true
if items should be grouped by category,
false
if categories should not be shown.public void setGroupByCategory(boolean group)
group
- true
if items should be grouped by category,
false
if categories should not be shown.public String getRepositoryPreferencePageId()
null
if there is no
preference page id showing the software sites.public void setRepositoryPreferencePageId(String id)
id
- the preference page id, or null
if there is no
preference page id showing the software sites.public String getRepositoryPreferencePageName()
null
if there is no
preference page.public void setRepositoryPreferencePageName(String name)
name
- the preference page name, or null
if there is no
preference page.setRepositoryPreferencePageId(String)
public int getUpdateWizardStyle()
UPDATE_STYLE_SINGLE_IUS
,
UPDATE_STYLE_MULTIPLE_IUS
public void setUpdateWizardStyle(int updateWizardStyle)
updateWizardStyle
- an integer constant describing the update wizard styleUPDATE_STYLE_SINGLE_IUS
,
UPDATE_STYLE_MULTIPLE_IUS
public Point getUpdateDetailsPreferredSize()
UPDATE_STYLE_SINGLE_IUS
public void setUpdateDetailsPreferredSize(Point preferredSize)
preferredSize
- a Point describing the preferred sizeUPDATE_STYLE_SINGLE_IUS
public boolean getContactAllSites()
true
true if all sites need to be contacted,
false
otherwise.public void setContactAllSites(boolean contactAll)
contactAll
- true
if all sites need to be contacted,
false
otherwise.public boolean getHideAlreadyInstalled()
true
if already installed units are to be hidden,
false
otherwise.public void setHideAlreadyInstalled(boolean hide)
hide
- true
if already installed units need to be hidden,
false
otherwise.
Copyright (c) 2000, 2014 Eclipse Contributors and others. All rights reserved.Guidelines for using Eclipse APIs.