[Practicalxml-commits] SF.net SVN: practicalxml:[97] branches/dev-1.1/src/main/java/net/sf/ practic
Brought to you by:
kdgregory
From: Auto-Generated S. C. M. <pra...@li...> - 2009-08-10 22:31:11
|
Revision: 97 http://practicalxml.svn.sourceforge.net/practicalxml/?rev=97&view=rev Author: kdgregory Date: 2009-08-10 22:30:50 +0000 (Mon, 10 Aug 2009) Log Message: ----------- introduce ConversionException Modified Paths: -------------- branches/dev-1.1/src/main/java/net/sf/practicalxml/converter/Bean2XmlDriver.java Added Paths: ----------- branches/dev-1.1/src/main/java/net/sf/practicalxml/converter/ConversionException.java Modified: branches/dev-1.1/src/main/java/net/sf/practicalxml/converter/Bean2XmlDriver.java =================================================================== --- branches/dev-1.1/src/main/java/net/sf/practicalxml/converter/Bean2XmlDriver.java 2009-07-23 23:28:30 UTC (rev 96) +++ branches/dev-1.1/src/main/java/net/sf/practicalxml/converter/Bean2XmlDriver.java 2009-08-10 22:30:50 UTC (rev 97) @@ -179,7 +179,7 @@ } catch (IntrospectionException ee) { - throw new RuntimeException("introspection failure", ee); + throw new ConversionException("introspection failure", ee); } } @@ -198,7 +198,7 @@ } catch (Exception ee) { - throw new RuntimeException("unable to retrieve bean value", ee); + throw new ConversionException("unable to retrieve bean value", ee); } dispatch(propDesc.getName(), value, handler); Added: branches/dev-1.1/src/main/java/net/sf/practicalxml/converter/ConversionException.java =================================================================== --- branches/dev-1.1/src/main/java/net/sf/practicalxml/converter/ConversionException.java (rev 0) +++ branches/dev-1.1/src/main/java/net/sf/practicalxml/converter/ConversionException.java 2009-08-10 22:30:50 UTC (rev 97) @@ -0,0 +1,36 @@ +// Copyright 2008-2009 severally by the contributors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package net.sf.practicalxml.converter; + + +/** + * A runtime exception thrown for any conversion error. Will always have a + * message, and typically contains a wrapped exception. + */ +public class ConversionException +extends RuntimeException +{ + private static final long serialVersionUID = 1L; + + public ConversionException(String message, Throwable cause) + { + super(message, cause); + } + + public ConversionException(String message) + { + super(message); + } +} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |