com.bea.apps.groupspace.controls.generic
Interface ContentControlBase<T extends ContentBase,V extends FolderBase>

All Known Subinterfaces:
AnnouncementsControl, CM_Control<T>, CmBrowserControl, CmBrowserFoldersControl, FeedEntriesControl, FeedFoldersControl, FoldersControl, FoldersControlBase<T,V>, GroupSpaceContentControl<T>, GsDocControl, IssuesControl, LinksControl, RichTextControl, SavedSearchControl
All Known Implementing Classes:
AnnouncementsControlImpl, CM_ControlImpl, CmBrowserControlImpl, CmBrowserFoldersControlImpl, ContentControlBaseImpl, FeedEntriesControlImpl, FeedFoldersControlImpl, FoldersControlBaseImpl, FoldersControlImpl, GroupSpaceContentControlImpl, GsDocControlImpl, IssuesControlImpl, LinksControlImpl, RichTextControlImpl, SavedSearchControlImpl

public interface ContentControlBase<T extends ContentBase,V extends FolderBase>

Copyright (c) 2005-2006 by BEA Systems, Inc. All Rights Reserved.

Defines general operations for dealing with CM content.

This class is meant to be used OUTSIDE of a GroupSpace community, since it will bypass GroupSpace security/role mappings

Declarative instantiation (@Control fooControl;) from a PageFlow or from another control is the preferred method of instantiating controls (as this will supply the control a proper Control Container Context (CCC)). Should the control be instantiated programmatically, from a different context or with an application scope (rather than webapp), extra measures should be taken:


Nested Class Summary
static class ContentControlBase.NodeSearchType
           
static interface ContentControlBase.Params
           
 
Method Summary
 ObjectClass createObjectClass()
          Creates an ObjectClass for the given control
 Set<T> createObjects(Node[] nodes)
          Create a collection of things of type T from an array of Nodes
 Set<T> createObjects(Set<Node> nodes)
          Create a collection of things of type T from a set of Nodes
 T findById(String nodeIdString)
          Find an item of type T based on its Node ID.
 ContentBase findContentById(String nodeIdString)
          Find ANY item based on its Node ID.
 SortableFilterablePagedResult<T> findMany(String expression, String[] searchPaths)
          Retrieve a set of things based on properties in an expression.
 SortableFilterablePagedResult<T> findMany(String expression, String[] searchPaths, SortCriteria[] sortCriteria)
          Retrieve a set of things based on properties in an expression.
 SortableFilterablePagedResult<T> findManyChildren(String expression)
           
 List<PropertyDefinition> getAllPropertyDefinitions()
           
 String getDefaultStringValue(String propertyName)
           
 V getFolder(ID folderId)
          Get Folder of type V of the Node with the supplied ID.
 Set<ContentBase> getImmediateChildren(V parentFolder, ContentControlBase.NodeSearchType type)
          Get the immediate children of this item as a set.
 Set<ContentBase> getImmediateChildren(V parentFolder, SortCriteria[] sortCriteria, ContentControlBase.NodeSearchType type)
          Get the immediate children of this item as a set.
 SortableFilterablePagedResult<ContentBase> getImmediateChildrenAsPagedResult(Node node, SortCriteria[] sortCriteria, ContentControlBase.NodeSearchType hierarchySearchType)
          Get the immediate children of this item as a paged result.
 ObjectClass getObjectClass()
          Return the object class associated with the thing T
 V getTopFolder()
          Get the top-level node of each data type (eg, top Links folder)
 Node getTopNode()
          Get the top-level node of each data type (eg, top Links folder)
 T move(ID source, ID newParent)
          Move Node identified by source ID to destination specified by newParent ID
 T move(String source, String newParent)
          Move Node identified by source id string to destination specified by newParent id string
 void remove(Node node)
          Remove the node
 void remove(Set<T> things)
          Remove the Set of things T
 void remove(T thing)
          Remove the thing T
 void removeAll()
          Remove all
 void update(Set<T> things)
          Update a Set of existing things
 void update(T thing)
          Update an existing thing
 

Method Detail

createObjects

Set<T> createObjects(Node[] nodes)
                                         throws AuthorizationException
