Overview | Package | Class | Tree | Deprecated | Index | Help
| Copyright © 2000, 2008, Oracle and/or its affiliates. All rights reserved.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bea.portal.tools.portal.controls
Interface PortletCategoryDefinitionControl

    @ControlInterface
    public interface PortletCategoryDefinitionControl

A custom control interface used to interact with portlet categories.

Method Summary
`void` | `addPortletDefinition(PortletDefinitionId portletId, PortletCategoryDefinitionId categoryId, ResourceContext context)` Adds a `PortletDefinitionId` to a portlet category.
`PortletCategoryDefinition` | `createCategory(String title, String description, PortletCategoryDefinitionId parentId, String webAppName, ResourceContext context)` Creates a persistent version of a `PortletCategoryDefinition` from the provided `PortletCategoryDefinition`.
`PortletCategoryDefinition` | `createRootCategory(String rootCategoryTitle, String rootCategoryDescription, String webAppName, ResourceContext context)` Creates and returns a ROOT category
`int` | `deleteCategory(PortletCategoryDefinitionId id, ResourceContext context)` Deletes all (including localized) versions of a category.
`void` | `deletePortletDefinition(PortletDefinitionId portletId, PortletCategoryDefinitionId categoryId, ResourceContext context)` Deletes a `PortletDefinitionId` from a portlet category.
`int` | `deletePortletDefinitions(PortletDefinitionId portletId, ResourceContext context)` Deletes a `PortletDefinitionId` from all portlet categories.
`SortableFilterablePagedResult<PortletCategoryDefinition>` | `getCategories(int pageSize, WebAppSearchCriteria criteria, ResourceContext context)` Returns a SortableFilterablePagedResult of `PortletCategoryDefinition`s corresponding to an array of `PortletCategoryDefinitionId`s.
`PortletCategoryDefinition` | `getCategory(PortletCategoryDefinitionId id, ResourceContext context)` Returns a `PortletCategoryDefinition` corresponding to a `PortletCategoryDefinitionId`.
`SortableFilterablePagedResult<PortletDefinition>` | `getNonCategorizedPortletDefinitions(int pageSize, WebAppSearchCriteria criteria, ResourceContext context)` Returns noncategorized `PortletDefinition`s.
`int` | `getPortletDefinitionCount(PortletCategoryDefinitionId id, ResourceContext context)` Returns the number of `PortletDefinition`s under category `pcdId`.
`SortableFilterablePagedResult<PortletDefinition>` | `getPortletDefinitions(int pageSize, PortletCategoryDefinitionId id, ResourceContext context)` Returns `PortletDefinition`s under the category `pcdId`.
`SortableFilterablePagedResult<PortletView>` | `getPortletViews(int pageSize, PortletCategoryDefinitionId id, ResourceContext context)` Returns `PortletView`s.
`PortletCategoryDefinition` | `getRootCategory(String webAppName, ResourceContext context)` Returns root of the PortletCategory hierarchy.
`SortableFilterablePagedResult<PortletCategoryDefinition>` | `getSubCategories(int pageSize, PortletCategoryDefinitionId id, WebAppSearchCriteria criteria, ResourceContext context)` Returns a SortableFilterablePagedResult of `PortletCategoryDefinition`s for subcategories of the category represented by `pcdId` If no definitions are found an empty SortableFilterablePagedResult is returned. Implementation has to ensure that repeated calls to this method return `PortletCategoryDefinition`s in a consistent order.
`int` | `getSubCategoryCount(PortletCategoryDefinitionId id, ResourceContext context)` Returns the number of immediate categories under category `pcdId`.

Method Detail

### createRootCategory

    PortletCategoryDefinition createRootCategory(String rootCategoryTitle,
                                                 String rootCategoryDescription,
                                                 String webAppName,
                                                 ResourceContext context)
                                                 throws ToolsException,
                                                        NotEntitledException,
                                                        MissingDataException,
                                                        ObjectNotFoundException

  Creates and returns a ROOT category

  Parameters
    `rootCategoryTitle` -
    `rootCategoryDescription` -
    `webAppName` -
    `context` - the resource context.
  Throws
    `ToolsException`
    `NotEntitledException`
    `MissingDataException`
    `ObjectNotFoundException`

