Vadim,

+1 from me too. Please go ahead with this.

Thanks,
dims

--- Carsten Ziegeler <[EMAIL PROTECTED]> wrote:
> > Vadim Gritsenko wrote:
> > 
> > Cocooners,
> > 
> > After migrating to new Source interface (extended from
> > XMLizable), certain exception handling issues arised:
> > 
> >  o Source is unable to throw ProcessingException anymore
> > (from toSAX method).
> > 
> > Result (in SitemapSource):
> > 
> >  o ProcessingException is wrapped into SAXException
> > 
> > But, getInputSource/getInputStream still can throw
> > ProcesingException. Result:
> > 
> >  o ProcessingException is wrapped into SAXException, which is
> > wrapped into ProcessingException (again)
> > 
> > As a result, Sitemap might get either SAXException[ProcessingException],
> > or even ProcessingException[SAXException[ProcessingException]],
> > which makes exception handling code ugly and unclear.
> > 
> > Same story applies to FileGenerator and may be to other
> > components as well.
> > 
> > Proposed solution:
> > 1. Preserve meaningful exceptions up to the exception
> > handling point (sitemap)
> +1
> 
> > 2. Add "throws ProcessingException" to toSAX method of
> > XMLizable (to satisfy point 1)
> +1, AFAIR the old stream() method did throw the ProcessingException.
> 
> 
> Carsten
> 
> > 3. Think about how to handle exception before writing
> > "throw new ...Exception("...", exception)"
> > 
> > I would love to hear suggestions from others on this topic.
> > 
> > Regards,
> > Vadim
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, email: [EMAIL PROTECTED]
> > 
> > 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, email: [EMAIL PROTECTED]
> 


=====
Davanum Srinivas, JNI-FAQ Manager
http://www.jGuru.com/faq/JNI

__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
http://im.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

Reply via email to