Overview | Package | Class | Deprecated | Index | Help
| Groovy Documentation
| FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | PROPERTY | CONSTR | METHOD | DETAIL: FIELD | PROPERTY | CONSTR | METHOD

## org.codehaus.groovy.grails.web.binding
[Groovy] Class GrailsWebDataBinder

    java.lang.Object
      org.grails.databinding.SimpleDataBinder
          org.codehaus.groovy.grails.web.binding.GrailsWebDataBinder

    @groovy.transform.CompileStatic
    class GrailsWebDataBinder
    extends SimpleDataBinder

Field Summary
`protected static java.util.Map` | `CLASS_TO_BINDING_INCLUDE_LIST`
`protected GrailsApplication` | `grailsApplication`
`protected java.util.List` | `listeners`
`protected org.springframework.context.MessageSource` | `messageSource`

Fields inherited from class SimpleDataBinder
BASIC_TYPES, conversionHelpers, formattedValueConvertersionHelpers, structuredEditors

Property Summary
`boolean` | `convertEmptyStringsToNull`
`boolean` | `trimStrings`

Constructor Summary
`GrailsWebDataBinder(GrailsApplication grailsApplication)`

Method Summary
`protected java.lang.Object` | `addElementToCollection(java.lang.Object obj, java.lang.String propName, java.lang.Class propertyType, java.lang.Object propertyValue, boolean clearCollection)`
`protected java.lang.Object` | `addElementToCollection(java.lang.Object obj, java.lang.String propName, GrailsDomainClassProperty property, java.lang.Object propertyValue, boolean clearCollection)`
`protected java.lang.Object` | `addElementToCollectionAt(java.lang.Object obj, java.lang.String propertyName, java.util.Collection collection, java.lang.Object index, java.lang.Object val)`
`void` | `bind(java.lang.Object obj, DataBindingSource source)`
`void` | `bind(java.lang.Object obj, DataBindingSource source, DataBindingListener listener)`
`void` | `bind(java.lang.Object object, DataBindingSource source, java.lang.String filter, java.util.List whiteList, java.util.List blackList, DataBindingListener listener)`
`void` | `bind(java.lang.Object obj, groovy.util.slurpersupport.GPathResult gpath)`
`protected java.lang.Object` | `convert(java.lang.Class typeToConvertTo, java.lang.Object value)`
`protected void` | `doBind(java.lang.Object object, DataBindingSource source, java.lang.String filter, java.util.List whiteList, java.util.List blackList, DataBindingListener listener, java.lang.Object errors)`
`protected java.lang.Class` | `getDomainClassType(java.lang.Object obj, java.lang.String propName)` @param obj any object
`protected java.lang.String` | `getFormatString(BindingFormat annotation)`
`protected java.lang.Object` | `getIdentifierValueFrom(java.lang.Object source)`
`protected java.util.Locale` | `getLocale()`
`protected java.lang.Object` | `getPersistentInstance(java.lang.Class type, java.lang.Object id)`
`protected java.lang.Class` | `getReferencedTypeForCollection(java.lang.String name, java.lang.Object target)`
`protected java.lang.Object` | `initializeProperty(java.lang.Object obj, java.lang.String propName, java.lang.Class propertyType, DataBindingSource source)`
`protected boolean` | `isDomainClass(java.lang.Class clazz)`
`protected java.lang.Object` | `populateErrors(java.lang.Object obj, org.springframework.validation.BindingResult bindingResult)`
`protected java.lang.Object` | `preprocessValue(java.lang.Object propertyValue)`
`protected java.lang.Object` | `processIndexedProperty(java.lang.Object obj, groovy.lang.MetaProperty metaProperty, IndexedPropertyReferenceDescriptor indexedPropertyReferenceDescriptor, java.lang.Object val, DataBindingSource source, DataBindingListener listener, java.lang.Object errors)`
`protected java.lang.Object` | `processProperty(java.lang.Object obj, groovy.lang.MetaProperty metaProperty, java.lang.Object val, DataBindingSource source, DataBindingListener listener, java.lang.Object errors)`
`void` | `setDataBindingListeners(DataBindingListener[] listeners)`
`void` | `setFormattedValueConverters(FormattedValueConverter[] converters)`
`void` | `setMessageSource(org.springframework.context.MessageSource messageSource)`
`protected java.lang.Object` | `setPropertyValue(java.lang.Object obj, DataBindingSource source, groovy.lang.MetaProperty metaProperty, java.lang.Object propertyValue, DataBindingListener listener)`
`void` | `setStructuredBindingEditors(TypedStructuredBindingEditor[] editors)`
`void` | `setValueConverters(ValueConverter[] converters)`

Methods inherited from class SimpleDataBinder
addBindingError, addElementToArrayAt, addElementToCollection, addElementToCollectionAt, bind, bind, bind, bind, bind, bind, bind, bindProperty, convert, convertStringToEnum, doBind, getConverter, getDefaultCollectionInstanceForType, getField, getFormatString, getFormattedConverter, getIndexedPropertyReferenceDescriptor, getReferencedTypeForCollection, getReferencedTypeForCollectionInClass, getValueConverter, getValueConverterForClass, getValueConverterForField, initializeArray, initializeCollection, initializeMap, initializeProperty, isBasicType, isOkToAddElementAt, isOkToBind, preprocessValue, processIndexedProperty, processProperty, registerConverter, registerFormattedValueConverter, registerStructuredEditor, setPropertyValue, setPropertyValue

