org.apache.cocoon.forms.binding
Interface Binding

All Known Implementing Classes:
AbstractCustomBinding, AggregateJXPathBinding, CaseJXPathBinding, ClassJXPathBinding, ComposedJXPathBindingBase, ContextJXPathBinding, CustomJXPathBinding, CustomValueWrapBinding, DeleteNodeJXPathBinding, EnhancedRepeaterJXPathBinding, GroupJXPathBinding, ImportJXPathBinding, InsertBeanJXPathBinding, InsertNodeJXPathBinding, JavaScriptJXPathBinding, JXPathBindingBase, MultiValueJXPathBinding, NewJXPathBinding, RepeaterJXPathBinding, SetAttributeJXPathBinding, SimpleRepeaterJXPathBinding, StructJXPathBinding, TempRepeaterJXPathBinding, TreeModelJXPath, UnionJXPathBinding, ValueJXPathBinding

public interface Binding

Binding declares the methods to 'bind' (i.e. 'load' and 'save') information elements from some back-end model (2nd argument) to and from a existing Cocoon Form Widget.

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

Method Summary
 Binding getClass(String id)
          Gets a binding class.
 Library getEnclosingLibrary()
          returns the local library for this tree of bindings
 String getId()
          Gets binding definition id.
 boolean isValid()
          checks for deep validity of this binding tree (taking into accound included libraries)
 void loadFormFromModel(Widget frmModel, Object objModel)
          Loads the information-elements from the objModel to the frmModel.
 void saveFormToModel(Widget frmModel, Object objModel)
          Saves the infortmation-elements to the objModel from the frmModel.
 void setEnclosingLibrary(Library lib)
          sets the library this binding is a part of
 void setParent(Binding binding)
          Sets parent binding.
 

Method Detail

setParent

void setParent(Binding binding)
Sets parent binding.

Parameters:
binding - Parent of this binding.

getId

String getId()
Gets binding definition id.


getEnclosingLibrary

Library getEnclosingLibrary()
returns the local library for this tree of bindings


setEnclosingLibrary

void setEnclosingLibrary(Library lib)
sets the library this binding is a part of


isValid

boolean isValid()
checks for deep validity of this binding tree (taking into accound included libraries)


getClass

Binding getClass(String id)
Gets a binding class.

Parameters:
id - Id of binding class to get.

loadFormFromModel

void loadFormFromModel(Widget frmModel,
                       Object objModel)
                       throws BindingException
Loads the information-elements from the objModel to the frmModel.

Parameters:
frmModel -
objModel -
Throws:
BindingException

saveFormToModel

void saveFormToModel(Widget frmModel,
                     Object objModel)
                     throws BindingException
Saves the infortmation-elements to the objModel from the frmModel.

Parameters:
frmModel -
objModel -
Throws:
BindingException


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