Hi,
Please help me out...
I'm trying to build a java
BizComponent (based on your Voters Sample).
I modified voterSample.java to add a method like below :
The java method I added in VoterSample.java is...
************
public static String balajis(Voter[] v) {
String s = "balaji:length" + "\n";
Voter voter = null;
s = s + v.length + "\n";
for (int i = 0; i < v.length; i++) {
voter = v[i];
s = s + ((voter == null) ? "missingVoter" :
i + " " + voter.toString()) + "\n";
}
return s;
}
*****************
Also check attached SBalajixbc.xbc and SBalajiDoc.xbd. (pasted below in this message)
My Java class method balajis is expected to get array of voter objects with values from input
XML. But it's not getting what i passed from my input parameters. (it's returning out default voter details...which you guys set in voter.java constructor).
Here is the sample XML that i am passing as input xml for the xbd.
<Document>
<voter>
<ID>001</ID>
<firstLastName>bkshatriy</firstLastName>
<party>Rep</party>
</voter>
<voter>
<ID>002</ID>
<firstLastName>bkshatriy2</firstLastName>
<party>Rep2</party>
</voter>
</Document>
please refer attachments..
Please help me out...
The SBalajiDoc.xbd which i am using is
********************
<?xml version="1.0" encoding="UTF-8"?>
<Document xmlns:xa="http://xaware.org/xas/ns1" xa:version="5.0" xa:on_error="xa-doc::/Document/Error" xa:visible="yes">
<xa:description />
<xa:input>
<xa:param xa:name="AllVoters" xa:datatype="xml" xa:default="" xa:description="" xa:schemaElement="XMLdata" />
</xa:input>
<Element xa:bizcomp="myCompany/SBalajiXbc.xbc" xa:remove="yes" />
<Error xa:include="no" xa:set_result="failure">
<detai,
Please help me out...
I'm trying to build a java bizcomponent (based on your Voters Sample).
I modified voterSample.java to add a method like below :
The java method I added in VoterSample.java is...
************
public static String balajis(Voter[] v) {
String s = "balaji:length" + "\n";
Voter voter = null;
s = s + v.length + "\n";
for (int i = 0; i < v.length; i++) {
voter = v[i];
s = s + ((voter == null) ? "missingVoter" :
i + " " + voter.toString()) + "\n";
}
return s;
}
*****************
Also check attached SBalajixbc.xbc and SBalajiDoc.xbd. (pasted below in this message)
My Java class method balajis is expected to get array of voter objects with values from input XML. But it's not getting what i passed from my input parameters. (it's returning out default voter details...which you guys set in voter.java constructor).
Here is the sample XML that i am passing as input xml for the xbd.
<Document>
<voter>
<ID>001</ID>
<firstLastName>bkshatriy</firstLastName>
<party>Rep</party>
</voter>
<voter>
<ID>002</ID>
<firstLastName>bkshatriy2</firstLastName>
<party>Rep2</party>
</voter>
</Document>
please refer attachments..
Please help me out...
The SBalajiDoc.xbd which i am using is
********************
<?xml version="1.0" encoding="UTF-8"?>
<Document xmlns:xa="http://xaware.org/xas/ns1" xa:version="5.0" xa:on_error="xa-doc::/Document/Error" xa:visible="yes">
<xa:description />
<xa:input>
<xa:param xa:name="AllVoters" xa:datatype="xml" xa:default="" xa:description="" xa:schemaElement="XMLdata" />
</xa:input>
<Element xa:bizcomp="myCompany/SBalajiXbc.xbc" xa:remove="yes" />
<Error xa:include="no" xa:set_result="failure">
<detail>$xavar:error_stack$</detail>
</Error>
</Document>
*************************
the XBC which i am using is SBalajixbc.xbc which is attached here...