org.rhq.enterprise.server.content
Class ContentUIManagerBean

java.lang.Object
  extended by org.rhq.enterprise.server.content.ContentUIManagerBean
All Implemented Interfaces:
ContentUIManagerLocal

public class ContentUIManagerBean
extends Object
implements ContentUIManagerLocal

Author:
Jason Dobies

Constructor Summary
ContentUIManagerBean()
           
 
Method Summary
 org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.InstalledPackageHistory> findInstalledPackageHistoryByCriteria(org.rhq.core.domain.auth.Subject subject, org.rhq.core.domain.criteria.InstalledPackageHistoryCriteria criteria)
          Returns a pagable list of all package events that have taken place on the given resource.
 org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.ContentServiceRequest> getContentRequestsWithNotStatus(org.rhq.core.domain.auth.Subject user, int resourceId, org.rhq.core.domain.content.ContentRequestStatus status, org.rhq.core.domain.util.PageControl pageControl)
          Returns a list of all content requests made against the specified resource that do not match the specified status.
 org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.ContentServiceRequest> getContentRequestsWithStatus(org.rhq.core.domain.auth.Subject user, int resourceId, org.rhq.core.domain.content.ContentRequestStatus status, org.rhq.core.domain.util.PageControl pageControl)
          Returns a list of all content requests made against the specified resource that match the specified status.
 org.rhq.core.domain.content.ContentServiceRequest getContentServiceRequest(int requestId)
          Retrieves a content request by its ID.
 org.rhq.core.domain.content.InstalledPackage getInstalledPackage(int id)
          Loads the installed package identified by the ID from the database.
 org.rhq.core.domain.content.InstalledPackageHistory getInstalledPackageHistory(int historyId)
          Retrieves a specific history entry by its ID.
 org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.InstalledPackageHistory> getInstalledPackageHistory(int contentServiceRequestId, org.rhq.core.domain.util.PageControl pc)
          Returns a list of installed package history entries that were created as a result of executing the indicated request.
 org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.InstalledPackageHistory> getInstalledPackageHistory(org.rhq.core.domain.auth.Subject subject, int resourceId, int generalPackageId, org.rhq.core.domain.util.PageControl pageControl)
           
 org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.InstalledPackageHistory> getInstalledPackageHistoryForResource(int resourceId, org.rhq.core.domain.util.PageControl pc)
          Returns a pagable list of all package events that have taken place on the given resource.
 org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.composite.PackageListItemComposite> getInstalledPackages(org.rhq.core.domain.auth.Subject user, int resourceId, Integer packageTypeFilterId, String packageVersionFilter, String search, org.rhq.core.domain.util.PageControl pageControl)
          Returns a list of all installed packages on the specified resource.
 List<org.rhq.core.domain.common.composite.IntegerOptionItem> getInstalledPackageTypes(org.rhq.core.domain.auth.Subject user, int resourceId)
           
 org.rhq.core.domain.content.composite.LoadedPackageBitsComposite getLoadedPackageBitsComposite(int packageVersionId)
          This will return a composite object that tells you if the actual content (the "bits") for a particular package version is loaded into inventory or not, and, if the content is loaded, whether or not that content is stored in the database.
 org.rhq.core.domain.content.PackageInstallationStep getPackageInstallationStep(int stepId)
          Retrieves a specific step entry by its ID.
 List<org.rhq.core.domain.content.PackageInstallationStep> getPackageInstallationSteps(int installedPackageHistoryId)
          Retrieves the individual steps executed during the specified package installation history.
 org.rhq.core.domain.content.PackageType getPackageType(int id)
          Loads the package type identified by the ID from the database.
 List<org.rhq.core.domain.content.PackageType> getPackageTypes()
           
 List<org.rhq.core.domain.content.PackageType> getPackageTypes(int resourceTypeId)
          Returns all package types that are available to the specified resource type.
 org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.PackageType> getPackageTypes(int resourceTypeId, org.rhq.core.domain.util.PageControl pageControl)
          Returns all package types that are available to the specified resource type in a page control.
 org.rhq.core.domain.content.PackageVersion getPackageVersion(int packageVersionId)
          Retrieves a package version by its ID.
 List<org.rhq.core.domain.content.composite.PackageVersionComposite> getPackageVersionComposites(org.rhq.core.domain.auth.Subject user, int[] packageVersionIds)
          Used to retrieve information about multiple packages to display to the user.
 org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.composite.PackageVersionComposite> getPackageVersionComposites(org.rhq.core.domain.auth.Subject user, int[] packageVersionIds, org.rhq.core.domain.util.PageControl pageControl)
          Used to retrieve information about multiple packages to display to the user.
 org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.composite.PackageVersionComposite> getPackageVersionCompositesByFilter(org.rhq.core.domain.auth.Subject user, int resourceId, String filter, org.rhq.core.domain.util.PageControl pc)
           
 org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.composite.PackageVersionComposite> getUpdatePackageVersionCompositesByFilter(org.rhq.core.domain.auth.Subject user, int resourceId, String filter, org.rhq.core.domain.util.PageControl pc)
           
 org.rhq.core.domain.content.composite.AdvisoryDetailsComposite loadAdvisoryDetailsComposite(org.rhq.core.domain.auth.Subject user, Integer advisoryId)
          Retrieves Advisory Details by its ID.
 org.rhq.core.domain.content.composite.PackageVersionComposite loadPackageVersionComposite(org.rhq.core.domain.auth.Subject user, int packageVersionId)
          Used to retrieve information about a package version to display to a user.
 org.rhq.core.domain.content.composite.PackageVersionComposite loadPackageVersionCompositeWithExtraProperties(org.rhq.core.domain.auth.Subject user, int packageVersionId)
          Used to retrieve information about a package version to display to a user.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ContentUIManagerBean

