com.cc.framework.ui.model.imp
Class PanelContentDesignModelImp

java.lang.Object
  extended bycom.cc.framework.ui.model.imp.PanelContentDesignModelImp
All Implemented Interfaces:
AccessControlled, DesignModel, PanelContentDesignModel, java.io.Serializable

public class PanelContentDesignModelImp
extends java.lang.Object
implements PanelContentDesignModel, java.io.Serializable

Designmoel for the panel content

Since:
1.0
Version:
$Revision: 1.15 $
Author:
Harald Schulz
See Also:
Serialized Form

Field Summary
private  java.lang.String action
          The action
private  boolean filter
          Specifies if all String should be converted into there HTML representation
private  ImageModel image
          The image to be displayed in the Panel
private  java.util.ArrayList items
          Buffer for the items
private  java.lang.String localeName
          Locale Setting
private  java.lang.String more
          Field more
private  Permission permission
          Permission
private static long serialVersionUID
          Serial Verion UID
private  java.lang.String title
          The title
private  java.lang.String tooltip
          The tooltip
 
Constructor Summary
PanelContentDesignModelImp()
          Constructor
 
Method Summary
 void addItem(PanelItemDesignModel newItem)
          Adds a panel item
 boolean filter()
          Returns if the filter is activated (default=true).
 java.lang.String getAction()
          Returns the action
 ImageModel getImage()
          Returns the image for the content body
 PanelItemDesignModel[] getItems()
          Returns a collection with the items
 java.lang.String getLocaleName()
          Gets the Local Setting for this element
 java.lang.String getMore()
          Return the text which should be displayed if there is a "other items" link.
 Permission getPermission()
          Returns the authorizations required to access an object If the method returns null no access rights is required.
 java.lang.String getTitle()
          Returns the title
 java.lang.String getTooltip()
          Returns the Tooltip
 void removeItem(PanelItemDesignModel item)
          Removes a panel item
 void setAction(java.lang.String action)
          Sets the action which should be processed if the user clicks on the "more link".
 void setFilter(boolean filter)
          Activates the HTML encoding (filter).
 void setImage(ImageModel image)
          Sets an image for the content body
 void setLocaleName(java.lang.String locale)
          Sets the Locale configuration for this element
 void setMore(java.lang.String newMore)
          Return the text which should be displayed if there are more items as displayed
 void setPermission(Permission permission)
          Sets a list with permissions to access this object.
 void setTitle(java.lang.String title)
          Sets the title
 void setTooltip(java.lang.String tooltip)
          Sets the Tooltip
 boolean show(Principal principal)
          Checks if the Object has a required permission.
 int size()
          Returns the number of items
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serialVersionUID

private static final long serialVersionUID
Serial Verion UID

See Also:
Constant Field Values

title

private java.lang.String title
The title


more

private java.lang.String more
Field more


image

private ImageModel image
The image to be displayed in the Panel


action

private java.lang.String action
The action


tooltip

private java.lang.String tooltip
The tooltip


filter

private boolean filter
Specifies if all String should be converted into there HTML representation


localeName

private java.lang.String localeName
Locale Setting


items

private java.util.ArrayList items
Buffer for the items


permission

private Permission permission
Permission

Constructor Detail

PanelContentDesignModelImp

public PanelContentDesignModelImp()
Constructor

Method Detail

addItem

public void addItem(PanelItemDesignModel newItem)
Description copied from interface: PanelContentDesignModel
Adds a panel item

Specified by:
addItem in interface PanelContentDesignModel
Parameters:
newItem - PanelItemDesignModel
See Also:
PanelContentDesignModel.addItem(PanelItemDesignModel)

removeItem

public void removeItem(PanelItemDesignModel item)
Description copied from interface: PanelContentDesignModel
Removes a panel item

Specified by:
removeItem in interface PanelContentDesignModel
Parameters:
item - PanelItemDesignModel
See Also:
PanelContentDesignModel.removeItem(PanelItemDesignModel)

getItems

public PanelItemDesignModel[] getItems()
Description copied from interface: PanelContentDesignModel
Returns a collection with the items

Specified by:
getItems in interface PanelContentDesignModel
Returns:
PanelItemDesignModel
See Also:
PanelContentDesignModel.getItems()

size

public int size()
Description copied from interface: PanelContentDesignModel
Returns the number of items

Specified by:
size in interface PanelContentDesignModel
Returns:
The number of items
See Also:
PanelContentDesignModel.size()

getMore

public java.lang.String getMore()
Description copied from interface: PanelContentDesignModel
Return the text which should be displayed if there is a "other items" link. This means that not all items are display in the panel at the same time

Specified by:
getMore in interface PanelContentDesignModel
Returns:
String
See Also:
PanelContentDesignModel.getMore()

getTitle

public java.lang.String getTitle()
Description copied from interface: PanelContentDesignModel
Returns the title

