473,396 Members | 1,833 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Xerces C++ Problem

I am unable to get Xerces to write out attributes from a struct which
I am able to print out and verify is correct. The structs are defined
below as is subsection of the output.

Expand|Select|Wrap|Line Numbers
  1.  
  2. int DDAS_XML_Handler::writeResultDocument( int job_id, int
  3. num_results, DDAS_CLIENT_RESULT_DATA* results )
  4. {
  5. try
  6. {
  7.  
  8. DOMElement* data_row;
  9. DOMElement* coeff;
  10. DOMElement* root;
  11.  
  12. DOMAttr* sse_attr;
  13. DOMAttr* bin_rep_attr;
  14. DOMAttr* def_num_attr;
  15. DOMAttr* index_attr;
  16. DOMAttr* value_attr;
  17. DOMAttr* job_id_attr;
  18.  
  19. XMLCh* data_row_ch      =
  20. XMLString::transcode("data_row");
  21. XMLCh* sse_ch           = XMLString::transcode("SSE");
  22. XMLCh* bin_rep_ch       =
  23. XMLString::transcode("binary_representation");
  24. XMLCh* def_num_ch       =
  25. XMLString::transcode("definition_number");
  26. XMLCh* coeff_ch         =
  27. XMLString::transcode("coefficient");
  28. XMLCh* index_ch         =
  29. XMLString::transcode("index");
  30. XMLCh* value_ch         =
  31. XMLString::transcode("value");
  32. XMLCh* job_id_ch        =
  33. XMLString::transcode("jobID");
  34.  
  35. //printDCRD(results);
  36.  
  37. //create a DOM
  38. DOMImplementation* impl =
  39. DOMImplementationRegistry::getDOMImplementation(XMLString::transcode("Range"));
  40. DOMDocument* doc        = impl->createDocument(0,
  41. XMLString::transcode("job_results"), 0);
  42.  
  43. //document root
  44. root = doc->getDocumentElement();
  45.  
  46. //root's job ID attribute
  47. job_id_attr     = doc->createAttribute(job_id_ch);
  48.  
  49. //add the job_id attribute to root tag
  50. char* job_buffer = new char[128];
  51. sprintf( job_buffer, "%i", job_id );
  52. XMLString::trim(job_buffer);
  53. job_id_attr-
  54.         
  55.                 >setValue(XMLString::transcode(job_buffer));
  56.  
  57. root->setAttributeNode(job_id_attr);
  58. delete[] job_buffer;
  59.  
  60. //for each data row
  61. for( int i=0; i<num_results; i++ )
  62. {
  63. data_row        = doc-
  64.         
  65.                 >createElement(data_row_ch);
  66.  
  67. sse_attr        = doc-
  68.         
  69.                 >createAttribute(sse_ch);
  70.  
  71. bin_rep_attr    = doc-
  72.         
  73.                 >createAttribute(bin_rep_ch);
  74.  
  75. def_num_attr    = doc-
  76.         
  77.                 >createAttribute(def_num_ch);
  78.  
  79. //set SSE value
  80. char* sse_buffer = new char[128];
  81. sprintf( sse_buffer, "%f", results->SSEs[i] );
  82.  
  83. //set binary representation value
  84. char* br_buffer = new char[128];
  85. sprintf( br_buffer, "%s", results-
  86.         
  87.                 >bin_reps[i] );
  88.  
  89. //set defintion number value
  90. char* dn_buffer = new char[128];
  91. sprintf( dn_buffer, "%s", results-
  92.         
  93.                 >def_nums[i] );
  94.  
  95. //trim strings
  96. XMLString::trim(sse_buffer);
  97. XMLString::trim(br_buffer);
  98. XMLString::trim(dn_buffer);
  99.  
  100. //convert to XMLCh*
  101. XMLCh* sse_val     =
  102. XMLString::transcode(sse_buffer);
  103. XMLCh* bin_rep_val =
  104. XMLString::transcode(br_buffer);
  105. XMLCh* def_num_val =
  106. XMLString::transcode(dn_buffer);
  107.  
  108. //set attr values
  109. sse_attr    ->setValue(sse_val);
  110. bin_rep_attr->setValue(bin_rep_val);
  111. def_num_attr->setValue(def_num_val);
  112.  
  113. //append attribute nodes to data row
  114. data_row->setAttributeNode(sse_attr);
  115. data_row->setAttributeNode(bin_rep_attr);
  116. data_row->setAttributeNode(def_num_attr);
  117.  
  118. //append data row to root
  119. root->appendChild(data_row);
  120.  
  121. //free memory
  122. delete[] sse_buffer;
  123. delete[] br_buffer;
  124. delete[] dn_buffer;
  125. XMLString::release(&sse_val);
  126. XMLString::release(&bin_rep_val);
  127. XMLString::release(&def_num_val);
  128.  
  129. //handle coefficients on a per data row basis
  130. for( unsigned int j=0; j<results->coefficients-
  131.         
  132.                 >size; j++)
  133.  
  134. {
  135. //create coefficient element
  136. coeff = doc->createElement(coeff_ch);
  137.  
  138. //create attribute nodes
  139. index_attr = doc-
  140.         
  141.                 >createAttribute(index_ch);
  142.  
  143. value_attr = doc-
  144.         
  145.                 >createAttribute(value_ch);
  146.  
  147. //request some space for conversion
  148. char* index_buffer = new char[128];
  149. char* value_buffer = new char[128];
  150.  
  151. //convert from numeric to char*
  152. sprintf( index_buffer, "%i", results-
  153.         
  154.                 >coefficients[i].index[j] );
  155.  
  156. sprintf( value_buffer, "%f", results-
  157.         
  158.                 >coefficients[i].values[j] );
  159.  
  160. //remove whitespace
  161. XMLString::trim(index_buffer);
  162. XMLString::trim(value_buffer);
  163.  
  164. //create values as XMLCh*
  165. XMLCh* index_val =
  166. XMLString::transcode(index_buffer);
  167. XMLCh* value_val =
  168. XMLString::transcode(value_buffer);
  169.  
  170. //set values
  171. index_attr->setValue(index_val);
  172. value_attr->setValue(value_val);
  173.  
  174. coeff->setAttributeNode(index_attr);
  175. coeff->setAttributeNode(value_attr);
  176.  
  177. //append coefficient to data row
  178. data_row->appendChild(coeff);
  179.  
  180. //free memory
  181. delete[] index_buffer;
  182. delete[] value_buffer;
  183.  
  184. }//end inner for loop
  185.  
  186.  
  187. }//end outer for loop
  188.  
  189. //DOM serializer
  190. DOMWriter* writer = ((DOMImplementationLS*)impl)-
  191.         
  192.                 >createDOMWriter();
  193.  
  194. //request some space for URL
  195. char* buffer = new char[512];
  196.  
  197. //create URL based on job ID
  198. sprintf( buffer, "%sjob_%u_results.xml",
  199. DDAS_RESULT_URL, job_id );
  200.  
  201. //remove whitespace
  202. XMLString::trim(buffer);
  203.  
  204. //create URL as XMLCh*
  205. XMLCh* url_ch = XMLString::transcode(buffer);
  206.  
  207. //set output type
  208. LocalFileFormatTarget local_file( url_ch );
  209.  
  210. //set some formatting options
  211. if (writer-
  212.         
  213.                 >canSetFeature(XMLUni::fgDOMWRTDiscardDefaultContent, true))
  214.  
  215. writer-
  216.         
  217.                 >setFeature(XMLUni::fgDOMWRTDiscardDefaultContent, true);
  218.  
  219. if (writer-
  220.         
  221.                 >canSetFeature(XMLUni::fgDOMWRTFormatPrettyPrint, true))
  222.  
  223. writer-
  224.         
  225.                 >setFeature(XMLUni::fgDOMWRTFormatPrettyPrint, true);
  226.  
  227. //actually write the root node to file
  228. writer->writeNode(&local_file, *root);
  229.  
  230. //free resources
  231. writer  ->release();
  232. doc     ->release();
  233. delete[] buffer;
  234.  
  235. return 1;
  236.  
  237. }
  238. catch( XMLException& e)
  239. {
  240. char* message =
  241. XMLString::transcode( e.getMessage() );
  242. cerr << "The following error occurred during
  243. the DOM creation: " << message << endl;
  244. XMLString::release( &message );
  245. }
  246. }
  247.  
  248.  