public ContentUIManagerBean()
Method Detail

getLoadedPackageBitsComposite

public org.rhq.core.domain.content.composite.LoadedPackageBitsComposite getLoadedPackageBitsComposite(int packageVersionId)
Description copied from interface: ContentUIManagerLocal
This will return a composite object that tells you if the actual content (the "bits") for a particular package version is loaded into inventory or not, and, if the content is loaded, whether or not that content is stored in the database.

Specified by:
getLoadedPackageBitsComposite in interface ContentUIManagerLocal
Parameters:
packageVersionId - the PackageVersion identifier
Returns:
indicates if the package version content is loaded and available
See Also:
LoadedPackageBitsComposite

getInstalledPackage

public org.rhq.core.domain.content.InstalledPackage getInstalledPackage(int id)
Description copied from interface: ContentUIManagerLocal
Loads the installed package identified by the ID from the database.

Specified by:
getInstalledPackage in interface ContentUIManagerLocal
Parameters:
id - identifies the installed package
Returns:
installed package if one exists; null otherwise

getPackageType

public org.rhq.core.domain.content.PackageType getPackageType(int id)
Description copied from interface: ContentUIManagerLocal
Loads the package type identified by the ID from the database.

Specified by:
getPackageType in interface ContentUIManagerLocal
Parameters:
id - package type to load
Returns:
package type if one exists for the ID; null otherwise

getPackageTypes

public List<org.rhq.core.domain.content.PackageType> getPackageTypes()
Specified by:
getPackageTypes in interface ContentUIManagerLocal
Returns:
all package types

getPackageTypes

public List<org.rhq.core.domain.content.PackageType> getPackageTypes(int resourceTypeId)
Description copied from interface: ContentUIManagerLocal
Returns all package types that are available to the specified resource type.

Specified by:
getPackageTypes in interface ContentUIManagerLocal
Parameters:
resourceTypeId - identifies the resource type
Returns:
set of package types

getPackageTypes

public org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.PackageType> getPackageTypes(int resourceTypeId,
                                                                                                  org.rhq.core.domain.util.PageControl pageControl)
Description copied from interface: ContentUIManagerLocal
Returns all package types that are available to the specified resource type in a page control.

Specified by:
getPackageTypes in interface ContentUIManagerLocal
Parameters:
resourceTypeId - identifies the resource type
pageControl - paging control
Returns:
pagable list of package types

getContentRequestsWithStatus

public org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.ContentServiceRequest> getContentRequestsWithStatus(org.rhq.core.domain.auth.Subject user,
                                                                                                                         int resourceId,
                                                                                                                         org.rhq.core.domain.content.ContentRequestStatus status,
                                                                                                                         org.rhq.core.domain.util.PageControl pageControl)
Description copied from interface: ContentUIManagerLocal
Returns a list of all content requests made against the specified resource that match the specified status.

Specified by:
getContentRequestsWithStatus in interface ContentUIManagerLocal
Parameters:
user - the user who is requesting the retrieval
resourceId - identifies the resource whose requests to retrieve
status - request status being matched
pageControl - pagination controller
Returns:
list of artifact requests for the specified resource

getContentRequestsWithNotStatus

public org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.ContentServiceRequest> getContentRequestsWithNotStatus(org.rhq.core.domain.auth.Subject user,
                                                                                                                            int resourceId,
                                                                                                                            org.rhq.core.domain.content.ContentRequestStatus status,
                                                                                                                            org.rhq.core.domain.util.PageControl pageControl)
Description copied from interface: ContentUIManagerLocal
Returns a list of all content requests made against the specified resource that do not match the specified status.

