com.stratelia.silverpeas.peasCore
Class MainSessionController

java.lang.Object
  extended by com.stratelia.silverpeas.peasCore.MainSessionController
All Implemented Interfaces:
Clipboard

public class MainSessionController
extends Object
implements Clipboard


Field Summary
static String MAIN_SESSION_CONTROLLER_ATT
           
 
Constructor Summary
protected MainSessionController()
          Default constructor just for tests.
  MainSessionController(String authenticationKey, String sessionId)
          parameter authenticationKey replaced by sUserId
 
Method Summary
 void add(ClipboardSelection clipObject)
          Method declaration
 void clear()
           
 Clipboard create(String name)
           
 ComponentContext createComponentContext(String sSpaceId, String sComponent)
          Helper function.
 AdminUserConnections getAdminUserConnections()
          Get the userId
 AlertUser getAlertUser()
           
 Clipboard getClipboard()
          Return the clipboard EJB
 List<Parameter> getComponentParameters(String sComponentId)
          Return the parameters for the given component
 String getComponentParameterValue(String sComponentId, String parameterName)
          Return the value of the parameter for the given component and the given name of parameter
 Object getComponentSOFactory()
          Return the SilverObject Factory
 ContentManager getContentManager()
           
 int getCount()
          Method declaration
 UserDetail getCurrentUserDetail()
          Return the UserDetail of the the current user
 Exception getExceptionError()
          Method declaration
 String getFavoriteLanguage()
          Return the user's favorite language
 String getFavoriteLook()
          Return the user's favorite language
 String getFavoriteSpace()
          Return the user's favorite space
 GenericPanel getGenericPanel(String panelKey)
           
 List<GlobalSilverContent> getLastResults()
           
 String getMessageError()
          Method declaration
 String getName()
           
 ClipboardSelection getObject()
          Method declaration
 ClipboardSelection getObject(int index)
          Method declaration
 Collection<ClipboardSelection> getObjects()
          Method declaration
 OrganisationController getOrganisationController()
           
 UserPreferences getPersonalization()
          Return the personalization EJB
 Collection<ClipboardSelection> getSelectedObjects()
          Method declaration
 Selection getSelection()
           
 String getServerName()
           
 String getServerNameAndPort()
           
 String getServerPort()
           
 String getSessionId()
           
 SubscriptionContext getSubscriptionContext()
           
 UserAccessLevel getUserAccessLevel()
          Return the user accesslevel of the cuurent user
 String[] getUserAvailComponentIds()
          Return the components ids available for the current user
 String[] getUserAvailRootSpaceIds()
          Return the root spaces ids available for the current user
 String[] getUserAvailSpaceIds()
          Return the spaces ids available for the current user
 String getUserCurrentComponentId()
          Deprecated.  
 String getUserCurrentSpaceId()
          Deprecated.  
 String getUserId()
           
 Date getUserLastRequest()
           
 Date getUserLoginBegin()
           
 List<String> getUserManageableGroupIds()
           
 String[] getUserManageableSpaceIds()
          Return the spaces ids manageable by the current user
 void initClipboard()
           
 void initServerProps(String sName, String sPort)
           
 boolean isAllowPasswordChange()
           
 boolean isAppInMaintenance()
           
 boolean isBackOfficeVisible()
           
 boolean isDragNDropEnabled()
           
 boolean isOnlineEditingEnabled()
           
 boolean isPDCBackOfficeVisible()
           
 boolean isSpaceInMaintenance(String spaceId)
           
 boolean isWebDAVEditingEnabled()
           
 void PasteDone()
          Method declaration
 void remove()
           
 void removeObject(int index)
          Method declaration
 void setAllowPasswordChange(boolean flag)
           
 void setAppModeMaintenance(boolean mode)
           
 void setComponentSOFactory(Object Factory)
          Get the Factory
 void setFavoriteSpace(String newSpace)
           
 void setGenericPanel(String panelKey, GenericPanel panel)
           
 void setLastResults(List<GlobalSilverContent> list)
           
 void setMessageError(String messageID, Exception e)
          Method declaration
 void setMultiClipboard()
          Method declaration
 void setSelected(int index, boolean setIt)
          Method declaration
 void setSingleClipboard()
          Method declaration
 void setSpaceModeMaintenance(String spaceId, boolean mode)
           
 void setUserLastRequest(Date d)
           
 void setUserLoginBegin(Date d)
           
 int size()
          Method declaration
 void updateUserComponent(String sComponent)
          Deprecated.  
 void updateUserSpace(String sSpaceId)
          Deprecated.  
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MAIN_SESSION_CONTROLLER_ATT

