org.apache.cocoon.forms.formmodel
Interface SelectableWidget

All Superinterfaces:
Locatable, Widget
All Known Implementing Classes:
AggregateField, CalculatedField, CaptchaField, Field, MultiValueField, RepeaterFilterField

public interface SelectableWidget
extends Widget

A Widget that can have a selection list. The initial selection list is set by the widget's WidgetDefinition, and can be changed afterwards. The selection list can be removed by setting the list to null.

Version:
$Id: SelectableWidget.html 1304258 2012-03-23 10:09:27Z ilgrosso $

Field Summary
 
Fields inherited from interface org.apache.cocoon.forms.formmodel.Widget
PATH_SEPARATOR
 
Method Summary
 void setSelectionList(Object model, String valuePath, String labelPath)
          Set the widgdet's selection given an object and XPath expressions.
 void setSelectionList(SelectionList selectionList)
          Set the widget's selection list given a SelectionList.
 void setSelectionList(String uri)
          Set the widget's selection list given a source URI where the list will be read from.
 
Methods inherited from interface org.apache.cocoon.forms.formmodel.Widget
addValidator, broadcastEvent, generateLabel, generateSaxFragment, getAttribute, getCombinedState, getDefinition, getForm, getFullName, getId, getLocation, getName, getParent, getRequestParameterName, getState, getValue, getWidget, initialize, isRequired, isValid, lookupWidget, readFromRequest, removeAttribute, removeValidator, setAttribute, setParent, setState, setValue, validate
 

Method Detail

setSelectionList

void setSelectionList(SelectionList selectionList)
Set the widget's selection list given a SelectionList.

Parameters:
selectionList - the selection list or null to have no selection list.

setSelectionList

void setSelectionList(String uri)
Set the widget's selection list given a source URI where the list will be read from.

Parameters:
uri - the selection list's URI

setSelectionList

void setSelectionList(Object model,
                      String valuePath,
                      String labelPath)
Set the widgdet's selection given an object and XPath expressions.

Parameters:
model - the selection list model. This is typically a collection or an array of objects in which valuePath and labelPath will extract some data.
valuePath - the XPath expression to extract values
labelPath - the XPath expression to extract labels (can be absent in which case the value is used as label).


Copyright © 1999-2010 The Apache Software Foundation. All Rights Reserved.