Here are the structs used:

Expand|Select|Wrap|Line Numbers
  1.  
  2. struct REGRESSION_COEFFICIENTS
  3. {
  4. //which column are talking about
  5. int*            index;
  6.  
  7. //the value of the linear coefficient
  8. double*         values;
  9.  
  10. //the size of the struct
  11. unsigned int    size;
  12. };
  13.  
  14.  
  15. ///A struct used to hold the client result data
  16. struct DDAS_CLIENT_RESULT_DATA
  17. {
  18. /// The binary representation of the definition number -
  19. serves to disambiguate endianess
  20. char**          bin_reps;
  21.  
  22. /// The decimal representation of the combination of
  23. independent variables used in this regression (1011 base 2 == 11 base
  24. 10)
  25. char**          def_nums;
  26.  
  27. /// The sum of squared error for the linear regression
  28. double*         SSEs;
  29.  
  30. /// How many results are contained in the struct
  31. unsigned int   size;
  32.  
  33. //regression coefficients
  34. REGRESSION_COEFFICIENTS* coefficients;
  35. };
  36.  
  37.  

And here is a sample of the output:

[OUTPUT]

<data_row SSE="137.527403" binary_representation="1010111011111001"
definition_number="44793">
<coefficient index="0" value="-0.000977"/>
<coefficient index="1" value="0.000000"/>
<coefficient index="2" value="0.000000"/>
<coefficient index="3" value="-66123751426.362999"/>
<coefficient index="4" value="0.000088"/>
<coefficient index="5" value="1095801473.097510"/>
<coefficient index="6" value="0.003840"/>
<coefficient index="7" value="-26494374893.985001"/>
<coefficient index="8" value="0.000000"/>
<coefficient index="9" value="0.097907"/>
<coefficient index="10" value="0.004219"/>
<coefficient index="11" value="66123751426.363098"/>
<coefficient index="12" value="0.000000"/>
<coefficient index="13" value="-1095801473.102500"/>
<coefficient index="14" value="0.000000"/>
<coefficient index="15" value="26494374894.009701"/>
</data_row>

