lumis.portal.channel
Interface IChannelManager

Package class diagram package IChannelManager
All Superinterfaces:
IConfigKeyChecker
All Known Implementing Classes:
ChannelManager

@StableMinor(version="4.1",
             sinceVersion="4.0")
public interface IChannelManager
extends IConfigKeyChecker

Manager responsible for channel-related operations

Since:
4.0.0

Method Summary
 String add(SessionConfig sessionConfig, ChannelConfig channelConfig, ITransaction transaction)
          Add a Channel.
 void addCssLink(SessionConfig sessionConfig, String channelId, String cssId, int position, ITransaction transaction)
          Add the hyperlink to the channel's CSS file.
 void addOrUpdate(SessionConfig sessionConfig, ChannelConfig channelConfig, ITransaction transaction)
          Add or Update a Channel, depending on its previous existence.
 void clearCache(SessionConfig sessionConfig, String channelId, ITransaction transaction)
          Clear the Channel cache.
 String copy(SessionConfig sessionConfig, String sourceChannelId, String destinationParentChannelId, ITransaction transaction)
          Creates a new channel by copying source channel's properties and structure into destination's parent channel.
 void delete(SessionConfig sessionConfig, String channelId, ITransaction transaction)
          Delete the Channel.
 void deleteCssLink(SessionConfig sessionConfig, String channelId, String cssId, ITransaction transaction)
          Delete the hyperlink to the channel's CSS file.
 String deserialize(SessionConfig sessionConfig, DeserializationConfig deserializationConfig, Node channelNode, ITransaction transaction)
           
 void deserializeCss(SessionConfig sessionConfig, DeserializationConfig deserializationConfig, Node cssLinksNodes, ITransaction transaction)
           
 void deserializeSecondPass(SessionConfig sessionConfig, DeserializationConfig deserializationConfig, Node channelNode, ITransaction transaction)
          Perfoms the second pass of the channels deserialization
 ChannelConfig get(SessionConfig sessionConfig, String channelId, ITransaction transaction)
          Get the Channel's configuration.
 int getCachePages(SessionConfig sessionConfig, ChannelConfig channelConfig, ITransaction transaction)
           
 boolean getCenterPages(SessionConfig sessionConfig, ChannelConfig channelConfig, ITransaction transaction)
          Get a boolean indicating wheter the page must be centralized.
 int getChannelTreeCount(String rootChannelId, ITransaction transaction)
          Returns the number of channels in the tree for which the root is the given channelId.
 List<String> getChannelTreeIds(String rootChannelId, ITransaction transaction)
          Returns all the ids of channels in the tree for which the root is the given channelId.
 List<String> getCssIds(SessionConfig sessionConfig, String channelId, ITransaction transaction)
          Get a list of CSS Ids of the Channel.
 List<String> getCssIdsRecursively(SessionConfig sessionConfig, String channelId, ITransaction transaction)
          Get a list of Css Ids of the Channel including inherited Css.
 String getFriendlyPath(SessionConfig sessionConfig, String channelId, ITransaction transaction)
          Get the friendly path of a channel.
 Collection<String> getIdsByPageTemplateId(SessionConfig sessionConfig, String pageTemplateId, ITransaction transaction)
          Retrieves the Ids of all channel that uses the specified page template as default page template
 List<String> getIdsByParentChannelId(SessionConfig sessionConfig, String channelId, ITransaction transaction)
          Get a list of sub channel's id given the parent Channel's id.
 List<String> getIdsByParentTemplateId(SessionConfig sessionConfig, String parentTemplateId, ITransaction transaction)
          Retrieves the Ids of all channel that uses the specified channel template.
 List<String> getMetaTagIdsRecursively(SessionConfig sessionConfig, String channelId, ITransaction transaction)
          Get a list of meta-tags ids of the Channel including inherit Meta-tag.
 String getPageTemplateIdRecursively(SessionConfig sessionConfig, String channelId, ITransaction transaction)
          Returns the PageTemplateId for the specified channel (local or inherited from a parent channel)
 String getPath(SessionConfig sessionConfig, String channelId, boolean localizable, ITransaction transaction)
          Get the full path of the Channel.
 String getPath(SessionConfig sessionConfig, String channelId, ITransaction transaction)
          Get the full path of the Channel.
 List<String> getPathIds(SessionConfig sessionConfig, String channelId, ITransaction transaction)
          Get Ids of channel and its parents.
 List<String> getPathNames(SessionConfig sessionConfig, String channelId, boolean localizable, ITransaction transaction)
          Returns a list of strings each representing the name of the channel between the root portal channel and the channel solicited.
 int getProtocolType(SessionConfig sessionConfig, ChannelConfig channelConfig, ITransaction transaction)
          Returns the protocolType of the given channel.
 void serialize(SessionConfig sessionConfig, String channelId, OutputStream outputStream, ITransaction transaction)
           
 void serializeCss(SessionConfig sessionConfig, String channelId, OutputStream outputStream, ITransaction transaction)
           
 void update(SessionConfig sessionConfig, ChannelConfig channelConfig, ITransaction transaction)
          Update the Channel.
 
Methods inherited from interface lumis.portal.serialization.operation.IConfigKeyChecker
keyExists
 

Method Detail

addOrUpdate

void addOrUpdate(SessionConfig sessionConfig,
                 ChannelConfig channelConfig,
                 ITransaction transaction)
                 throws ManagerException,
                        PortalException
Add or Update a Channel, depending on its previous existence.

Parameters:
sessionConfig -
channelConfig -
transaction -
Throws:
ManagerException
PortalException

add

String add(SessionConfig sessionConfig,
           ChannelConfig channelConfig,
           ITransaction transaction)
           throws ManagerException,
                  PortalException
Add a Channel. To access this method, the user needs the PERMISSION_TYPE_FULL_CONTROL permission in the parent channel.

Parameters:
sessionConfig -
channelConfig -
transaction -
Returns:
a String.
Throws:
ManagerException
PortalException

copy

String copy(SessionConfig sessionConfig,
            String sourceChannelId,
            String destinationParentChannelId,
            ITransaction transaction)
            throws ManagerException,
                   PortalException
Creates a new channel by copying source channel's properties and structure into destination's parent channel. Does not allow the creation of a new Channel based on the "Portal" channel.

Parameters:
sessionConfig -
sourceChannelId -
destinationParentChannelId -
transaction -
Returns:
Throws:
ManagerException
PortalException

get

ChannelConfig get(SessionConfig sessionConfig,
                  String channelId,
                  ITransaction transaction)
                  throws ManagerException,
                         PortalException
Get the Channel's configuration. To access this method, the user needs the PERMISSION_TYPE_VIEW_CHANNEL permission.

Parameters:
sessionConfig - the user's session information.
channelId - the channelId.
transaction - the transaction for persistence access.
Returns:
the channel.
Throws:
PortalObjectNotFoundException - if the channel was not found.
ManagerException
PortalException

delete

void delete(SessionConfig sessionConfig,
            String channelId,
            ITransaction transaction)
            throws ManagerException,
                   PortalException
Delete the Channel. To access this method, the user needs the PERMISSION_TYPE_FULL_CONTROL permission.

Parameters:
sessionConfig - The session information of the user.
channelId -
transaction -
Throws:
ManagerException
PortalException

update

void update(SessionConfig sessionConfig,
            ChannelConfig channelConfig,
            ITransaction transaction)
            throws ManagerException,
                   PortalException
Update the Channel. To access this method, the user needs the PERMISSION_TYPE_FULL_CONTROL permission.

Parameters:
sessionConfig - The session information of the user.
channelConfig -
transaction -
Throws:
ManagerException
PortalException

getPath

String getPath(SessionConfig sessionConfig,
               String channelId,
               ITransaction transaction)
               throws ManagerException,
                      PortalException
Get the full path of the Channel. To access this method, the user needs the PERMISSION_TYPE_VIEW_CHANNEL permission.

Parameters:
sessionConfig - The session information of the user.
channelId -
transaction -
Returns:
a String.
Throws:
ManagerException
PortalException

getPath

String getPath(SessionConfig sessionConfig,
               String channelId,
               boolean localizable,
               ITransaction transaction)
               throws ManagerException,
                      PortalException
Get the full path of the Channel. To access this method, the user needs the PERMISSION_TYPE_VIEW_CHANNEL permission.

Parameters:
sessionConfig - The session information of the user.
channelId -
localizable - TODO
transaction -
Returns:
a String.
Throws:
ManagerException
PortalException

getFriendlyPath

String getFriendlyPath(SessionConfig sessionConfig,
                       String channelId,
                       ITransaction transaction)
                       throws ManagerException,
                              PortalException
Get the friendly path of a channel. The friendly path is generated according to the configuration in the channel.

Parameters:
sessionConfig - The session information of the user. the identification of the user.
channelId - the identification of the channel.
transaction - the transaction for persistence access.
Returns:
the generated path.
Throws:
ManagerException
PortalException
See Also:
ChannelConfig.FRIENDLY_PATH_TYPE_CHANNEL_NAME, ChannelConfig.FRIENDLY_PATH_TYPE_INHERIT, ChannelConfig.FRIENDLY_PATH_TYPE_USER_DEFINED