Specified by:
getTitle in interface PanelContentDesignModel
Returns:
String
See Also:
PanelContentDesignModel.getTitle()

setImage

public void setImage(ImageModel image)
Description copied from interface: PanelContentDesignModel
Sets an image for the content body

Specified by:
setImage in interface PanelContentDesignModel
Parameters:
image - ImageModel
See Also:
PanelContentDesignModel.setImage(ImageModel image)

setMore

public void setMore(java.lang.String newMore)
Description copied from interface: PanelContentDesignModel
Return the text which should be displayed if there are more items as displayed

Specified by:
setMore in interface PanelContentDesignModel
Parameters:
newMore - The hint to be display if there are more items
See Also:
PanelContentDesignModel.setMore(java.lang.String)

setTitle

public void setTitle(java.lang.String title)
Description copied from interface: PanelContentDesignModel
Sets the title

Specified by:
setTitle in interface PanelContentDesignModel
Parameters:
title - The title
See Also:
PanelContentDesignModel.setTitle(String title)

getImage

public ImageModel getImage()
Description copied from interface: PanelContentDesignModel
Returns the image for the content body

Specified by:
getImage in interface PanelContentDesignModel
Returns:
ImageModel
See Also:
PanelContentDesignModel.getImage()

setAction

public void setAction(java.lang.String action)
Description copied from interface: PanelContentDesignModel
Sets the action which should be processed if the user clicks on the "more link".

Specified by:
setAction in interface PanelContentDesignModel
Parameters:
action - The action to process
See Also:
PanelContentDesignModel.setAction(String)

getAction

public java.lang.String getAction()
Description copied from interface: PanelContentDesignModel
Returns the action

Specified by:
getAction in interface PanelContentDesignModel
Returns:
The action
See Also:
PanelContentDesignModel.getAction()

getPermission

public Permission getPermission()
Description copied from interface: AccessControlled
Returns the authorizations required to access an object If the method returns null no access rights is required.

Specified by:
getPermission in interface AccessControlled
Returns:
Permission A list with required permissions separated by ";"
See Also:
AccessControlled.getPermission()

setPermission

public void setPermission(Permission permission)
Description copied from interface: PanelContentDesignModel
Sets a list with permissions to access this object. The permission are separated by ';'.

Specified by:
setPermission in interface PanelContentDesignModel
Parameters:
permission - Permission
See Also:
PanelContentDesignModel.setPermission(com.cc.framework.security.Permission)

setTooltip

public void setTooltip(java.lang.String tooltip)
Description copied from interface: PanelContentDesignModel
Sets the Tooltip

Specified by:
setTooltip in interface PanelContentDesignModel
Parameters:
tooltip - Tooltip
See Also:
PanelContentDesignModel.setTooltip(java.lang.String)

getTooltip

public java.lang.String getTooltip()
Description copied from interface: PanelContentDesignModel
Returns the Tooltip

Specified by:
getTooltip in interface PanelContentDesignModel
Returns:
String
See Also:
PanelContentDesignModel.getTooltip()

filter

public boolean filter()
Description copied from interface: PanelContentDesignModel
Returns if the filter is activated (default=true). This means that all Strings which should be displayed in the HTML page are HTML encoded

Specified by:
filter in interface PanelContentDesignModel
Returns:
true if string will be HTML encoded; false otherwise. If a null is returned than the filter of the enclosing CrumbControl should be used
See Also:
PanelContentDesignModel.filter()

setFilter

public void setFilter(boolean filter)
Description copied from interface: PanelContentDesignModel
Activates the HTML encoding (filter). Default is true. This means that all Strings which should be displayed in the HTML page will be HTML encoded.

Specified by:
setFilter in interface PanelContentDesignModel
Parameters:
filter - true if strings should be HTML encoded; false otherwise
See Also:
PanelContentDesignModel.setFilter(boolean)

getLocaleName

public java.lang.String getLocaleName()
Description copied from interface: PanelContentDesignModel
Gets the Local Setting for this element

Specified by:
getLocaleName in interface PanelContentDesignModel
Returns:
Locale Setting
See Also:
PanelContentDesignModel.getLocaleName()

setLocaleName

public void setLocaleName(java.lang.String locale)
Description copied from interface: PanelContentDesignModel
Sets the Locale configuration for this element

Specified by:
setLocaleName in interface PanelContentDesignModel
Parameters:
locale - Locale Identifier or true|false
See Also:
PanelContentDesignModel.setLocaleName(java.lang.String)

show

public boolean show(Principal principal)
Description copied from interface: AccessControlled
Checks if the Object has a required permission.

Specified by:
show in interface AccessControlled
Parameters:
principal - the users principal object
Returns:
true if the permission exists
See Also:
AccessControlled.show(Principal)


Copyright © 2000-2005 SCC Informationssysteme GmbH. All Rights Reserved.