<data_row SSE="137.533380" binary_representation=""
definition_number="">
<coefficient index="0" value="-0.001039"/>
<coefficient index="1" value="0.097757"/>
<coefficient index="2" value="758258573.171398"/>
<coefficient index="3" value="-35123845436.044098"/>
<coefficient index="4" value="0.000000"/>
<coefficient index="5" value="0.000000"/>
<coefficient index="6" value="-464164413.890403"/>
<coefficient index="7" value="0.024555"/>
<coefficient index="8" value="0.000000"/>
<coefficient index="9" value="0.000000"/>
<coefficient index="10" value="-758258573.167233"/>
<coefficient index="11" value="35123845436.044197"/>
<coefficient index="12" value="0.000016"/>
<coefficient index="13" value="-0.004898"/>
<coefficient index="14" value="464164413.894253"/>
<coefficient index="15" value="0.000000"/>
</data_row>

<data_row SSE="137.533796" binary_representation="0111111011P>V"
definition_number="32457">
<coefficient index="0" value="-0.001034"/>
<coefficient index="1" value="0.000000"/>
<coefficient index="2" value="0.000000"/>
<coefficient index="3" value="-35209041045.623802"/>
<coefficient index="4" value="0.000000"/>
<coefficient index="5" value="0.000000"/>
<coefficient index="6" value="-425970878.520971"/>
<coefficient index="7" value="0.024583"/>
<coefficient index="8" value="0.000000"/>
<coefficient index="9" value="0.097997"/>
<coefficient index="10" value="0.004175"/>
<coefficient index="11" value="35209041045.623802"/>
<coefficient index="12" value="-0.000016"/>
<coefficient index="13" value="-0.004899"/>
<coefficient index="14" value="425970878.524831"/>
<coefficient index="15" value="0.000000"/>
</data_row>