Specified by:
getContentRequestsWithNotStatus in interface ContentUIManagerLocal
Parameters:
user - the user who is requesting the retrieval
resourceId - identifies the resource whose requests to retrieve
status - request status to not match
pageControl - pagination controller
Returns:
list of content requests for the specified resource

getInstalledPackages

public org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.composite.PackageListItemComposite> getInstalledPackages(org.rhq.core.domain.auth.Subject user,
                                                                                                                              int resourceId,
                                                                                                                              Integer packageTypeFilterId,
                                                                                                                              String packageVersionFilter,
                                                                                                                              String search,
                                                                                                                              org.rhq.core.domain.util.PageControl pageControl)
Description copied from interface: ContentUIManagerLocal
Returns a list of all installed packages on the specified resource.

Specified by:
getInstalledPackages in interface ContentUIManagerLocal
Parameters:
user - the user who is requesting the retrieval
resourceId - identifies the resource whose requests to retrieve
search - string to search against filtering by name or description
pageControl - pagination controller
Returns:
pagable list of packages installed on the resource

getInstalledPackageTypes

public List<org.rhq.core.domain.common.composite.IntegerOptionItem> getInstalledPackageTypes(org.rhq.core.domain.auth.Subject user,
                                                                                             int resourceId)
Specified by:
getInstalledPackageTypes in interface ContentUIManagerLocal

getInstalledPackageHistory

public org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.InstalledPackageHistory> getInstalledPackageHistory(org.rhq.core.domain.auth.Subject subject,
                                                                                                                         int resourceId,
                                                                                                                         int generalPackageId,
                                                                                                                         org.rhq.core.domain.util.PageControl pageControl)
Specified by:
getInstalledPackageHistory in interface ContentUIManagerLocal

getPackageVersionCompositesByFilter

public org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.composite.PackageVersionComposite> getPackageVersionCompositesByFilter(org.rhq.core.domain.auth.Subject user,
                                                                                                                                            int resourceId,
                                                                                                                                            String filter,
                                                                                                                                            org.rhq.core.domain.util.PageControl pc)
Specified by:
getPackageVersionCompositesByFilter in interface ContentUIManagerLocal

getUpdatePackageVersionCompositesByFilter

public org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.composite.PackageVersionComposite> getUpdatePackageVersionCompositesByFilter(org.rhq.core.domain.auth.Subject user,
                                                                                                                                                  int resourceId,
                                                                                                                                                  String filter,
                                                                                                                                                  org.rhq.core.domain.util.PageControl pc)
Specified by:
getUpdatePackageVersionCompositesByFilter in interface ContentUIManagerLocal

loadPackageVersionComposite

public org.rhq.core.domain.content.composite.PackageVersionComposite loadPackageVersionComposite(org.rhq.core.domain.auth.Subject user,
                                                                                                 int packageVersionId)
Description copied from interface: ContentUIManagerLocal
Used to retrieve information about a package version to display to a user.

Specified by:
loadPackageVersionComposite in interface ContentUIManagerLocal
Parameters:
user - user who wants to see the information
packageVersionId - identifies what package version to return info on
Returns:
the information on the package version

loadPackageVersionCompositeWithExtraProperties

public org.rhq.core.domain.content.composite.PackageVersionComposite loadPackageVersionCompositeWithExtraProperties(org.rhq.core.domain.auth.Subject user,
                                                                                                                    int packageVersionId)
Description copied from interface: ContentUIManagerLocal
Used to retrieve information about a package version to display to a user. This call will also load the extra properties configuration object on the package version.

Specified by:
loadPackageVersionCompositeWithExtraProperties in interface ContentUIManagerLocal
Parameters:
user - user who wants to see the information
packageVersionId - identifies what package version to return info on
Returns:
the information on the package version

getPackageVersionComposites

public List<org.rhq.core.domain.content.composite.PackageVersionComposite> getPackageVersionComposites(org.rhq.core.domain.auth.Subject user,
                                                                                                       int[] packageVersionIds)
Description copied from interface: ContentUIManagerLocal
Used to retrieve information about multiple packages to display to the user.

Specified by:
getPackageVersionComposites in interface ContentUIManagerLocal
Parameters:
user - user who wants to see the information
packageVersionIds - identifies what package versions to return info on
Returns:
package version information for each package identified

loadAdvisoryDetailsComposite

public org.rhq.core.domain.content.composite.AdvisoryDetailsComposite loadAdvisoryDetailsComposite(org.rhq.core.domain.auth.Subject user,
                                                                                                   Integer advisoryId)
Description copied from interface: ContentUIManagerLocal
Retrieves Advisory Details by its ID. One and only one must exist for the ID;