public static final String MAIN_SESSION_CONTROLLER_ATT
See Also:
Constant Field Values
Constructor Detail

MainSessionController

protected MainSessionController()
Default constructor just for tests.


MainSessionController

public MainSessionController(String authenticationKey,
                             String sessionId)
                      throws Exception
parameter authenticationKey replaced by sUserId

Throws:
Exception
Method Detail

isAppInMaintenance

public final boolean isAppInMaintenance()

setAppModeMaintenance

public void setAppModeMaintenance(boolean mode)

isSpaceInMaintenance

public boolean isSpaceInMaintenance(String spaceId)

setSpaceModeMaintenance

public void setSpaceModeMaintenance(String spaceId,
                                    boolean mode)

getUserId

public String getUserId()

getSessionId

public String getSessionId()

getComponentSOFactory

public Object getComponentSOFactory()
Return the SilverObject Factory


setComponentSOFactory

public void setComponentSOFactory(Object Factory)
Get the Factory


setUserLoginBegin

public void setUserLoginBegin(Date d)

getUserLoginBegin

public Date getUserLoginBegin()

setUserLastRequest

public void setUserLastRequest(Date d)

getUserLastRequest

public Date getUserLastRequest()

setGenericPanel

public void setGenericPanel(String panelKey,
                            GenericPanel panel)

getGenericPanel

public GenericPanel getGenericPanel(String panelKey)

getSelection

public Selection getSelection()

getSubscriptionContext

public SubscriptionContext getSubscriptionContext()

getAlertUser

public AlertUser getAlertUser()

initClipboard

public void initClipboard()

getClipboard

public Clipboard getClipboard()
Return the clipboard EJB


getPersonalization

public UserPreferences getPersonalization()
Return the personalization EJB


getFavoriteLanguage

public String getFavoriteLanguage()
Return the user's favorite language


getFavoriteSpace

public String getFavoriteSpace()
Return the user's favorite space


setFavoriteSpace

public void setFavoriteSpace(String newSpace)

getFavoriteLook

public String getFavoriteLook()
Return the user's favorite language


isOnlineEditingEnabled

public boolean isOnlineEditingEnabled()
Returns:
@deprecated use isWebDAVEditingEnabled instead.

isWebDAVEditingEnabled

public boolean isWebDAVEditingEnabled()

isDragNDropEnabled

public boolean isDragNDropEnabled()

getOrganisationController

public OrganisationController getOrganisationController()

getUserAccessLevel

public UserAccessLevel getUserAccessLevel()
Return the user accesslevel of the cuurent user


getCurrentUserDetail

public UserDetail getCurrentUserDetail()
Return the UserDetail of the the current user


getComponentParameters

public List<Parameter> getComponentParameters(String sComponentId)
Return the parameters for the given component


getComponentParameterValue

public String getComponentParameterValue(String sComponentId,
                                         String parameterName)
Return the value of the parameter for the given component and the given name of parameter


getUserAvailRootSpaceIds

public String[] getUserAvailRootSpaceIds()
Return the root spaces ids available for the current user


getUserAvailComponentIds

public String[] getUserAvailComponentIds()
Return the components ids available for the current user


getUserAvailSpaceIds

public String[] getUserAvailSpaceIds()
Return the spaces ids available for the current user


getUserManageableSpaceIds

public String[] getUserManageableSpaceIds()
Return the spaces ids manageable by the current user


isBackOfficeVisible