getIdsByParentChannelId

List<String> getIdsByParentChannelId(SessionConfig sessionConfig,
                                     String channelId,
                                     ITransaction transaction)
                                     throws ManagerException,
                                            PortalException
Get a list of sub channel's id given the parent Channel's id. To access this method, the user needs the PERMISSION_TYPE_VIEW_CHANNEL permission.

Parameters:
sessionConfig - The session information of the user.
channelId -
transaction -
Returns:
an array of strings.
Throws:
ManagerException
PortalException

getPathIds

List<String> getPathIds(SessionConfig sessionConfig,
                        String channelId,
                        ITransaction transaction)
                        throws ManagerException,
                               PortalException
Get Ids of channel and its parents. To access this method, the user needs the PERMISSION_TYPE_VIEW_CHANNEL permission.

Parameters:
sessionConfig - The session information of the user.
channelId -
transaction -
Returns:
an array of Strings.
Throws:
ManagerException
PortalException

addCssLink

void addCssLink(SessionConfig sessionConfig,
                String channelId,
                String cssId,
                int position,
                ITransaction transaction)
                throws ManagerException,
                       PortalException
Add the hyperlink to the channel's CSS file. To access this method, the user needs the PERMISSION_TYPE_PAGES_LAYOUT permission.

Parameters:
sessionConfig - The session information of the user.
channelId -
cssId -
position -
transaction -
Throws:
ManagerException
PortalException

deleteCssLink

void deleteCssLink(SessionConfig sessionConfig,
                   String channelId,
                   String cssId,
                   ITransaction transaction)
                   throws ManagerException,
                          PortalException
Delete the hyperlink to the channel's CSS file. To access this method, the user needs the PERMISSION_TYPE_PAGES_LAYOUT permission.

Parameters:
sessionConfig - The session information of the user.
channelId -
cssId -
transaction -
Throws:
ManagerException
PortalException

getCssIds

List<String> getCssIds(SessionConfig sessionConfig,
                       String channelId,
                       ITransaction transaction)
                       throws ManagerException,
                              PortalException
Get a list of CSS Ids of the Channel.

Parameters:
sessionConfig - The session information of the user.
channelId -
transaction -
Returns:
an array of Strings.
Throws:
ManagerException
PortalException

getCssIdsRecursively

List<String> getCssIdsRecursively(SessionConfig sessionConfig,
                                  String channelId,
                                  ITransaction transaction)
                                  throws ManagerException,
                                         PortalException
Get a list of Css Ids of the Channel including inherited Css.

Parameters:
sessionConfig - The session information of the user.
channelId -
transaction -
Returns:
an array of Strings.
Throws:
ManagerException
PortalException

getMetaTagIdsRecursively

List<String> getMetaTagIdsRecursively(SessionConfig sessionConfig,
                                      String channelId,
                                      ITransaction transaction)
                                      throws ManagerException,
                                             PortalException
Get a list of meta-tags ids of the Channel including inherit Meta-tag.

Parameters:
sessionConfig -
channelId -
transaction -
Returns:
Throws:
ManagerException
PortalException

getCenterPages

boolean getCenterPages(SessionConfig sessionConfig,
                       ChannelConfig channelConfig,
                       ITransaction transaction)
                       throws ManagerException,
                              PortalException
Get a boolean indicating wheter the page must be centralized.

Parameters:
sessionConfig - The session information of the user.
channelConfig -
transaction -
Returns:
Throws:
ManagerException
PortalException

getCachePages

int getCachePages(SessionConfig sessionConfig,
                  ChannelConfig channelConfig,
                  ITransaction transaction)
                  throws ManagerException,
                         PortalException
Parameters:
sessionConfig - The session information of the user.
channelConfig -
transaction -
Returns:
an integer.
Throws:
ManagerException
PortalException

serialize

void serialize(SessionConfig sessionConfig,
               String channelId,
               OutputStream outputStream,
               ITransaction transaction)
               throws ManagerException,
                      PortalException
Parameters:
sessionConfig - The session information of the user.
channelId -
outputStream -
transaction -
Throws:
ManagerException
PortalException

deserialize

String deserialize(SessionConfig sessionConfig,
                   DeserializationConfig deserializationConfig,
                   Node channelNode,
                   ITransaction transaction)
                   throws ManagerException,
                          PortalException
Parameters:
sessionConfig - The session information of the user.
deserializationConfig -
channelNode -
transaction -
Returns:
a String.
Throws:
ManagerException
PortalException

deserializeSecondPass

void deserializeSecondPass(SessionConfig sessionConfig,
                           DeserializationConfig deserializationConfig,
                           Node channelNode,
                           ITransaction transaction)
                           throws ManagerException,
                                  PortalException
