org.openmdx.portal.servlet.attribute
Class Attribute

java.lang.Object
  extended by org.openmdx.portal.servlet.attribute.Attribute
All Implemented Interfaces:
Serializable

public final class Attribute
extends Object
implements Serializable

See Also:
Serialized Form

Constructor Summary
  Attribute()
           
  Attribute(int locale, ValuedField field, AttributeValue attributeValue)
           
protected Attribute(String label, String toolTip, int spanRow, List eventHandler, AttributeValue value)
           
 
Method Summary
 List getEventHandler()
           
 String getLabel()
           
 String getName()
           
 int getSpanRow()
           
 String getStringifiedValue(HtmlPage p, boolean forEditing, boolean shortFormat)
           
 String getToolTip()
           
 AttributeValue getValue()
           
 boolean isEmpty()
          An empty attribute should be skipped by the rendering.
 void paintForEdit(HtmlPage p, org.openmdx.base.accessor.jmi.cci.RefObject_1_0 lookupObject, int nCols, int tabIndex, String rowSpanModifier, String readonlyModifier, String disabledModifier, String lockedModifier, String stringifiedValue)
          Paints the attribute to page.
 void paintForEdit(HtmlPage p, String id, String label, org.openmdx.base.accessor.jmi.cci.RefObject_1_0 lookupObject, int nCols, int tabIndex, String rowSpanModifier, String readonlyModifier, String disabledModifier, String lockedModifier, String stringifiedValue)
          Paints the attribute to page.
 void paintForShow(HtmlPage p, int nCols, String gapModifier, String styleModifier, String widthModifier, String rowSpanModifier, String stringifiedValue)
          Paints the attribute to page.
 void paintForShow(HtmlPage p, String label, int nCols, String gapModifier, String styleModifier, String widthModifier, String rowSpanModifier, String stringifiedValue)
          Paints the attribute to page.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Attribute

public Attribute(int locale,
                 ValuedField field,
                 AttributeValue attributeValue)

Attribute

protected Attribute(String label,
                    String toolTip,
                    int spanRow,
                    List eventHandler,
                    AttributeValue value)

Attribute

public Attribute()
Method Detail

isEmpty

public boolean isEmpty()
An empty attribute should be skipped by the rendering. An empty attribute acts as placeholder in case an attribute was defined with spanRow > 1 in the same column of a field group.


getLabel

public String getLabel()

getToolTip

public String getToolTip()

getValue

public AttributeValue getValue()

getName

public String getName()

getSpanRow

public int getSpanRow()

getEventHandler

public List getEventHandler()

toString

public String toString()
Overrides:
toString in class Object

getStringifiedValue

public String getStringifiedValue(HtmlPage p,
                                  boolean forEditing,
                                  boolean shortFormat)

paintForShow

public void paintForShow(HtmlPage p,
                         int nCols,
                         String gapModifier,
                         String styleModifier,
                         String widthModifier,
                         String rowSpanModifier,
                         String stringifiedValue)
                  throws org.openmdx.base.exception.ServiceException
Paints the attribute to page.

Parameters:
p - target page
nCols - column span
gapModifier - gap modifier before attribute-specific code is generated. null if forEditing==true
styleModifier - style tag for generated element. null if forEditing==true
widthModifier - width tag for generated element. null if forEditing==true
rowSpanModifier - row span modifier
stringifiedValue - stringified value of field
Throws:
org.openmdx.base.exception.ServiceException

paintForShow

public void paintForShow(HtmlPage p,
                         String label,
                         int nCols,
                         String gapModifier,
                         String styleModifier,
                         String widthModifier,
                         String rowSpanModifier,
                         String stringifiedValue)
                  throws org.openmdx.base.exception.ServiceException
Paints the attribute to page.

Parameters:
p - target page
label - attribute label. null for default label, i.e. this.getValue().getLabel()
nCols - column span
gapModifier - gap modifier before attribute-specific code is generated. null if forEditing==true
styleModifier - style tag for generated element. null if forEditing==true
widthModifier - width tag for generated element. null if forEditing==true
rowSpanModifier - row span modifier
stringifiedValue - stringified value of field
Throws:
org.openmdx.base.exception.ServiceException

paintForEdit

public void paintForEdit(HtmlPage p,
                         org.openmdx.base.accessor.jmi.cci.RefObject_1_0 lookupObject,
                         int nCols,
                         int tabIndex,
                         String rowSpanModifier,
                         String readonlyModifier,
                         String disabledModifier,
                         String lockedModifier,
                         String stringifiedValue)
                  throws org.openmdx.base.exception.ServiceException
Paints the attribute to page. Use default field id and label.

Parameters:
p - target page
lookupObject - optinal base object where object lookup starts from. null if forEditing==false
nCols - column span
tabIndex - tab index of generated input field.
rowSpanModifier - row span modifier
readonlyModifier - readonly modifier.
disabledModifier - disabled modifier.
lockedModifier - modifier to lock field.
stringifiedValue - stringified value of field
Throws:
org.openmdx.base.exception.ServiceException

paintForEdit

public void paintForEdit(HtmlPage p,
                         String id,
                         String label,
                         org.openmdx.base.accessor.jmi.cci.RefObject_1_0 lookupObject,
                         int nCols,
                         int tabIndex,
                         String rowSpanModifier,
                         String readonlyModifier,
                         String disabledModifier,
                         String lockedModifier,
                         String stringifiedValue)
                  throws org.openmdx.base.exception.ServiceException
Paints the attribute to page.

Parameters:
p - target page
id - optional input field id. null for default id
label - attribute label. null for default label, i.e. this.getValue().getLabel()
lookupObject - optinal base object where object lookup starts from. null if forEditing==false
nCols - column span
tabIndex - tab index of generated input field.
rowSpanModifier - row span modifier
readonlyModifier - readonly modifier.
disabledModifier - disabled modifier.
lockedModifier - modifier to lock field.
stringifiedValue - stringified value of field
Throws:
org.openmdx.base.exception.ServiceException


This software is published under the BSD license. Copyright © 2006-2008, OMEX AG, Switzerland, All rights reserved. Use is subject to license terms.