You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jaxme-dev@ws.apache.org by "Jochen Wiedmann (JIRA)" <ja...@ws.apache.org> on 2004/11/03 22:09:36 UTC

[jira] Closed: (JAXME-7) PATCH JMHandlerImpl improved exception text

     [ http://nagoya.apache.org/jira/browse/JAXME-7?page=history ]
     
Jochen Wiedmann closed JAXME-7:
-------------------------------

    Assign To:     (was: JaxMe Developers mailing list)

> PATCH JMHandlerImpl improved exception text
> -------------------------------------------
>
>          Key: JAXME-7
>          URL: http://nagoya.apache.org/jira/browse/JAXME-7
>      Project: JaxMe
>         Type: Bug
>   Components: JaxMe Core
>     Versions: current (nightly)
>  Environment: Operating System: Other
> Platform: Other
>     Reporter: Henrik Vendelbo

>
> The current text seemed very confusing on an issue today. Only after 2 hours 
> did I realise that I was actually dealing with empty values. This patch adds 
> quotes around the offending values, so empty values are immediately obvious.
>   public void addAttribute(String pNamespaceURI, String pLocalName,
>                             String pValue) throws SAXException {
>     throw new SAXParseException("Unknown attribute: '" + pLocalName +
>                                  "' in namespace '" + pNamespaceURI +"'",
>                                  getDocumentLocator());
>   }
>   public void startElement(String pNamespaceURI, String pLocalName,
>                             String pQName, Attributes pAttr) throws 
> SAXException {
>     validationEvent(ValidationEvent.WARNING,
>                     "Unexpected element: '" + pQName + "'",
>                     ValidationEvents.EVENT_UNEXPECTED_CHILD_ELEMENT);
>   }
>   public void characters(char[] pChars, int pOffset, int pLen) throws 
> SAXException {
>     for (int i = 0;  i < pLen;  i++) {
>       if (!Character.isWhitespace(pChars[pOffset+i])) {
>         validationEvent(ValidationEvent.WARNING, "Unexpected non-whitespace 
> characters:'" +
>                         new String(pChars, pOffset, pLen) + "'",
>                         ValidationEvents.EVENT_UNEXPECTED_TEXTUAL_CONTENTS);
>       }
>     }
>   }
>   public void endElement(String pNamespaceURI, String pLocalName,
>                           String pQName) throws SAXException {
>     validationEvent(ValidationEvent.WARNING,
>                     "Unexpected element: '" + pQName + "'",
>                     ValidationEvents.EVENT_UNEXPECTED_CHILD_ELEMENT);
>   }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://nagoya.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: jaxme-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: jaxme-dev-help@ws.apache.org