Create a collection of things of type T from an array of Nodes

Throws
AuthorizationException

createObjects

Set<T> createObjects(Set<Node> nodes)
                                         throws AuthorizationException
Create a collection of things of type T from a set of Nodes

Throws
AuthorizationException

createObjectClass

ObjectClass createObjectClass()
                              throws NoSuchNodeException,
                                     RepositoryException,
                                     AuthorizationException
Creates an ObjectClass for the given control

Throws
NoSuchNodeException
RepositoryException
AuthorizationException - throws ControlException - unchecked exception that wraps InstantiationException, IllegalAccessException, InvocationTargetException, NodeMapper.NodeMapperException, AuthenticationException, NoSuchNodeException

getObjectClass

ObjectClass getObjectClass()
                           throws AuthorizationException,
                                  NoSuchObjectClassException,
                                  RepositoryException
Return the object class associated with the thing T

Throws
RepositoryException
AuthorizationException
NoSuchObjectClassException

getTopNode

Node getTopNode()
                throws RepositoryException,
                       AuthorizationException
Get the top-level node of each data type (eg, top Links folder)

Throws
RepositoryException
AuthorizationException - throws ControlException - unchecked exception that wraps InstantiationException, IllegalAccessException, InvocationTargetException, NodeMapper.NodeMapperException, AuthenticationException, NoSuchNodeException

getFolder

V getFolder(ID folderId)
                               throws AuthorizationException,
                                      NoSuchNodeException,
                                      RepositoryException
Get Folder of type V of the Node with the supplied ID.

Throws
AuthorizationException
NoSuchNodeException
RepositoryException

findManyChildren

SortableFilterablePagedResult<T> findManyChildren(String expression)
                                                                      throws AuthorizationException,
                                                                             NoSuchNodeException,
                                                                             RepositoryException
Throws
AuthorizationException
NoSuchNodeException
RepositoryException

findMany

SortableFilterablePagedResult<T> findMany(String expression,
                                          String[] searchPaths)
                                                              throws AuthorizationException,
                                                                     NoSuchNodeException,
                                                                     RepositoryException
Retrieve a set of things based on properties in an expression. Returns null if none are found.

Throws
AuthorizationException
NoSuchNodeException
RepositoryException

findMany

SortableFilterablePagedResult<T> findMany(String expression,
                                          String[] searchPaths,
                                          SortCriteria[] sortCriteria)
                                                              throws RepositoryException,
                                                                     AuthorizationException
Retrieve a set of things based on properties in an expression. Returns null if none are found.

Throws
RepositoryException
AuthorizationException - throws ControlException - unchecked exception that wraps InstantiationException, IllegalAccessException, InvocationTargetException, NodeMapper.NodeMapperException, AuthenticationException, NoSuchNodeException

update

void update(T thing)
            throws NoSuchNodeException,
                   RepositoryException,
                   AuthorizationException
Update an existing thing

Throws
RepositoryException
AuthorizationException - throws ControlException - unchecked exception that wraps AuthenticationException, NoSuchPropertyException, InstantiationException, IllegalAccessException, InvocationTargetException, NodeMapper.NodeMapperException, IOException
NoSuchNodeException

update

void update(Set<T> things)
            throws NoSuchNodeException,
                   RepositoryException,
                   AuthorizationException
Update a Set of existing things

Throws
RepositoryException
AuthorizationException - throws ControlException - unchecked exception that wraps AuthenticationException, NoSuchPropertyException, InstantiationException, IllegalAccessException, InvocationTargetException, NodeMapper.NodeMapperException, IOException
NoSuchNodeException

getTopFolder

V getTopFolder()
                                  throws RepositoryException,
                                         AuthorizationException
Get the top-level node of each data type (eg, top Links folder)

Throws
RepositoryException
AuthorizationException - throws ControlException - unchecked exception that wraps InstantiationException, IllegalAccessException, InvocationTargetException, NodeMapper.NodeMapperException, AuthenticationException, NoSuchNodeException

removeAll

void removeAll()
               throws RepositoryException,
                      AuthorizationException
Remove all

