org.exoplatform.services.portletcontainer.plugins.pc.portletAPIImp
Class PortletPreferencesImp

java.lang.Object
  extended by org.exoplatform.services.portletcontainer.plugins.pc.portletAPIImp.PortletPreferencesImp
All Implemented Interfaces:
Serializable, javax.portlet.PortletPreferences

public class PortletPreferencesImp
extends Object
implements javax.portlet.PortletPreferences, Serializable

Created by The eXo Platform SAS. Author : Mestrallet Benjamin benjmestrallet@users.sourceforge.net Date: Jul 27, 2003 Time: 9:21:41 PM

See Also:
Serialized Form

Field Summary
protected  WindowID windowID
          Window id.
 
Constructor Summary
PortletPreferencesImp(javax.portlet.PreferencesValidator validator, ExoPortletPreferences defaultPreferences, WindowID windowID, PortletPreferencesPersister persister)
           
 
Method Summary
 void discard()
          Discard.
 ExoPortletPreferences getCurrentPreferences()
           
 Map<String,String[]> getMap()
          Overridden method.
 int getMethodCalledIsAction()
           
 Enumeration<String> getNames()
          Overridden method.
 String getValue(String s, String s1)
          Overridden method.
 String[] getValues(String s, String[] strings)
          Overridden method.
 boolean isMethodCalledIsRender()
           
 boolean isReadOnly(String s)
          Overridden method.
 boolean isStateChangeAuthorized()
           
 boolean isStateSaveOnClient()
           
 void reset(String s)
          Overridden method.
 void setCurrentPreferences(ExoPortletPreferences map)
           
 void setMethodCalledIsAction(int b)
           
 void setStateChangeAuthorized(boolean stateChangeAuthorized)
           
 void setStateSaveOnClient(boolean stateSaveOnClient)
           
 void setValue(String s, String s1)
          Overridden method.
 void setValues(String s, String[] strings)
          Overridden method.
 void store()
          We first validate every field then we deleguates the storing to an object that implements the PersistentManager interface
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

windowID

protected WindowID windowID
Window id.

Constructor Detail

PortletPreferencesImp

public PortletPreferencesImp(javax.portlet.PreferencesValidator validator,
                             ExoPortletPreferences defaultPreferences,
                             WindowID windowID,
                             PortletPreferencesPersister persister)
Parameters:
validator - validator
defaultPreferences - default preferences
windowID - window id
persister - persister
Method Detail

getCurrentPreferences

public ExoPortletPreferences getCurrentPreferences()
Returns:
preferences

setCurrentPreferences

public void setCurrentPreferences(ExoPortletPreferences map)
Parameters:
map - map

isReadOnly

public boolean isReadOnly(String s)
Overridden method.

Specified by:
isReadOnly in interface javax.portlet.PortletPreferences
Parameters:
s - name
Returns:
is readonly
See Also:
PortletPreferences.isReadOnly(java.lang.String)

getValue

public String getValue(String s,
                       String s1)
Overridden method.

Specified by:
getValue in interface javax.portlet.PortletPreferences
Parameters:
s - name
s1 - default value
Returns:
value
See Also:
PortletPreferences.getValue(java.lang.String, java.lang.String)

getValues

public String[] getValues(String s,
                          String[] strings)
Overridden method.

Specified by:
getValues in interface javax.portlet.PortletPreferences
Parameters:
s - name
strings - default values
Returns:
values
See Also:
PortletPreferences.getValues(java.lang.String, java.lang.String[])

setValue

public void setValue(String s,
                     String s1)
              throws javax.portlet.ReadOnlyException
Overridden method.

Specified by:
setValue in interface javax.portlet.PortletPreferences
Parameters:
s - name
s1 - value
Throws:
javax.portlet.ReadOnlyException - exception
See Also:
PortletPreferences.setValue(java.lang.String, java.lang.String)

setValues

public void setValues(String s,
                      String[] strings)
               throws javax.portlet.ReadOnlyException
Overridden method.

Specified by:
setValues in interface javax.portlet.PortletPreferences
Parameters:
s - key
strings - values
Throws:
javax.portlet.ReadOnlyException - exception
See Also:
PortletPreferences.setValues(java.lang.String, java.lang.String[])

getNames

public Enumeration<String> getNames()
Overridden method.

Specified by:
getNames in interface javax.portlet.PortletPreferences
Returns:
names
See Also:
PortletPreferences.getNames()

getMap

public Map<String,String[]> getMap()
Overridden method.

Specified by:
getMap in interface javax.portlet.PortletPreferences
Returns:
map
See Also:
PortletPreferences.getMap()

reset

public void reset(String s)
           throws javax.portlet.ReadOnlyException
Overridden method.

Specified by:
reset in interface javax.portlet.PortletPreferences
Parameters:
s - key
Throws:
javax.portlet.ReadOnlyException - exception
See Also:
PortletPreferences.reset(java.lang.String)

store

public void store()
           throws IOException,
                  javax.portlet.ValidatorException
We first validate every field then we deleguates the storing to an object that implements the PersistentManager interface

Specified by:
store in interface javax.portlet.PortletPreferences
Throws:
IOException - exception
javax.portlet.ValidatorException - exception

discard

public void discard()
Discard.


setMethodCalledIsAction

public void setMethodCalledIsAction(int b)
Parameters:
b - method called

getMethodCalledIsAction

public int getMethodCalledIsAction()
Returns:
called method

isMethodCalledIsRender

public boolean isMethodCalledIsRender()
Returns:
if method called is action

isStateChangeAuthorized

public boolean isStateChangeAuthorized()
Returns:
is state change authorized

setStateChangeAuthorized

public void setStateChangeAuthorized(boolean stateChangeAuthorized)
Parameters:
stateChangeAuthorized - state change authorized

setStateSaveOnClient

public void setStateSaveOnClient(boolean stateSaveOnClient)
Parameters:
stateSaveOnClient - state save on client

isStateSaveOnClient

public boolean isStateSaveOnClient()
Returns:
is state save on client


Copyright © 2009 eXo Platform SAS. All Rights Reserved.