The MarshalException is a subclass of the {@link javax.xml.bind.JAXBException} being thrown if theunmarshalling of a JAXB object failed.
MarshalException
645646647648649650651652653
// if the handler says "abort", we will not return the object // from the unmarshaller.getResult() if(!recover) aborted = true; if( !canRecover || !recover ) throw new SAXException( new UnmarshalException( event.getMessage(), event.getLinkedException() ) ); }
532533534535536537538
throw new IllegalStateException(); if(!aborted) return result; // there was an error. throw new UnmarshalException((String)null); }
599600601602603604605606607
// from the unmarshaller.getResult() if(!recover) aborted = true; if( !canRecover || !recover ) throw new SAXParseException2( event.getMessage(), locator, new UnmarshalException( event.getMessage(), event.getLinkedException() ) ); }
208209210211212213214215216217218
reader.setErrorHandler(coordinator); try { reader.parse(source); } catch( IOException e ) { throw new UnmarshalException(e); } catch( SAXException e ) { throw createUnmarshalException(e); } Object result = connector.getResult();
416417418419420421422423
// that could throw away some meaningful exception information. Throwable ne = e.getNestedException(); if(ne instanceof JAXBException) return (JAXBException)ne; if(ne instanceof SAXException) return new UnmarshalException(ne); return new UnmarshalException(e); }
452453454455456457458
519520521522523524525526527
110111112113114115116117118119120
u.coordinator.setThreadAffinity(); u.coordinator.pushCoordinator(); try { return a.unmarshal(v); } catch (Exception e) { throw new UnmarshalException(e); } finally { u.coordinator.popCoordinator(); u.coordinator.resetThreadAffinity(); } }
191192193194195196197198199200201
390391392393394395396397