Methods inherited from class java.lang.Object
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()

Field Detail

### CLASS_TO_BINDING_INCLUDE_LIST

    protected static final java.util.Map CLASS_TO_BINDING_INCLUDE_LIST

### grailsApplication

    protected GrailsApplication grailsApplication

### listeners

    protected java.util.List listeners

### messageSource

    protected org.springframework.context.MessageSource messageSource

Property Detail

### convertEmptyStringsToNull

    boolean convertEmptyStringsToNull

### trimStrings

    boolean trimStrings

Constructor Detail

### GrailsWebDataBinder

    GrailsWebDataBinder(GrailsApplication grailsApplication)

Method Detail

### addElementToCollection

    @java.lang.Override
    protected java.lang.Object addElementToCollection(java.lang.Object obj, java.lang.String propName, java.lang.Class propertyType, java.lang.Object propertyValue, boolean clearCollection)

### addElementToCollection

    protected java.lang.Object addElementToCollection(java.lang.Object obj, java.lang.String propName, GrailsDomainClassProperty property, java.lang.Object propertyValue, boolean clearCollection)

### addElementToCollectionAt

    @java.lang.Override
    protected java.lang.Object addElementToCollectionAt(java.lang.Object obj, java.lang.String propertyName, java.util.Collection collection, java.lang.Object index, java.lang.Object val)

### bind

    @java.lang.Override
    void bind(java.lang.Object obj, DataBindingSource source)

### bind

    @java.lang.Override
    void bind(java.lang.Object obj, DataBindingSource source, DataBindingListener listener)

### bind

    @java.lang.Override
    void bind(java.lang.Object object, DataBindingSource source, java.lang.String filter, java.util.List whiteList, java.util.List blackList, DataBindingListener listener)

### bind

    @java.lang.Override
    void bind(java.lang.Object obj, groovy.util.slurpersupport.GPathResult gpath)

### convert

    @java.lang.Override
    protected java.lang.Object convert(java.lang.Class typeToConvertTo, java.lang.Object value)

### doBind

    @java.lang.Override
    protected void doBind(java.lang.Object object, DataBindingSource source, java.lang.String filter, java.util.List whiteList, java.util.List blackList, DataBindingListener listener, java.lang.Object errors)

### getDomainClassType

    protected java.lang.Class getDomainClassType(java.lang.Object obj, java.lang.String propName)

  Parameters:
    `obj` - any object
    `propName` - the name of a property on obj
  Returns:
    the Class of the domain class referenced by propName, null if propName does not reference a domain class

### getFormatString

    @java.lang.Override
    protected java.lang.String getFormatString(BindingFormat annotation)

### getIdentifierValueFrom

    protected java.lang.Object getIdentifierValueFrom(java.lang.Object source)

### getLocale

    protected java.util.Locale getLocale()

### getPersistentInstance

    protected java.lang.Object getPersistentInstance(java.lang.Class type, java.lang.Object id)

### getReferencedTypeForCollection

    @java.lang.Override
    protected java.lang.Class getReferencedTypeForCollection(java.lang.String name, java.lang.Object target)

### initializeProperty

    @java.lang.Override
    protected java.lang.Object initializeProperty(java.lang.Object obj, java.lang.String propName, java.lang.Class propertyType, DataBindingSource source)

### isDomainClass

    protected boolean isDomainClass(java.lang.Class clazz)

### populateErrors

    protected java.lang.Object populateErrors(java.lang.Object obj, org.springframework.validation.BindingResult bindingResult)

### preprocessValue

    @java.lang.Override
    protected java.lang.Object preprocessValue(java.lang.Object propertyValue)

### processIndexedProperty

    @java.lang.Override
    protected java.lang.Object processIndexedProperty(java.lang.Object obj, groovy.lang.MetaProperty metaProperty, IndexedPropertyReferenceDescriptor indexedPropertyReferenceDescriptor, java.lang.Object val, DataBindingSource source, DataBindingListener listener, java.lang.Object errors)

### processProperty

    @java.lang.Override
    protected java.lang.Object processProperty(java.lang.Object obj, groovy.lang.MetaProperty metaProperty, java.lang.Object val, DataBindingSource source, DataBindingListener listener, java.lang.Object errors)

### setDataBindingListeners

    @org.springframework.beans.factory.annotation.Autowired(required=false)
    void setDataBindingListeners(DataBindingListener[] listeners)

### setFormattedValueConverters

    @org.springframework.beans.factory.annotation.Autowired(required=false)
    void setFormattedValueConverters(FormattedValueConverter[] converters)

### setMessageSource

    @org.springframework.beans.factory.annotation.Autowired
    void setMessageSource(org.springframework.context.MessageSource messageSource)

### setPropertyValue

    @java.lang.Override
    protected java.lang.Object setPropertyValue(java.lang.Object obj, DataBindingSource source, groovy.lang.MetaProperty metaProperty, java.lang.Object propertyValue, DataBindingListener listener)

### setStructuredBindingEditors

    @org.springframework.beans.factory.annotation.Autowired(required=false)
    void setStructuredBindingEditors(TypedStructuredBindingEditor[] editors)

### setValueConverters

    @org.springframework.beans.factory.annotation.Autowired(required=false)
    void setValueConverters(ValueConverter[] converters)

Groovy Documentation