org.apache.cocoon.forms.binding
Class InsertBeanJXPathBinding
java.lang.Object
org.apache.cocoon.util.AbstractLogEnabled
org.apache.cocoon.forms.binding.JXPathBindingBase
org.apache.cocoon.forms.binding.InsertBeanJXPathBinding
- All Implemented Interfaces:
- Binding
- public class InsertBeanJXPathBinding
- extends JXPathBindingBase
InsertBeanJXPathBinding provides an implementation of a Binding
that inserts a new instance of the specified bean (classname) or a new instance
created by the model itself into the target back-end model upon save.
NOTES:
- This Binding does not perform any actions when loading.
- This expects the back-end model to be a Java Bean model.
- Version:
- $Id: InsertBeanJXPathBinding.html 1304280 2012-03-23 11:18:01Z ilgrosso $
Methods inherited from class org.apache.cocoon.forms.binding.JXPathBindingBase |
getClass, getCommonAtts, getEnclosingLibrary, getId, getLocation, isValid, loadFormFromModel, loadFormFromModel, saveFormToModel, saveFormToModel, selectWidget, setEnclosingLibrary, setParent |
Methods inherited from class org.apache.cocoon.util.AbstractLogEnabled |
getLogger, setLogger |
InsertBeanJXPathBinding
public InsertBeanJXPathBinding(JXPathBindingBuilderBase.CommonAttributes commonAtts,
String className,
String addMethod)
- Constructs InsertBeanJXPathBinding
getClassName
public String getClassName()
getAddMethodName
public String getAddMethodName()
doLoad
public void doLoad(Widget frmModel,
org.apache.commons.jxpath.JXPathContext jxpc)
- Do-nothing implementation of the interface.
- Specified by:
doLoad
in class JXPathBindingBase
doSave
public void doSave(Widget frmModel,
org.apache.commons.jxpath.JXPathContext jxpc)
throws BindingException
- Registers a JXPath Factory on the JXPath Context.
The factory will insert a new instance of the specified bean (classname)
inside this object into the target objectmodel or it will just call the
add method if classname is null.
- Specified by:
doSave
in class JXPathBindingBase
- Throws:
BindingException
toString
public String toString()
Copyright © 1999-2008 The Apache Software Foundation. All Rights Reserved.