edu.washington.cs.supple.wlib.wap
Class ContainerWapWidget
java.lang.Object
edu.washington.cs.supple.render.AbstractWidget
edu.washington.cs.supple.render.AbstractContainerWidget
edu.washington.cs.supple.wlib.wap.ContainerWapWidget
- All Implemented Interfaces:
- java.lang.Cloneable, ContainerWidget, java.util.EventListener, java.beans.PropertyChangeListener, UnwrappedWidget, WapWidget, Widget
- public class ContainerWapWidget
- extends AbstractContainerWidget
- implements WapWidget
- Author:
- kgajos
|
Method Summary |
protected java.lang.String |
getChildWidgetsCode(int hints)
Returns wml code corresponding to all children |
protected java.lang.String |
getCodeForChild(UiObject object,
int hints)
Returns the WML code for a child corresponding to object description
and rendered according to the hings |
ConcreteWidget |
getConcreteWidget(java.io.Serializable renderingContext,
int hints)
Returns the concrete component (specific to a particular platform) |
float |
getEffortEstimate(ActionDescription a)
|
java.lang.String |
getExtraWapCode(int hints)
Some components may need to return code that cannot just be nested
but needs to be appended later in the WML document (for example,
if a component introduces a new card). |
java.awt.Dimension |
getSize(int hints)
|
java.lang.String |
getWapComponent(int hints)
|
void |
makeVisible(UiObject target)
This piece of functionality is necessary for interfaces with shortcuts --
it forces the container widget to make a particular child visible; this
base implementation assumes that widgets are rendered side by side so it
only makes sure that the target is a legal child. |
static boolean |
rendersObject(UiObject object)
A static method for testing the applicability of the widget given
a type of the UI component to be rendered |
java.lang.String |
toString()
|
| Methods inherited from class edu.washington.cs.supple.render.AbstractContainerWidget |
childIterator, disengage, engage, getChild, getChildFor, getMaxChildSize, getMaxChildSize, getMinChildSize, getSumChildSize, getSumChildSize, getWidgetProperties, hasChildren, setChildren |
| Methods inherited from class edu.washington.cs.supple.render.AbstractWidget |
anotherPropertyChanged, clone, clone, dismissCurrentView, displayDynamic, equals, executeAction, generateWidgetDescriptor, getBag, getConcreteWidget, getCost, getParent, getPath, getSizeCache, getTextLabel, getType, getUiObject, getWidgetDescriptor, indexChanged, isEngaged, isEquivalent, legalValuesChanged, likelyValuesChanged, propertyChange, reportActionExecutionEvent, reportValueChangedEvent, setBag, setCost, setEnabled, setParent, setSizeCache, setValue, setWrapper, unwrapWidget, valueChanged |
| Methods inherited from class java.lang.Object |
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface edu.washington.cs.supple.render.Widget |
childIterator, clone, clone, disengage, engage, getBag, getConcreteWidget, getCost, getPath, getSizeCache, getTextLabel, getType, getUiObject, getWidgetDescriptor, getWidgetProperties, hasChildren, isEngaged, isEquivalent, setBag, setCost, setEnabled, setParent, setSizeCache, setWrapper, unwrapWidget |
ContainerWapWidget
public ContainerWapWidget(UiObject object)
- Parameters:
object -
rendersObject
public static boolean rendersObject(UiObject object)
- A static method for testing the applicability of the widget given
a type of the UI component to be rendered
- Returns:
- true for all coumpound objects; false otherwise
getConcreteWidget
public ConcreteWidget getConcreteWidget(java.io.Serializable renderingContext,
int hints)
- Description copied from interface:
Widget
- Returns the concrete component (specific to a particular platform)
- Specified by:
getConcreteWidget in interface Widget- Overrides:
getConcreteWidget in class AbstractWidget
getCodeForChild
protected java.lang.String getCodeForChild(UiObject object,
int hints)
- Returns the WML code for a child corresponding to object description
and rendered according to the hings
- Parameters:
object - descriptionhints - rendering hints
- Returns:
- WML code for the maching child if set; null otherwise
getChildWidgetsCode
protected java.lang.String getChildWidgetsCode(int hints)
- Returns wml code corresponding to all children
- Parameters:
hints - the rendering hints
- Returns:
- the wml code for rendering children
getWapComponent
public java.lang.String getWapComponent(int hints)
- Specified by:
getWapComponent in interface WapWidget
- Parameters:
hints - specifies the variant of the widget to be rendered
- Returns:
- a renderable component
getExtraWapCode
public java.lang.String getExtraWapCode(int hints)
- Description copied from interface:
WapWidget
- Some components may need to return code that cannot just be nested
but needs to be appended later in the WML document (for example,
if a component introduces a new card). This method allows widgets
to return such code
- Specified by:
getExtraWapCode in interface WapWidget
- Parameters:
hints - rendering hints
- Returns:
- the extra WML code
getSize
public java.awt.Dimension getSize(int hints)
- Specified by:
getSize in interface Widget- Overrides:
getSize in class AbstractWidget
toString
public java.lang.String toString()
- Overrides:
toString in class AbstractContainerWidget
makeVisible
public void makeVisible(UiObject target)
- Description copied from class:
AbstractContainerWidget
- This piece of functionality is necessary for interfaces with shortcuts --
it forces the container widget to make a particular child visible; this
base implementation assumes that widgets are rendered side by side so it
only makes sure that the target is a legal child.
- Specified by:
makeVisible in interface ContainerWidget- Overrides:
makeVisible in class AbstractContainerWidget
- Parameters:
target - the vhild object that should be made visible
getEffortEstimate
public float getEffortEstimate(ActionDescription a)
- Specified by:
getEffortEstimate in interface Widget