CStockage 4.2_beta-RC-1
API Documentation

org.esupportail.portal.channels.CStockage.channelAction.injac
Class ChannelAction

java.lang.Object
  extended byorg.esupportail.portal.channels.CStockage.channelAction.AbstractChannelAction
      extended byorg.esupportail.portal.channels.CStockage.channelAction.injac.ChannelAction

public class ChannelAction
extends AbstractChannelAction

Id: ChannelAction.java,v 1.0 27 sept. 2004 Copyright (c) 2004 Esup Portail (www.esup-portail.org) Classes: ChannelAction Original Author: Yohan Colmant Class used to manage the actions when we are in an injac space context


Constructor Summary
ChannelAction()
          Default constructor
 
Method Summary
 void init(org.jasig.portal.security.IPerson person, Space currentSpace, java.util.ArrayList spaces, BufferAction buffer, java.lang.String userPortalLogin, java.util.Vector userGroups)
          Init the object used to manage the actions of the channel
static boolean isUserDocumentOwner(java.lang.String documentPath, Space currentSpace, java.lang.String userPortalLogin)
          Check if the current user is the owner of the specified document
static boolean isUserEditorInSpace(java.lang.String spacePath, Space currentSpace, java.lang.String userPortalLogin, java.util.Vector userGroups)
          Check if the current user is editor in the specified space
static boolean isUserManagerInSpace(java.lang.String spacePath, Space currentSpace, java.lang.String userPortalLogin, java.util.Vector userGroups)
          Check if the current user is manager in the specified space
static boolean isUserWriterInSpace(java.lang.String spacePath, Space currentSpace, java.lang.String userPortalLogin, java.util.Vector userGroups)
          Check if the current user is writer in the specified space
 java.lang.StringBuffer renderXmlChannelException(ChannelException e)
          Return the xml when we have a ChannelException exception
 java.lang.StringBuffer renderXmlWithInformation(java.lang.String informationCode)
          Return the xml when we have to show a information message
 java.lang.StringBuffer specificCheckCalledAction(java.lang.String currentMode, org.jasig.portal.ChannelStaticData staticData, org.jasig.portal.ChannelRuntimeData runtimeData, org.xml.sax.ContentHandler out, org.jasig.portal.utils.XSLT xslt, ChannelException setStaticDataException)
          Manage the specific actions when refreshing the channel for the specific channel mode
 
Methods inherited from class org.esupportail.portal.channels.CStockage.channelAction.AbstractChannelAction
checkCalledAction
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ChannelAction

public ChannelAction()
Default constructor

Method Detail

init

public void init(org.jasig.portal.security.IPerson person,
                 Space currentSpace,
                 java.util.ArrayList spaces,
                 BufferAction buffer,
                 java.lang.String userPortalLogin,
                 java.util.Vector userGroups)
          throws ChannelException
Init the object used to manage the actions of the channel

Overrides:
init in class AbstractChannelAction
Parameters:
person - the uportal person object
currentSpace - the current space used
spaces - all the spaces used
buffer - the buffer used to get for example the clipboard
userPortalLogin - The user login in the portal
userGroups - The groups of the user in the portal
Throws:
ChannelException

isUserManagerInSpace

public static boolean isUserManagerInSpace(java.lang.String spacePath,
                                           Space currentSpace,
                                           java.lang.String userPortalLogin,
                                           java.util.Vector userGroups)
                                    throws ServerException
Check if the current user is manager in the specified space

Parameters:
spacePath - the space access path
currentSpace - the current space used
userPortalLogin - the uportal access login
userGroups - the groups of the user
Returns:
true if manager, false else
Throws:
ServerException

isUserWriterInSpace

public static boolean isUserWriterInSpace(java.lang.String spacePath,
                                          Space currentSpace,
                                          java.lang.String userPortalLogin,
                                          java.util.Vector userGroups)
                                   throws ServerException
Check if the current user is writer in the specified space

Parameters:
spacePath - the space access path
currentSpace - the current space used
userPortalLogin - the uportal access login
userGroups - the groups of the user
Returns:
true if writer, false else
Throws:
ServerException

isUserEditorInSpace

public static boolean isUserEditorInSpace(java.lang.String spacePath,
                                          Space currentSpace,
                                          java.lang.String userPortalLogin,
                                          java.util.Vector userGroups)
                                   throws ServerException
Check if the current user is editor in the specified space

Parameters:
spacePath - the space access path
currentSpace - the current space used
userPortalLogin - the uportal access login
userGroups - the groups of the user
Returns:
true if editor, false else
Throws:
ServerException

isUserDocumentOwner

public static boolean isUserDocumentOwner(java.lang.String documentPath,
                                          Space currentSpace,
                                          java.lang.String userPortalLogin)
                                   throws ServerException
Check if the current user is the owner of the specified document

Parameters:
documentPath - the document access path
currentSpace - the current space used
userPortalLogin - the uportal access login
Returns:
true if author, false else
Throws:
ServerException

specificCheckCalledAction

public java.lang.StringBuffer specificCheckCalledAction(java.lang.String currentMode,
                                                        org.jasig.portal.ChannelStaticData staticData,
                                                        org.jasig.portal.ChannelRuntimeData runtimeData,
                                                        org.xml.sax.ContentHandler out,
                                                        org.jasig.portal.utils.XSLT xslt,
                                                        ChannelException setStaticDataException)
                                                 throws ChannelException,
                                                        org.jasig.portal.PortalException
Manage the specific actions when refreshing the channel for the specific channel mode

Specified by:
specificCheckCalledAction in class AbstractChannelAction
Parameters:
currentMode - the current channel mode
staticData - the static data channel object
runtimeData - the runtime data channel object
out - the contentHandler used in the renderXml
xslt - the xslt motor object
setStaticDataException - the excpetion throwed in the setStaticData method
Throws:
org.jasig.portal.PortalException
ChannelException

renderXmlWithInformation

public java.lang.StringBuffer renderXmlWithInformation(java.lang.String informationCode)
Return the xml when we have to show a information message

Specified by:
renderXmlWithInformation in class AbstractChannelAction
Returns:
the xml when we have to show a information message

renderXmlChannelException

public java.lang.StringBuffer renderXmlChannelException(ChannelException e)
Return the xml when we have a ChannelException exception

Specified by:
renderXmlChannelException in class AbstractChannelAction
Parameters:
e - the throwed exception
Returns:
the xml when we have a ChannelException exception

CStockage 4.2_beta-RC-1
API Documentation