public boolean isBackOfficeVisible()

isPDCBackOfficeVisible

public boolean isPDCBackOfficeVisible()

getUserManageableGroupIds

public List<String> getUserManageableGroupIds()

createComponentContext

public ComponentContext createComponentContext(String sSpaceId,
                                               String sComponent)
Helper function. Create a new CurrentSessionControl object and fill it with the values of the current space Id and component Id passed in parameters


updateUserSpace

public void updateUserSpace(String sSpaceId)
Deprecated. 

Update the current space for the current user


updateUserComponent

public void updateUserComponent(String sComponent)
Deprecated. 

Update the current component for the current user


getUserCurrentSpaceId

public String getUserCurrentSpaceId()
Deprecated. 


getUserCurrentComponentId

public String getUserCurrentComponentId()
Deprecated. 


getAdminUserConnections

public AdminUserConnections getAdminUserConnections()
Get the userId


getContentManager

public ContentManager getContentManager()

initServerProps

public void initServerProps(String sName,
                            String sPort)

getServerName

public String getServerName()

getServerPort

public String getServerPort()

getServerNameAndPort

public String getServerNameAndPort()

remove

public void remove()
Specified by:
remove in interface Clipboard

getLastResults

public List<GlobalSilverContent> getLastResults()
Returns:
a List of GlobalSilverResult corresponding to the last search

setLastResults

public void setLastResults(List<GlobalSilverContent> list)
Parameters:
list -

setAllowPasswordChange

public void setAllowPasswordChange(boolean flag)

isAllowPasswordChange

public boolean isAllowPasswordChange()

create

public Clipboard create(String name)
Specified by:
create in interface Clipboard

add

public void add(ClipboardSelection clipObject)
         throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
add in interface Clipboard
Throws:
ClipboardException
See Also:

getObject

public ClipboardSelection getObject()
Description copied from interface: Clipboard
Method declaration

Specified by:
getObject in interface Clipboard
Returns:

PasteDone

public void PasteDone()
               throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
PasteDone in interface Clipboard
Throws:
ClipboardException

getSelectedObjects

public Collection<ClipboardSelection> getSelectedObjects()
                                                  throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
getSelectedObjects in interface Clipboard
Returns:
Throws:
ClipboardException

getObjects

public Collection<ClipboardSelection> getObjects()
                                          throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
getObjects in interface Clipboard
Returns:
Throws:
ClipboardException

size

public int size()
         throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
size in interface Clipboard
Returns:
Throws:
ClipboardException
See Also:

getObject

public ClipboardSelection getObject(int index)
                             throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
getObject in interface Clipboard
Returns:
Throws:
ClipboardException

setSelected

public void setSelected(int index,
                        boolean setIt)
                 throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
setSelected in interface Clipboard
Throws:
ClipboardException

removeObject

public void removeObject(int index)
                  throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
removeObject in interface Clipboard
Throws:
ClipboardException

clear

public void clear()
Specified by:
clear in interface Clipboard

setMultiClipboard

public void setMultiClipboard()
                       throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
setMultiClipboard in interface Clipboard
Throws:
ClipboardException

setSingleClipboard

public void setSingleClipboard()
                        throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
setSingleClipboard in interface Clipboard
Throws:
ClipboardException

getName

public String getName()
Specified by:
getName in interface Clipboard

getCount

public int getCount()
             throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
getCount in interface Clipboard
Returns:
Throws:
ClipboardException

getMessageError

public String getMessageError()
                       throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
getMessageError in interface Clipboard
Returns:
Throws:
ClipboardException

getExceptionError

public Exception getExceptionError()
                            throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
getExceptionError in interface Clipboard
Returns:
Throws:
ClipboardException

setMessageError

public void setMessageError(String messageID,
                            Exception e)
                     throws ClipboardException
Description copied from interface: Clipboard
Method declaration

Specified by:
setMessageError in interface Clipboard
Throws:
ClipboardException


Copyright © 2016 Silverpeas. All Rights Reserved.