Throws
RepositoryException
AuthorizationException - throws ControlException - unchecked exception that wraps InstantiationException, IllegalAccessException, InvocationTargetException, NodeMapper.NodeMapperException, AuthenticationException, NoSuchNodeException

remove

void remove(T thing)
            throws RepositoryException,
                   AuthorizationException
Remove the thing T

Throws
RepositoryException
AuthorizationException - throws ControlException - unchecked exception that wraps AuthenticationException

remove

void remove(Node node)
            throws RepositoryException,
                   AuthorizationException
Remove the node

Throws
RepositoryException
AuthorizationException - throws ControlException - unchecked exception that wraps AuthenticationException

remove

void remove(Set<T> things)
            throws RepositoryException,
                   AuthorizationException
Remove the Set of things T

Throws
RepositoryException
AuthorizationException - throws ControlException - unchecked exception that wraps AuthenticationException

getImmediateChildren

Set<ContentBase> getImmediateChildren(V parentFolder,
                                      ContentControlBase.NodeSearchType type)
                                      throws AuthorizationException,
                                             NoSuchNodeException,
                                             RepositoryException
Get the immediate children of this item as a set. Returns null if none are found.

Throws
AuthorizationException
NoSuchNodeException
RepositoryException

getImmediateChildren

Set<ContentBase> getImmediateChildren(V parentFolder,
                                      SortCriteria[] sortCriteria,
                                      ContentControlBase.NodeSearchType type)
                                      throws AuthorizationException,
                                             NoSuchNodeException,
                                             RepositoryException
Get the immediate children of this item as a set. Returns null if none are found.

Throws
AuthorizationException
NoSuchNodeException
RepositoryException

getImmediateChildrenAsPagedResult

SortableFilterablePagedResult<ContentBase> getImmediateChildrenAsPagedResult(Node node,
                                                                             SortCriteria[] sortCriteria,
                                                                             ContentControlBase.NodeSearchType hierarchySearchType)
                                                                             throws AuthorizationException,
                                                                                    NoSuchNodeException,
                                                                                    RepositoryException
Get the immediate children of this item as a paged result. Returns null if none are found. returns a collection of both types T & V

Throws
AuthorizationException
NoSuchNodeException
RepositoryException

move

T move(ID source,
       ID newParent)
                           throws NoSuchNodeException,
                                  RepositoryException,
                                  AuthorizationException
Move Node identified by source ID to destination specified by newParent ID

Throws
RepositoryException
AuthorizationException
NoSuchNodeException - throws ControlException - unchecked exception that wraps AuthenticationException

move

T move(String source,
       String newParent)
                           throws NoSuchNodeException,
                                  RepositoryException,
                                  AuthorizationException
Move Node identified by source id string to destination specified by newParent id string

Throws
RepositoryException
AuthorizationException
NoSuchNodeException - throws ControlException - unchecked exception that wraps AuthenticationException

findById

T findById(String nodeIdString)
                               throws RepositoryException,
                                      AuthorizationException
Find an item of type T based on its Node ID. Throws NoSuchNodeException if nothing is found.

Throws
RepositoryException
AuthorizationException - throws ControlException - unchecked exception that wraps InstantiationException, IllegalAccessException, InvocationTargetException, NodeMapper.NodeMapperException, AuthenticationException, NoSuchNodeException

findContentById

ContentBase findContentById(String nodeIdString)
                            throws RepositoryException,
                                   AuthorizationException
Find ANY item based on its Node ID. Throws NoSuchNodeException if nothing is found.

Throws
RepositoryException
AuthorizationException - throws ControlException - unchecked exception that wraps InstantiationException, IllegalAccessException, InvocationTargetException, NodeMapper.NodeMapperException, AuthenticationException, NoSuchNodeException

getAllPropertyDefinitions

List<PropertyDefinition> getAllPropertyDefinitions()
                                                   throws AuthorizationException,
                                                          NoSuchObjectClassException,
                                                          RepositoryException
Throws
AuthorizationException
NoSuchObjectClassException
RepositoryException

getDefaultStringValue

String getDefaultStringValue(String propertyName)
                             throws RepositoryException
Throws
RepositoryException


Copyright © 2006 BEA Systems, Inc. All Rights Reserved