org.apache.cocoon.forms.binding
Class ContextJXPathBinding

java.lang.Object
  extended by org.apache.avalon.framework.logger.AbstractLogEnabled
      extended by org.apache.cocoon.forms.binding.JXPathBindingBase
          extended by org.apache.cocoon.forms.binding.ComposedJXPathBindingBase
              extended by org.apache.cocoon.forms.binding.ContextJXPathBinding
All Implemented Interfaces:
LogEnabled, Binding
Direct Known Subclasses:
GroupJXPathBinding, StructJXPathBinding

public class ContextJXPathBinding
extends ComposedJXPathBindingBase

ContextJXPathBinding provides an implementation of a Binding that narrows the binding scope to some xpath-context on the target objectModel to load and save from.

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

Field Summary
 
Fields inherited from class org.apache.cocoon.forms.binding.JXPathBindingBase
classes, parent
 
Constructor Summary
ContextJXPathBinding(JXPathBindingBuilderBase.CommonAttributes commonAtts, String contextPath, JXPathBindingBase[] childBindings)
          Constructs ContextJXPathBinding for the specified xpath sub-context
ContextJXPathBinding(JXPathBindingBuilderBase.CommonAttributes commonAtts, String contextPath, String factoryClassName, JXPathBindingBase[] childBindings)
          Constructs ContextJXPathBinding for the specified xpath sub-context and optional JXPath factory class.
 
Method Summary
 void doLoad(Widget frmModel, org.apache.commons.jxpath.JXPathContext jxpc)
          Actively performs the binding from the ObjectModel wrapped in a jxpath context to the CocoonForm.
 void doSave(Widget frmModel, org.apache.commons.jxpath.JXPathContext jxpc)
          Actively performs the binding from the CocoonForm to the ObjectModel wrapped in a jxpath context.
 String getFactoryClassName()
           
 String getXPath()
          To allow child classes to know which path they bind to
 String toString()
           
 
Methods inherited from class org.apache.cocoon.forms.binding.ComposedJXPathBindingBase
enableLogging, getChildBindings, getClass
 
Methods inherited from class org.apache.cocoon.forms.binding.JXPathBindingBase
getCommonAtts, getEnclosingLibrary, getId, getLocation, isValid, loadFormFromModel, loadFormFromModel, saveFormToModel, saveFormToModel, selectWidget, setEnclosingLibrary, setParent
 
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
getLogger, setupLogger, setupLogger, setupLogger
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ContextJXPathBinding

public ContextJXPathBinding(JXPathBindingBuilderBase.CommonAttributes commonAtts,
                            String contextPath,
                            JXPathBindingBase[] childBindings)
Constructs ContextJXPathBinding for the specified xpath sub-context


ContextJXPathBinding

public ContextJXPathBinding(JXPathBindingBuilderBase.CommonAttributes commonAtts,
                            String contextPath,
                            String factoryClassName,
                            JXPathBindingBase[] childBindings)
Constructs ContextJXPathBinding for the specified xpath sub-context and optional JXPath factory class.

Method Detail

getFactoryClassName

public String getFactoryClassName()

doLoad

public void doLoad(Widget frmModel,
                   org.apache.commons.jxpath.JXPathContext jxpc)
            throws BindingException
Actively performs the binding from the ObjectModel wrapped in a jxpath context to the CocoonForm.

Overrides:
doLoad in class ComposedJXPathBindingBase
Throws:
BindingException

doSave

public void doSave(Widget frmModel,
                   org.apache.commons.jxpath.JXPathContext jxpc)
            throws BindingException
Actively performs the binding from the CocoonForm to the ObjectModel wrapped in a jxpath context.

Overrides:
doSave in class ComposedJXPathBindingBase
Throws:
BindingException

getXPath

public String getXPath()
To allow child classes to know which path they bind to

Overrides:
getXPath in class ComposedJXPathBindingBase

toString

public String toString()
Overrides:
toString in class Object


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