spcp7.imagegallery.view.managedbean.helper
Class PropertyWrapper

java.lang.Object
  extended by spcp7.imagegallery.view.managedbean.helper.PropertyWrapper
All Implemented Interfaces:
java.lang.Comparable<PropertyWrapper>

public class PropertyWrapper
extends java.lang.Object
implements java.lang.Comparable<PropertyWrapper>

Wraps PropertyModelFace for use within view.

Author:
Phillip Merensky

Constructor Summary
PropertyWrapper(PropertyModelFace propertyModel, EditBean editBean)
          Standard constructor.
 
Method Summary
 void browseContent(javax.faces.event.ActionEvent ae)
          JSF callable method which should be called if the property is browseable and content should be selected.
 int compareTo(PropertyWrapper o)
          To allow sorting the keys ( PropertyModelFace.getSchluessel() ) are compared.
 PropertyModelFace getPropertyModel()
           
 boolean isBool()
          This is needed because JSF cannot handle Boolean objects.
 boolean isBrowseable()
          This is needed because JSF cannot handle Boolean objects.
 boolean isDeletable()
          This is needed because JSF cannot handle Boolean objects.
 boolean isFolderSelection()
          This is needed because JSF cannot handle Boolean objects.
 boolean isImageSelection()
          This is needed because JSF cannot handle Boolean objects.
 boolean isNumber()
          This is needed because JSF cannot handle Boolean objects.
 boolean isSelected()
           
 boolean isUrlSelection()
          This is needed because JSF cannot handle Boolean objects.
 boolean isVisible()
          This is needed because JSF cannot handle Boolean objects.
 void setBrowseable(boolean browseable)
          This is needed because JSF cannot handle Boolean objects.
 void setPropertyModel(PropertyModelFace propertyModel)
          This is needed because JSF cannot handle Boolean objects.
 void setSelected(boolean selected)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PropertyWrapper

public PropertyWrapper(PropertyModelFace propertyModel,
                       EditBean editBean)
Standard constructor.

Parameters:
propertyModel - the property model which should be wrapped.
editBean - The corresponding managed/backing bean.
Method Detail

browseContent

public void browseContent(javax.faces.event.ActionEvent ae)
JSF callable method which should be called if the property is browseable and content should be selected. This method does nothing when PropertyModelFace.getBrowseable() is set to false.

Parameters:
ae -

isSelected

public boolean isSelected()
Returns:

setSelected

public void setSelected(boolean selected)
Parameters:
selected -

compareTo

public int compareTo(PropertyWrapper o)
To allow sorting the keys ( PropertyModelFace.getSchluessel() ) are compared.

Specified by:
compareTo in interface java.lang.Comparable<PropertyWrapper>
See Also:
Comparable.compareTo(java.lang.Object)

isDeletable

public boolean isDeletable()
This is needed because JSF cannot handle Boolean objects. So this property is wrapped and now returns a primitive boolean.

Returns:

isBool

public boolean isBool()
This is needed because JSF cannot handle Boolean objects. So this property is wrapped and now returns a primitive boolean.

Returns:

isNumber

public boolean isNumber()
This is needed because JSF cannot handle Boolean objects. So this property is wrapped and now returns a primitive boolean.

Returns:

isFolderSelection

public boolean isFolderSelection()
This is needed because JSF cannot handle Boolean objects. So this property is wrapped and now returns a primitive boolean.

Returns:

isUrlSelection

public boolean isUrlSelection()
This is needed because JSF cannot handle Boolean objects. So this property is wrapped and now returns a primitive boolean.

Returns:

isImageSelection

public boolean isImageSelection()
This is needed because JSF cannot handle Boolean objects. So this property is wrapped and now returns a primitive boolean.

Returns:

isVisible

public boolean isVisible()
This is needed because JSF cannot handle Boolean objects. So this property is wrapped and now returns a primitive boolean.

Returns:

getPropertyModel

public PropertyModelFace getPropertyModel()

setPropertyModel

public void setPropertyModel(PropertyModelFace propertyModel)
This is needed because JSF cannot handle Boolean objects. So this property is wrapped and now returns a primitive boolean.


isBrowseable

public boolean isBrowseable()
This is needed because JSF cannot handle Boolean objects. So this property is wrapped and now returns a primitive boolean.

Returns:

setBrowseable

public void setBrowseable(boolean browseable)
This is needed because JSF cannot handle Boolean objects. So this property is wrapped and now returns a primitive boolean.



Copyright © 2008. All Rights Reserved.