org.apache.cocoon.forms.formmodel
Class AggregateFieldDefinition

java.lang.Object
  extended byorg.apache.cocoon.forms.formmodel.AbstractWidgetDefinition
      extended byorg.apache.cocoon.forms.formmodel.AbstractDatatypeWidgetDefinition
          extended byorg.apache.cocoon.forms.formmodel.FieldDefinition
              extended byorg.apache.cocoon.forms.formmodel.AggregateFieldDefinition
All Implemented Interfaces:
org.apache.cocoon.util.location.Locatable, WidgetDefinition

public class AggregateFieldDefinition
extends FieldDefinition

The WidgetDefinition part of a AggregateField widget, see AggregateField for more information.

Version:
$Id: AggregateFieldDefinition.html 1304280 2012-03-23 11:18:01Z ilgrosso $

Nested Class Summary
static class AggregateFieldDefinition.SplitMapping
           
 
Field Summary
protected  XMLizable splitFailMessage
          Message to be displayed when the splitPattern does not match what the user entered.
 
Fields inherited from class org.apache.cocoon.forms.formmodel.AbstractWidgetDefinition
createListener, enclosingLibrary, parent
 
Constructor Summary
AggregateFieldDefinition()
           
 
Method Summary
protected  void addSplitMapping(int group, String fieldId)
           
 void addWidgetDefinition(WidgetDefinition widgetDefinition)
           
 void checkCompleteness()
          checks completeness of this definition
 Widget createInstance()
          Creates and returns a widget based on this widget definition.
 org.outerj.expression.Expression getCombineExpression()
           
 XMLizable getSplitFailMessage()
           
 Iterator getSplitMappingsIterator()
           
 org.apache.oro.text.regex.Pattern getSplitPattern()
           
 String getSplitRegexp()
           
 boolean hasWidget(String id)
           
 void initializeFrom(WidgetDefinition definition)
          initialize this definition with the other, sort of like a copy constructor
protected  void setCombineExpression(org.outerj.expression.Expression expression)
           
protected  void setSplitFailMessage(XMLizable splitFailMessage)
           
protected  void setSplitPattern(org.apache.oro.text.regex.Pattern pattern, String regexp)
           
 
Methods inherited from class org.apache.cocoon.forms.formmodel.FieldDefinition
getSuggestionList, getWhitespaceTrim, isRequired, setRequired, setSuggestionList, setWhitespaceTrim
 
Methods inherited from class org.apache.cocoon.forms.formmodel.AbstractDatatypeWidgetDefinition
addValueChangedListener, buildSelectionList, buildSelectionListFromModel, fireValueChangedEvent, getDatatype, getInitialValue, getSelectionList, getValueChangedListener, hasValueChangedListeners, setDatatype, setProcessInfoProvider, setSelectionList, setSourceResolver, setXmlizer
 
Methods inherited from class org.apache.cocoon.forms.formmodel.AbstractWidgetDefinition
addCreateListener, addValidator, checkMutable, fireCreateEvent, generateDisplayData, generateDisplayData, generateLabel, getAttribute, getEnclosingLibrary, getFormDefinition, getId, getLocation, getParent, getState, makeImmutable, setAttributes, setDisplayData, setEnclosingLibrary, setId, setLocation, setParent, setState, validate, widgetCreated
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

splitFailMessage

protected XMLizable splitFailMessage
Message to be displayed when the splitPattern does not match what the user entered. Optional.

Constructor Detail

AggregateFieldDefinition

public AggregateFieldDefinition()
Method Detail

initializeFrom

public void initializeFrom(WidgetDefinition definition)
                    throws Exception
initialize this definition with the other, sort of like a copy constructor

Specified by:
initializeFrom in interface WidgetDefinition
Overrides:
initializeFrom in class FieldDefinition
Throws:
Exception

addWidgetDefinition

public void addWidgetDefinition(WidgetDefinition widgetDefinition)
                         throws DuplicateIdException
Throws:
DuplicateIdException

checkCompleteness

public void checkCompleteness()
                       throws IncompletenessException
checks completeness of this definition

Specified by:
checkCompleteness in interface WidgetDefinition
Overrides:
checkCompleteness in class AbstractDatatypeWidgetDefinition
Throws:
IncompletenessException

hasWidget

public boolean hasWidget(String id)

setCombineExpression

protected void setCombineExpression(org.outerj.expression.Expression expression)

getCombineExpression

public org.outerj.expression.Expression getCombineExpression()

setSplitPattern

protected void setSplitPattern(org.apache.oro.text.regex.Pattern pattern,
                               String regexp)

getSplitPattern

public org.apache.oro.text.regex.Pattern getSplitPattern()

getSplitRegexp

public String getSplitRegexp()

getSplitFailMessage

public XMLizable getSplitFailMessage()

setSplitFailMessage

protected void setSplitFailMessage(XMLizable splitFailMessage)

addSplitMapping

protected void addSplitMapping(int group,
                               String fieldId)

getSplitMappingsIterator

public Iterator getSplitMappingsIterator()

createInstance

public Widget createInstance()
Description copied from interface: WidgetDefinition
Creates and returns a widget based on this widget definition.

Specified by:
createInstance in interface WidgetDefinition
Overrides:
createInstance in class FieldDefinition


Copyright 1999-2008 The Apache Software Foundation. All Rights Reserved.