Specified by:
loadAdvisoryDetailsComposite in interface ContentUIManagerLocal
Parameters:
user - user who wants to see the information
advisoryId - identifier for advisory
Returns:
AdvisoryDetailsComposite entity

getPackageVersionComposites

public org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.composite.PackageVersionComposite> getPackageVersionComposites(org.rhq.core.domain.auth.Subject user,
                                                                                                                                    int[] packageVersionIds,
                                                                                                                                    org.rhq.core.domain.util.PageControl pageControl)
Description copied from interface: ContentUIManagerLocal
Used to retrieve information about multiple packages to display to the user.

Specified by:
getPackageVersionComposites in interface ContentUIManagerLocal
Parameters:
user - user who wants to see the information
packageVersionIds - identifies what package versions to return info on
pageControl - pagination controller
Returns:
package version information for each package identified

getPackageVersion

public org.rhq.core.domain.content.PackageVersion getPackageVersion(int packageVersionId)
Description copied from interface: ContentUIManagerLocal
Retrieves a package version by its ID. One and only one package version must exist for the ID; an error will be thrown if exactly one package version is not found.

Specified by:
getPackageVersion in interface ContentUIManagerLocal
Parameters:
packageVersionId - identifies the package version
Returns:
package version entity

getContentServiceRequest

public org.rhq.core.domain.content.ContentServiceRequest getContentServiceRequest(int requestId)
Description copied from interface: ContentUIManagerLocal
Retrieves a content request by its ID. One and only one content request must exist for the ID; an error will be thrown if exactly one content request is not found.

Specified by:
getContentServiceRequest in interface ContentUIManagerLocal
Parameters:
requestId - identifies the request
Returns:
content request entity

getInstalledPackageHistory

public org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.InstalledPackageHistory> getInstalledPackageHistory(int contentServiceRequestId,
                                                                                                                         org.rhq.core.domain.util.PageControl pc)
Description copied from interface: ContentUIManagerLocal
Returns a list of installed package history entries that were created as a result of executing the indicated request.

Specified by:
getInstalledPackageHistory in interface ContentUIManagerLocal
Parameters:
contentServiceRequestId - identifies the request that caused the history entries
pc - pagination controller
Returns:
list of history entries

getInstalledPackageHistory

public org.rhq.core.domain.content.InstalledPackageHistory getInstalledPackageHistory(int historyId)
Description copied from interface: ContentUIManagerLocal
Retrieves a specific history entry by its ID. One and only one history entry must exist for the ID; an error will be thrown if exactly one history entry is not found.

Specified by:
getInstalledPackageHistory in interface ContentUIManagerLocal
Parameters:
historyId - identifies the history entry
Returns:
history entry

getPackageInstallationSteps

public List<org.rhq.core.domain.content.PackageInstallationStep> getPackageInstallationSteps(int installedPackageHistoryId)
Description copied from interface: ContentUIManagerLocal
Retrieves the individual steps executed during the specified package installation history.

Specified by:
getPackageInstallationSteps in interface ContentUIManagerLocal
Parameters:
installedPackageHistoryId - identifies the history entry
Returns:
list of steps; empty list if there were no steps reported

getPackageInstallationStep

public org.rhq.core.domain.content.PackageInstallationStep getPackageInstallationStep(int stepId)
Description copied from interface: ContentUIManagerLocal
Retrieves a specific step entry by its ID.

Specified by:
getPackageInstallationStep in interface ContentUIManagerLocal
Parameters:
stepId - identifies the step to retrieve
Returns:
step entry

getInstalledPackageHistoryForResource

public org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.InstalledPackageHistory> getInstalledPackageHistoryForResource(int resourceId,
                                                                                                                                    org.rhq.core.domain.util.PageControl pc)
Description copied from interface: ContentUIManagerLocal
Returns a pagable list of all package events that have taken place on the given resource.

Specified by:
getInstalledPackageHistoryForResource in interface ContentUIManagerLocal
Parameters:
resourceId - must refer to a valid resource in the database
pc - pagination controller
Returns:
pagable list of package change items; will not be null

findInstalledPackageHistoryByCriteria

public org.rhq.core.domain.util.PageList<org.rhq.core.domain.content.InstalledPackageHistory> findInstalledPackageHistoryByCriteria(org.rhq.core.domain.auth.Subject subject,
                                                                                                                                    org.rhq.core.domain.criteria.InstalledPackageHistoryCriteria criteria)
Description copied from interface: ContentUIManagerLocal
Returns a pagable list of all package events that have taken place on the given resource.

Specified by:
findInstalledPackageHistoryByCriteria in interface ContentUIManagerLocal
Returns:
pagable list of package change items; will not be null


Copyright © 2008-2012 Red Hat, Inc.. All Rights Reserved.