### getRootCategory

    PortletCategoryDefinition getRootCategory(String webAppName,
                                              ResourceContext context)
                                              throws ObjectNotFoundException,
                                                     ToolsException

  Returns root of the PortletCategory hierarchy.

  Parameters
    `webAppName` -
    `context` - the resource context.
  Throws
    `ObjectNotFoundException`
    `ToolsException`

### getCategory

    PortletCategoryDefinition getCategory(PortletCategoryDefinitionId id,
                                          ResourceContext context)
                                          throws ToolsException,
                                                 ObjectNotFoundException

  Returns a `PortletCategoryDefinition` corresponding to a `PortletCategoryDefinitionId`.

  Parameters
    `id` - the portlet category definition id.
    `context` - the resource context.
  Throws
    `ToolsException`
    `ObjectNotFoundException`

### getCategories

    SortableFilterablePagedResult<PortletCategoryDefinition> getCategories(int pageSize,
                                                                           WebAppSearchCriteria criteria,
                                                                           ResourceContext context)
                                                                           throws ToolsException,
                                                                                  ObjectNotFoundException

  Returns a SortableFilterablePagedResult of `PortletCategoryDefinition`s corresponding to an array of `PortletCategoryDefinitionId`s.

  Parameters
    `pageSize` - the number of entries per page of the `SortableFilterablePagedResult`
    `criteria` - the search criteria, including the web app name
    `context` - the resource context.
  Returns
    an Iterator of pages. Each page will contain `pageSize` entries.
  Throws
    `ToolsException`
    `ObjectNotFoundException`

### getSubCategoryCount

    int getSubCategoryCount(PortletCategoryDefinitionId id,
                            ResourceContext context)
                            throws ToolsException

  Returns the number of immediate categories under category `pcdId`.

  Parameters
    `id` - the portlet category definition id.
    `context` - the resource context.
  Throws
    `ToolsException`

### getSubCategories

    SortableFilterablePagedResult<PortletCategoryDefinition> getSubCategories(int pageSize,
                                                                              PortletCategoryDefinitionId id,
                                                                              WebAppSearchCriteria criteria,
                                                                              ResourceContext context)
                                                                              throws ToolsException,
                                                                                     ObjectNotFoundException

  Returns a SortableFilterablePagedResult of `PortletCategoryDefinition`s for subcategories of the category represented by `pcdId` If no definitions are found an empty SortableFilterablePagedResult is returned.
  Implementation has to ensure that repeated calls to this method return `PortletCategoryDefinition`s in a consistent order.

  Parameters
    `pageSize` - the number of entries per page of the `SortableFilterablePagedResult`
    `id` - the portlet category definition id.
    `criteria` - the search criteria, including the web app name
    `context` - the resource context.
  Returns
    an Iterator of pages. Each page will contain `pageSize` entries.
  Throws
    `ToolsException`
    `ObjectNotFoundException`

### getPortletDefinitionCount

    int getPortletDefinitionCount(PortletCategoryDefinitionId id,
                                  ResourceContext context)
                                  throws ToolsException

  Returns the number of `PortletDefinition`s under category `pcdId`.

  Parameters
    `id` - the portlet category definition id.
    `context` - the resource context.
  Throws
    `ToolsException`

### getPortletDefinitions

    SortableFilterablePagedResult<PortletDefinition> getPortletDefinitions(int pageSize,
                                                                           PortletCategoryDefinitionId id,
                                                                           ResourceContext context)
                                                                           throws ToolsException

  Returns `PortletDefinition`s under the category `pcdId`. If no definitions are found an empty SortableFilterablePagedResult is returned.
  Use this method after getting the number of `PortletDefinition`s.
  Implementation has to ensure that repeated calls to this method return `PortletDefinition`s in a consistent order.

  Parameters
    `pageSize` - the number of entries per page of the `SortableFilterablePagedResult`
    `id` - the portlet category definition id.
    `context` - the resource context.
  Returns
    an Iterator of pages. Each page will contain `pageSize` entries.
  Throws
    `ToolsException`

