The following comment has been added to this issue:

     Author: Dennis Sosnoski
    Created: Sat, 29 May 2004 3:57 PM
       Body:
The above two comments refer to a separate binding definition problem that happened to 
result in the same error message. The only effect of this bug is to refer to the wrong 
element name in the error message. It does not represent any broken functionality, and 
does not require any work around.
---------------------------------------------------------------------
View this comment:
  http://jira.codehaus.org/browse/JIBX-2?page=comments#action_20192

---------------------------------------------------------------------
View the issue:
  http://jira.codehaus.org/browse/JIBX-2

Here is an overview of the issue:
---------------------------------------------------------------------
        Key: JIBX-2
    Summary: Unmarshalling error "Expected end tag" reports wrong tag
       Type: Bug

     Status: Open
   Priority: Minor

 Original Estimate: Unknown
 Time Spent: Unknown
  Remaining: Unknown

    Project: JiBX
 Components: 
             core
   Versions:
             1.0-beta3a

   Assignee: Dennis Sosnoski
   Reporter: Dennis Sosnoski

    Created: Sat, 27 Mar 2004 12:39 PM
    Updated: Sat, 29 May 2004 3:57 PM

Description:
In a case where a collection that's expected to be the last part of an element's 
content is followed by another element, the error message "Expected end tag, found 
start tag..." is generated but identifies the first child element of the unexpected 
element. Here's the binding:

        <mapping class="cap.data.DataSet" extends="cap.data.Rule" name="DataSet">
                <structure map-as="cap.data.Rule"/>
                <collection add-method="addAction" item-type="cap.data.Action" 
iter-method="actionIterator"/>
                <collection add-method="addDataItem" item-type="cap.data.DataItem" 
iter-method="dataItemIterator"/>
        </mapping>

Here's the actual XML:

        <DataSet label="START">
                <Message>Is the patient greater than or = 16 years of age?</Message>
                <Selection name="age" required="YES" tabular="NO" type="RADIO">
                        <SelectedItem default="NO" returnValue="no" 
textEntry="NO">No</SelectedItem>
                        <SelectedItem default="NO" returnValue="yes" 
textEntry="NO">Yes</SelectedItem>
                </Selection>
                <Action label="REJECT-AGE">
                        <Condition>START.age = "no"</Condition>
                </Action>
                <Action label="REASON">
                        <Condition>START.age = "yes"</Condition>
                </Action>
        </DataSet>

where Selection is a type of cap.data.DataItem. The generated error is 
"org.jibx.runtime.JiBXException: Expected end tag, found start tag "Condition" (line 
10, col 15)".

It looks like the collection close handling code needs to be adjusted to make sure the 
error message refers to the proper tag.


---------------------------------------------------------------------
JIRA INFORMATION:
This message is automatically generated by JIRA.

If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa

If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira



-------------------------------------------------------
This SF.Net email is sponsored by: Oracle 10g
Get certified on the hottest thing ever to hit the market... Oracle 10g. 
Take an Oracle 10g class now, and we'll give you the exam FREE.
http://ads.osdn.com/?ad_id=3149&alloc_id=8166&op=click
_______________________________________________
jibx-devs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jibx-devs

Reply via email to