Perfoms the second pass of the channels deserialization

Parameters:
sessionConfig - user session information.
deserializationConfig - deserialization configuration.
channelNode - the data for the channel to be imported.
transaction - the transaction for persistence access.
Throws:
ManagerException
PortalException

serializeCss

void serializeCss(SessionConfig sessionConfig,
                  String channelId,
                  OutputStream outputStream,
                  ITransaction transaction)
                  throws ManagerException,
                         PortalException
Parameters:
sessionConfig - The session information of the user.
channelId -
outputStream -
transaction -
Throws:
ManagerException
PortalException

deserializeCss

void deserializeCss(SessionConfig sessionConfig,
                    DeserializationConfig deserializationConfig,
                    Node cssLinksNodes,
                    ITransaction transaction)
                    throws ManagerException,
                           PortalException
Parameters:
sessionConfig - The session information of the user.
deserializationConfig -
cssLinksNodes -
transaction -
Throws:
ManagerException
PortalException

getIdsByParentTemplateId

List<String> getIdsByParentTemplateId(SessionConfig sessionConfig,
                                      String parentTemplateId,
                                      ITransaction transaction)
                                      throws ManagerException,
                                             PortalException
Retrieves the Ids of all channel that uses the specified channel template.

Parameters:
sessionConfig -
parentTemplateId -
transaction -
Returns:
Throws:
ManagerException
PortalException
Since:
4.0.4

clearCache

void clearCache(SessionConfig sessionConfig,
                String channelId,
                ITransaction transaction)
                throws ManagerException,
                       PortalException
Clear the Channel cache.

This method clears the following caches

If the channel being cleared is the Portal Channel, the string cache will also be cleared.

If there are subchannels to which the user does not have access, these channels and their subchannels are skipped.

Parameters:
sessionConfig -
channelId -
transaction -
Throws:
ManagerException
PortalException
Since:
4.0.4

getIdsByPageTemplateId

Collection<String> getIdsByPageTemplateId(SessionConfig sessionConfig,
                                          String pageTemplateId,
                                          ITransaction transaction)
                                          throws ManagerException,
                                                 PortalException
Retrieves the Ids of all channel that uses the specified page template as default page template

Parameters:
sessionConfig -
pageTemplateId -
transaction -
Returns:
Throws:
ManagerException
PortalException
Since:
4.0.8

getPageTemplateIdRecursively

String getPageTemplateIdRecursively(SessionConfig sessionConfig,
                                    String channelId,
                                    ITransaction transaction)
                                    throws PortalException
Returns the PageTemplateId for the specified channel (local or inherited from a parent channel)

Parameters:
sessionConfig -
channelId -
transaction -
Returns:
Throws:
PortalException
Since:
4.0.6

getChannelTreeCount

int getChannelTreeCount(String rootChannelId,
                        ITransaction transaction)
                        throws ManagerException,
                               PortalException
Returns the number of channels in the tree for which the root is the given channelId.

Parameters:
rootChannelId - root channel identifier
transaction -
Returns:
Throws:
ManagerException
PortalException

getChannelTreeIds

List<String> getChannelTreeIds(String rootChannelId,
                               ITransaction transaction)
                               throws ManagerException,
                                      PortalException
Returns all the ids of channels in the tree for which the root is the given channelId.

Parameters:
rootChannelId - root channel identifier
transaction -
Returns:
Throws:
ManagerException
PortalException

getPathNames

List<String> getPathNames(SessionConfig sessionConfig,
                          String channelId,
                          boolean localizable,
                          ITransaction transaction)
                          throws ManagerException,
                                 PortalException
Returns a list of strings each representing the name of the channel between the root portal channel and the channel solicited.

The first element of the list is the root portal channel followed by its children in hierarchical order.

Parameters:
sessionConfig - session config of a user
channelId - identifier of the channel for which you want the path names
localizable - if true, the channel names are localized
transaction -
Returns:
Throws:
ManagerException
PortalException

getProtocolType

int getProtocolType(SessionConfig sessionConfig,
                    ChannelConfig channelConfig,
                    ITransaction transaction)
                    throws ManagerException,
                           PortalException
Returns the protocolType of the given channel.

This method checks recursively up the channel´s ancestors until it finds a protocolType that is not PageConfig.PAGE_PROTOCOL_INHERIT.

Possible protocol types are:

Parameters:
sessionConfig -
channelConfig -
transaction -
Returns:
Throws:
ManagerException
PortalException


Lumisportal  4.1.0.071221 - Copyright © 2001-2007, Lumis. All Rights Reserved.