[/OUTPUT]
Some of the output is correct, some is there but erroneous, some is
missing altogether. Each data_row element should have a
definition_number with some value between 0 and (2^16)-1. The binary
representation is merely the binary representation of the decimal
value. I have spent many hours trying to figure out what the error
is. Again, I am able to print the struct (printDCRD) at the beginning
of the method and verify that the data contained therein is correct
and present.

So, if anyone can lend me some attention cycles, I'd greatly
appreciate it.

Thanks ahead.
Jun 27 '08 #1
3 1897
On May 9, 7:26*pm, mearvk <mea...@gmail.comwrote:
I am unable to get Xerces to write out attributes from a struct which
I am able to print out and verify is correct. The structs are defined
below as is subsection of the output.

Expand|Select|Wrap|Line Numbers
  1. int DDAS_XML_Handler::writeResultDocument( int job_id, int
  2. num_results, DDAS_CLIENT_RESULT_DATA* results )
  3. * * * * {
  4. * * * * * * * * try
  5. * * * * * * * * {
  6. * * * * * * * * DOMElement* data_row;
  7. * * * * * * * * DOMElement* coeff;
  8. * * * * * * * * DOMElement* root;
  9. * * * * * * * * DOMAttr* sse_attr;
  10. * * * * * * * * DOMAttr* bin_rep_attr;
  11. * * * * * * * * DOMAttr* def_num_attr;
  12. * * * * * * * * DOMAttr* index_attr;
  13. * * * * * * * * DOMAttr* value_attr;
  14. * * * * * * * * DOMAttr* job_id_attr;
  15. * * * * * * * * XMLCh* data_row_ch * * *=
  16. XMLString::transcode("data_row");
  17. * * * * * * * * XMLCh* sse_ch * * * * * = XMLString::transcode("SSE");
  18. * * * * * * * * XMLCh* bin_rep_ch * * * =
  19. XMLString::transcode("binary_representation");
  20. * * * * * * * * XMLCh* def_num_ch * * * =
  21. XMLString::transcode("definition_number");
  22. * * * * * * * * XMLCh* coeff_ch * * * * =
  23. XMLString::transcode("coefficient");
  24. * * * * * * * * XMLCh* index_ch * * * * =
  25. XMLString::transcode("index");
  26. * * * * * * * * XMLCh* value_ch * * * * =
  27. XMLString::transcode("value");
  28. * * * * * * * * XMLCh* job_id_ch * * * *=
  29. XMLString::transcode("jobID");
  30. * * * * * * * * //printDCRD(results);
  31. * * * * * * * * //create a DOM
  32. * * * * * * * * DOMImplementation* impl =
  33. DOMImplementationRegistry::getDOMImplementation(XMLString::transcode("Range*"));
  34. * * * * * * * * DOMDocument* doc * * * *= impl->createDocument(0,
  35. XMLString::transcode("job_results"), 0);
  36. * * * * * * * * //document root
  37. * * * * * * * * root = doc->getDocumentElement();
  38. * * * * * * * * //root's job ID attribute
  39. * * * * * * * * job_id_attr * * = doc->createAttribute(job_id_ch);
  40. * * * * * * * * //add the job_id attribute to root tag
  41. * * * * * * * * char* job_buffer = new char[128];
  42. * * * * * * * * sprintf( job_buffer, "%i", job_id );
  43. * * * * * * * * XMLString::trim(job_buffer);
  44. * * * * * * * * job_id_attr->setValue(XMLString::transcode(job_buffer));
  45. * * * * * * * * root->setAttributeNode(job_id_attr);
  46. * * * * * * * * delete[] job_buffer;
  47. * * * * * * * * //for each data row
  48. * * * * * * * * for( int i=0; i<num_results; i++ )
  49. * * * * * * * * {
  50. * * * * * * * * * * * * data_row * * * *= doc->createElement(data_row_ch);
  51. * * * * * * * * * * * * sse_attr * * * *= doc->createAttribute(sse_ch);
  52. * * * * * * * * * * * * bin_rep_attr * *= doc->createAttribute(bin_rep_ch);
  53. * * * * * * * * * * * * def_num_attr * *= doc-
  54.         
  55.                 createAttribute(def_num_ch);
  •  
  • * * * * * * * * * * * * //set SSE value
  • * * * * * * * * * * * * char* sse_buffer = new char[128];
  • * * * * * * * * * * * * sprintf( sse_buffer, "%f",results->SSEs[i] );
  • * * * * * * * * * * * * //set binary representation value
  • * * * * * * * * * * * * char* br_buffer = new char[128];
  • * * * * * * * * * * * * sprintf( br_buffer, "%s", results-
  •         
  •                 bin_reps[i] );
  •  
  • * * * * * * * * * * * * //set defintion number value
  • * * * * * * * * * * * * char* dn_buffer = new char[128];
  • * * * * * * * * * * * * sprintf( dn_buffer, "%s", results-
  •         
  •                 def_nums[i] );
  •  
  • * * * * * * * * * * * * //trim strings
  • * * * * * * * * * * * * XMLString::trim(sse_buffer);
  • * * * * * * * * * * * * XMLString::trim(br_buffer);
  • * * * * * * * * * * * * XMLString::trim(dn_buffer);
  • * * * * * * * * * * * * //convert to XMLCh*
  • * * * * * * * * * * * * XMLCh* sse_val * * =
  • XMLString::transcode(sse_buffer);
  • * * * * * * * * * * * * XMLCh* bin_rep_val =
  • XMLString::transcode(br_buffer);
  • * * * * * * * * * * * * XMLCh* def_num_val =
  • XMLString::transcode(dn_buffer);
  • * * * * * * * * * * * * //set attr values
  • * * * * * * * * * * * * sse_attr * *->setValue(sse_val);
  • * * * * * * * * * * * * bin_rep_attr->setValue(bin_rep_val);
  • * * * * * * * * * * * * def_num_attr->setValue(def_num_val);
  • * * * * * * * * * * * * //append attribute nodes to data row
  • * * * * * * * * * * * * data_row->setAttributeNode(sse_attr);
  • * * * * * * * * * * * * data_row->setAttributeNode(bin_rep_attr);
  • * * * * * * * * * * * * data_row->setAttributeNode(def_num_attr);
  • * * * * * * * * * * * * //append data row to root
  • * * * * * * * * * * * * root->appendChild(data_row);
  • * * * * * * * * * * * * //free memory
  • * * * * * * * * * * * * delete[] sse_buffer;
  • * * * * * * * * * * * * delete[] br_buffer;
  • * * * * * * * * * * * * delete[] dn_buffer;
  • * * * * * * * * * * * * XMLString::release(&sse_val);
  • * * * * * * * * * * * * XMLString::release(&bin_rep_val);
  • * * * * * * * * * * * * XMLString::release(&def_num_val);
  • * * * * * * * * * * * * //handle coefficients on aper data row basis
  • * * * * * * * * * * * * for( unsigned int j=0; j<results->coefficients->size; j++)
  • * * * * * * * * * * * * {
  • * * * * * * * * * * * * * * * * //create coefficient element
  • * * * * * * * * * * * * * * * * coeff = doc->createElement(coeff_ch);
  • * * * * * * * * * * * * * * * * //create attribute nodes
  • * * * * * * * * * * * * * * * * index_attr= doc->createAttribute(index_ch);
  • * * * * * * * * * * * * * * * * value_attr= doc-
  •         
  •                 createAttribute(value_ch);
  •  
  • * * * * * * * * * * * * * * * * //request some space for conversion
  • * * * * * * * * * * * * * * * * char* index_buffer = new char[128];
  • * * * * * * * * * * * * * * * * char* value_buffer = new char[128];
  • * * * * * * * * * * * * * * * * //convert from numeric to char*
  • * * * * * * * * * * * * * * * * sprintf( index_buffer, "%i", results->coefficients[i].index[j] );
  • * * * * * * * * * * * * * * * * sprintf( value_buffer, "%f", results-
  •         
  •                 coefficients[i].values[j] );
  •  
  • * * * * * * * * * * * * * * * * //remove whitespace
  • * * * * * * * * * * * * * * * * XMLString::trim(index_buffer);
  • * * * * * * * * * * * * * * * * XMLString::trim(value_buffer);
  • * * * * * * * * * * * * * * * * //create values as XMLCh*
  • * * * * * * * * * * * * * * * * XMLCh* index_val =
  • XMLString::transcode(index_buffer);
  • * * * * * * * * * * * * * * * * XMLCh* value_val =
  • XMLString::transcode(value_buffer);
  • * * * * * * * * * * * * * * * * //set values
  • * * * * * * * * * * * * * * * * index_attr->setValue(index_val);
  • * * * * * * * * * * * * * * * * value_attr->setValue(value_val);
  • * * * * * * * * * * * * * * * * coeff->setAttributeNode(index_attr);
  • * * * * * * * * * * * * * * * * coeff->setAttributeNode(value_attr);
  • * * * * * * * * * * * * * * * * //append coefficient to data row
  • * * * * * * * * * * * * * * * * data_row->appendChild(coeff);
  • * * * * * * * * * * * * * * * * //free memory
  • * * * * * * * * * * * * * * * * delete[] index_buffer;
  • * * * * * * * * * * * * * * * * delete[] value_buffer;
  • * * * * * * * * * * * * }//end inner for loop
  • * * * * * * * * }//end outer for loop
  • * * * * * * * * //DOM serializer
  • * * * * * * * * DOMWriter* writer = ((DOMImplementationLS*)impl)-
  •         
  •                 createDOMWriter();
  •  
  • * * * * * * * * //request some space for URL
  • * * * * * * * * char* buffer = new char[512];
  • * * * * * * * * //create URL based on job ID
  • * * * * * * * * sprintf( buffer, "%sjob_%u_results.xml",
  • DDAS_RESULT_URL, job_id );
  • * * * * * * * * //remove whitespace
  • * * * * * * * * XMLString::trim(buffer);
  • * * * * * * * * //create URL as XMLCh*
  • * * * * * * * * XMLCh* url_ch = XMLString::transcode(buffer);
  • * * * * * * * * //set output type
  • * * * * * * * * LocalFileFormatTarget local_file( url_ch );
  • * * * * * * * * //set some formatting options
  • * * * * * * * * if (writer->canSetFeature(XMLUni::fgDOMWRTDiscardDefaultContent, true))
  • * * * * * * * * * * * * writer->setFeature(XMLUni::fgDOMWRTDiscardDefaultContent, true);
  • * * * * * * * * if (writer->canSetFeature(XMLUni::fgDOMWRTFormatPrettyPrint, true))
  • * * * * * * * * * * * * writer-
  •         
  •                 setFeature(XMLUni::fgDOMWRTFormatPrettyPrint, true);
  •  
  • * * * * * * * * //actually write the root node to file
  • * * * * * * * * writer->writeNode(&local_file, *root);
  • * * * * * * * * //free resources
  • * * * * * * * * writer *->release();
  • * * * * * * * * doc * * ->release();
  • * * * * * * * * delete[] buffer;
  • * * * * * * * * return 1;
  • * * * * * * * * }
  • * * * * * * * * catch( XMLException& e)
  • * * * * * * * * {
  • * * * * * * * * * * * * char* message =
  • XMLString::transcode( e.getMessage() );
  • * * * * * * * * * * * * cerr << "The following error occurred during
  • the DOM creation: " << message << endl;
  • * * * * * * * * * * * * XMLString::release( &message );
  • * * * * * * * * }
  • * * * * }
  •  

  • Here are the structs used:

    Expand|Select|Wrap|Line Numbers
    1. struct REGRESSION_COEFFICIENTS
    2. {
    3. * * * * //which column are talking about
    4. * * * * int* * * * * * *index;
    5. * * * * //the value of the linear coefficient
    6. * * * * double* * * * * values;
    7. * * * * //the size of the struct
    8. * * * * unsigned int * *size;
    9. };
    10. ///A struct used to hold the client result data
    11. struct DDAS_CLIENT_RESULT_DATA
    12. {
    13. * * * * /// The binary representation of the definition number -
    14. serves to disambiguate endianess
    15. * * * * char** * * * * *bin_reps;
    16. * * * * /// The decimal representation of the combination of
    17. independent variables used in this regression (1011 base 2 == 11 base
    18. 10)
    19. * * * * char** * * * * *def_nums;
    20. * * * * /// The sum of squared error for the linear regression
    21. * * * * double* * * * * SSEs;
    22. * * * * /// How many results are contained in the struct
    23. * * * * unsigned int * size;
    24. * * * * //regression coefficients
    25. * * * * REGRESSION_COEFFICIENTS* coefficients;
    26. };
    27.  

    And here is a sample of the output:

    [OUTPUT]

    * <data_row SSE="137.527403" binary_representation="1010111011111001"
    definition_number="44793">
    * * <coefficient index="0" value="-0.000977"/>
    * * <coefficient index="1" value="0.000000"/>
    * * <coefficient index="2" value="0.000000"/>
    * * <coefficient index="3" value="-66123751426.362999"/>
    * * <coefficient index="4" value="0.000088"/>
    * * <coefficient index="5" value="1095801473.097510"/>
    * * <coefficient index="6" value="0.003840"/>
    * * <coefficient index="7" value="-26494374893.985001"/>
    * * <coefficient index="8" value="0.000000"/>
    * * <coefficient index="9" value="0.097907"/>
    * * <coefficient index="10" value="0.004219"/>
    * * <coefficient index="11" value="66123751426.363098"/>
    * * <coefficient index="12" value="0.000000"/>
    * * <coefficient index="13" value="-1095801473.102500"/>
    * * <coefficient index="14" value="0.000000"/>
    * * <coefficient index="15" value="26494374894.009701"/>
    * </data_row>

    * <data_row SSE="137.533380" binary_representation=""
    definition_number="">
    * * <coefficient index="0" value="-0.001039"/>
    * * <coefficient index="1" value="0.097757"/>
    * * <coefficient index="2" value="758258573.171398"/>
    * * <coefficient index="3" value="-35123845436.044098"/>
    * * <coefficient index="4" value="0.000000"/>
    * * <coefficient index="5" value="0.000000"/>
    * * <coefficient index="6" value="-464164413.890403"/>
    * * <coefficient index="7" value="0.024555"/>
    * * <coefficient index="8" value="0.000000"/>
    * * <coefficient index="9" value="0.000000"/>
    * * <coefficient index="10" value="-758258573.167233"/>
    * * <coefficient index="11" value="35123845436.044197"/>
    * * <coefficient index="12" value="0.000016"/>
    * * <coefficient index="13" value="-0.004898"/>
    * * <coefficient index="14" value="464164413.894253"/>
    * * <coefficient index="15" value="0.000000"/>
    * </data_row>

    * <data_row SSE="137.533796" binary_representation="0111111011P>V"
    definition_number="32457">
    * * <coefficient index="0" value="-0.001034"/>
    * * <coefficient index="1" value="0.000000"/>
    * * <coefficient index="2" value="0.000000"/>
    * * <coefficient index="3" value="-35209041045.623802"/>
    * * <coefficient index="4" value="0.000000"/>
    * * <coefficient index="5" value="0.000000"/>
    * * <coefficient index="6" value="-425970878.520971"/>
    * * <coefficient index="7" value="0.024583"/>
    * * <coefficient index="8" value="0.000000"/>
    * * <coefficient index="9" value="0.097997"/>
    * * <coefficient index="10" value="0.004175"/>
    * * <coefficient index="11" value="35209041045.623802"/>
    * * <coefficient index="12" value="-0.000016"/>
    * * <coefficient index="13" value="-0.004899"/>
    * * <coefficient index="14" value="425970878.524831"/>
    * * <coefficient index="15" value="0.000000"/>
    * </data_row>

    [/OUTPUT]

    Some of the output is correct, some is there but erroneous, some is
    missing altogether. Each data_row element should have a
    definition_number with some value between 0 and (2^16)-1. The binary
    representation is merely the binary representation of the decimal
    value. I have spent many hours trying to figure out what the error
    is. *Again, I am able to print the struct (printDCRD) at the beginning
    of the method and verify that the data contained therein is correct
    and present.

    So, if anyone can lend me some attention cycles, I'd greatly
    appreciate it.

    Thanks ahead. Anyone?
    Jun 27 '08 #2
    Anyone?

    Have you tried asking on the mailing list specifically for Xerces C++?

    (I haven't used the C++ version in about five years. I might be able to
    dig through this, but given the time it'd take for me to to so you could
    probably get a faster answer by asking the folks actually using and
    developing that parser.)
    Jun 27 '08 #3
    On May 11, 8:54*pm, "Joseph J. Kesselman" <keshlam-nos...@comcast.net>
    wrote:
    Anyone?

    Have you tried asking on the mailing list specifically for Xerces C++?

    (I haven't used the C++ version in about five years. I might be able to
    dig through this, but given the time it'd take for me to to so you could
    probably get a faster answer by asking the folks actually using and
    developing that parser.)
    I'll try it.
    Jun 27 '08 #4

    This thread has been closed and replies have been disabled. Please start a new discussion.

    Similar topics

    3
    by: Roy Benjamin | last post by:
    I'm developing a WEB service for Sun ONE deployment (AppServer7). I'm developing on Windows XP Pro though will deploy on Solaris, Sun AppServer7 includes a XercesImpl.jar in share/lib. 2 kb...
    2
    by: Sylwester Ba³a | last post by:
    Hi, I have problem with Xerces can someone help me? I have implementation Xerces in Visual C++ 6.0. Xerces is only an interface of my application. Everything seems to be working well when I...
    0
    by: Waseem | last post by:
    Hi I have looked and tried everything and i still cant sort this out i have no idea why this wont work I am using Xerces Perl on Windows and Debian to try this and it wont work on both of...
    0
    by: Jim Phelps | last post by:
    After having memory leak issues with Xerces-c 2.3.0 for Solaris 2.7 for CC 6.2 I have decided to update to at least 2.4. I have downloaded the binary tarball and have installed it on my...
    0
    by: Dale Gerdemann | last post by:
    I've been trying to use DOM level 3 with xerces-2_6_2. There's a sample called samples/DOM3.java, but I've had trouble with compilation. I've downloaded Xerces-J-bin.2.6.2 and...
    4
    by: Sanjay Kumar | last post by:
    Folks ! I am working with VC++ after a long time and having problem linking latest xerces 2.7 in VC++ 2005 Express Edition. I have done following: 1. downloaded and unpacked the the...
    3
    by: Matt | last post by:
    Hello, Summary: Where can one download a Xerces-C (XML pardser) dynamic library file (.DLL file) for Windows (Win98/WinNT/Win2k/WinXP/Win2003, including server flavors; don't need to support...
    2
    by: Vlad Zorinov | last post by:
    I'm getting the following error after a couple of months of XML processing, using Xerces 2.0.0 in an apache tomcat. Does anyone have any ideas what this problem may be or what I should do to solve...
    3
    by: Raphael Tagliani | last post by:
    (english version below) Bonjour! Je travaille sur un gros projet java, qui parse beaucoup de fichiers xml au lancement d'un serveur. Nous avons un problème de concurrence qu lancement. En...
    1
    by: Blocksom | last post by:
    I am new to Java and XML and I am trying to solve a problem that has bothered for few days. I have download the parser Xerser-1.4.3 and jdk1.5.0_06I install the JDK first and test it, it...
    0
    by: Charles Arthur | last post by:
    How do i turn on java script on a villaon, callus and itel keypad mobile phone
    0
    by: ryjfgjl | last post by:
    In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
    0
    BarryA
    by: BarryA | last post by:
    What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
    1
    by: nemocccc | last post by:
    hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
    0
    by: Hystou | last post by:
    There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
    0
    Oralloy
    by: Oralloy | last post by:
    Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
    0
    jinu1996
    by: jinu1996 | last post by:
    In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
    0
    by: Hystou | last post by:
    Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
    0
    tracyyun
    by: tracyyun | last post by:
    Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

    By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

    To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.