### getPortletViews

    SortableFilterablePagedResult<PortletView> getPortletViews(int pageSize,
                                                               PortletCategoryDefinitionId id,
                                                               ResourceContext context)
                                                               throws ToolsException,
                                                                      ObjectNotFoundException

  Returns `PortletView`s. If no views are found an empty SortableFilterablePagedResult is returned.
  Use this method after getting the number of `PortletDefinition`s.
  Implementation has to ensure that repeated calls to this method return `PortletView`s in a consistent order.
  Same caveat as method getCategoryView applies.

  Parameters
    `pageSize` - the number of entries per page of the `SortableFilterablePagedResult`
    `id` - the portlet category definition id.
    `context` - the resource context.
  Returns
    an Iterator of pages. Each page will contain `pageSize` entries.
  Throws
    `ToolsException`
    `ObjectNotFoundException`

### addPortletDefinition

    void addPortletDefinition(PortletDefinitionId portletId,
                              PortletCategoryDefinitionId categoryId,
                              ResourceContext context)
                              throws ToolsException,
                                     NotEntitledException

  Adds a `PortletDefinitionId` to a portlet category.

  Parameters
    `portletId` - portlet definition id.
    `categoryId` - portlet category definition id.
    `context` - the resource context.
  Throws
    `ToolsException`
    `NotEntitledException`

### deletePortletDefinition

    void deletePortletDefinition(PortletDefinitionId portletId,
                                 PortletCategoryDefinitionId categoryId,
                                 ResourceContext context)
                                 throws ToolsException,
                                        NotEntitledException

  Deletes a `PortletDefinitionId` from a portlet category.

  Parameters
    `portletId` - portlet definition id.
    `categoryId` - portlet category definition id.
    `context` - the resource context.
  Throws
    `ToolsException`
    `NotEntitledException`

### deletePortletDefinitions

    int deletePortletDefinitions(PortletDefinitionId portletId,
                                 ResourceContext context)
                                 throws ToolsException,
                                        NotEntitledException

  Deletes a `PortletDefinitionId` from all portlet categories.

  Parameters
    `portletId` - portlet definition id.
    `context` - the resource context.
  Returns
    the number of instances deleted.
  Throws
    `ToolsException`
    `NotEntitledException`

### getNonCategorizedPortletDefinitions

    SortableFilterablePagedResult<PortletDefinition> getNonCategorizedPortletDefinitions(int pageSize,
                                                                                         WebAppSearchCriteria criteria,
                                                                                         ResourceContext context)
                                                                                         throws ToolsException

  Returns noncategorized `PortletDefinition`s. If no definitions are found an empty SortableFilterablePagedResult is returned.
  Use this method after getting the number of noncategorized `PortletDefinition`s.
  Implementation has to ensure that repeated calls to this method return `PortletDefinition`s in a consistent order.

  Parameters
    `pageSize` - the number of entries per page of the `SortableFilterablePagedResult`
    `criteria` - the criteria for the search, including web app name.
    `context` - the resource context.
  Returns
    an Iterator of pages. Each page will contain `pageSize` entries.
  Throws
    `ToolsException`

### createCategory

    PortletCategoryDefinition createCategory(String title,
                                             String description,
                                             PortletCategoryDefinitionId parentId,
                                             String webAppName,
                                             ResourceContext context)
                                             throws ToolsException,
                                                    NotEntitledException,
                                                    MissingDataException,
                                                    ObjectNotFoundException

  Creates a persistent version of a `PortletCategoryDefinition` from the provided `PortletCategoryDefinition`.

  Parameters
    `title` -
    `description` -
    `parentId` - parent category definition id.
    `webAppName` -
    `context` - the resource context.
  Throws
    `ToolsException`
    `NotEntitledException`
    `MissingDataException`
    `ObjectNotFoundException`

### deleteCategory

    int deleteCategory(PortletCategoryDefinitionId id,
                       ResourceContext context)
                       throws ToolsException,
                              NotEntitledException,
                              ObjectNotFoundException

  Deletes all (including localized) versions of a category. Also deletes all subcategories of category in question. This method attempts to clean up all related security policies on and under the deleted Category. To achieve this, the current web app MUST be set in the `ResourceContext` via the setWebApp() method, otherwise a `NoWebAppFoundException` is thrown.

  Parameters
    `id` - the category definition id.
    `context` - the resource context.
  Returns
    the number of categories deleted
  Throws
    `ToolsException`
    `NotEntitledException`
    `ObjectNotFoundException`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000, 2008, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its affiliates.
Other names may be trademarks of their respective owners.