I have code:

public class Test_bean
{

   private String id;
   private String v_Test_bean;

   public Test_bean()
   {

   }

   public String getId()
   {
      return id;
   }

   public void setId(String id)
   {
      this.id = id;
   }

   public String getV_Test_bean()
   {
      return v_Test_bean;
   }

   public void setV_Test_bean(String test_bean)
   {
      v_Test_bean = test_bean;
   }

}

and xml file:

<?xml version="1.0" encoding="UTF-8"?>
<test_bean id="1">
Mister Jones
</test_bean>

and mapping file:

<?xml version="1.0"?>

<mapping>
<class name="com.xyz.Test_bean">

<map-to xml="test_bean"/>

<field name="id" type="string">
<bind-xml name="id" node="attribute"/>
</field>

<field name="v_Test_bean" type="string">
<bind-xml name="test_bean" node="element"/>
</field>
</class>
</mapping>

and I got the following errors when I ran my program:

OK-Util.getApplicationContext-OK
org.springframework.oxm.UnmarshallingFailureException: Castor unmarshalling exception; nested exception is org.exolab.castor.xml.MarshalException: Illegal Text data found as child of: test_bean
  value: "Mister Jones"{File: [not available]; line: 4; column: 13}
org.springframework.oxm.UnmarshallingFailureException: Castor unmarshalling exception; nested exception is org.exolab.castor.xml.MarshalException: Illegal Text data found as child of: test_bean
  value: "Mister Jones"{File: [not available]; line: 4; column: 13}

Any help?

-Henry


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

   http://xircles.codehaus.org/manage_email


Reply via email to