com.plumtree.portalpages.common.editpage
Class LayoutColumnStore

java.lang.Object
  extended by com.plumtree.portalpages.common.editpage.LayoutColumnStore

public class LayoutColumnStore
extends java.lang.Object

This class manages getting and setting portlet columns count for adaptive layouts

Author:
rozhang

Field Summary
protected static java.lang.String CACHEKEY_PREFIX
           
protected static java.lang.String DISABLE_DRAGDROPLAYOUTEDITOR
           
 
Constructor Summary
LayoutColumnStore()
           
 
Method Summary
protected  java.lang.String CreateCacheKey(int layoutId)
          Create cache key from layout id
protected  CachingManager GetCacheStore()
          Helper method to get container to store layout id/column count pairs
 int GetLayoutColumnCount(int layoutId)
          Get number of portlet columns for specified layout (should be a negative value for adaptive layout)
 boolean IsDragDropLayoutEditorDisabled()
          Checks whether drag drop layout editor for IE is disabled or not
protected  int LookupColumnCount(CachingManager colStore, int layoutId)
          Gets the number of columns assigned to specified layout id
 void SetDisableDragDropLayoutEditor()
          Sets flag on Application to disable Portlet layout editor used for IE browsers Called by LayoutMetaDataTag to resolve bug 9862302.
 boolean SetLayoutColumnCount(int layoutId, int newCount)
          Updates column count for specified layout.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CACHEKEY_PREFIX

protected static final java.lang.String CACHEKEY_PREFIX
See Also:
Constant Field Values

DISABLE_DRAGDROPLAYOUTEDITOR

protected static final java.lang.String DISABLE_DRAGDROPLAYOUTEDITOR
See Also:
Constant Field Values
Constructor Detail

LayoutColumnStore

public LayoutColumnStore()
Method Detail

GetLayoutColumnCount

public int GetLayoutColumnCount(int layoutId)
Get number of portlet columns for specified layout (should be a negative value for adaptive layout)

Parameters:
layoutId -
Returns:
0 if the adaptive layout for the specified id was not found

GetCacheStore

protected CachingManager GetCacheStore()
Helper method to get container to store layout id/column count pairs

Returns:

CreateCacheKey

protected java.lang.String CreateCacheKey(int layoutId)
Create cache key from layout id


LookupColumnCount

protected int LookupColumnCount(CachingManager colStore,
                                int layoutId)
Gets the number of columns assigned to specified layout id

Parameters:
colStore -
layoutId -
Returns:
0 if the layout was not found

SetLayoutColumnCount

public boolean SetLayoutColumnCount(int layoutId,
                                    int newCount)
Updates column count for specified layout. New value is stored only if column count for layout is not stored before or if stored value is different from new value

Parameters:
layoutId -
colCount -
Returns:
true if column count was updated, false if the value already was set

SetDisableDragDropLayoutEditor

public void SetDisableDragDropLayoutEditor()
Sets flag on Application to disable Portlet layout editor used for IE browsers Called by LayoutMetaDataTag to resolve bug 9862302. Made optional for existing customers who want to keep the drag and drop layout editor


IsDragDropLayoutEditorDisabled

public boolean IsDragDropLayoutEditorDisabled()
Checks whether drag drop layout editor for IE is disabled or not

Returns:



Copyright © 2002,2003,2004,2005 Plumtree Software, Inc., All Rights Reserved.