/** * This method is invoked by the JAXB implementation on each instance when unmarshalling completes. * * @param parent * The parent object in the object tree. * @param unmarshaller * The unmarshaller that generated the instance. */ public void afterUnmarshal(Unmarshaller unmarshaller, Object parent) { setParent(parent); }
@Override public Worksheet unmarshal( java.io.InputStream is ) throws JAXBException { Worksheet w = super.unmarshal(is); w.setParent(this); // workaround for JAXB in Java 8 setting parent to JAXBElement! return w; }
@Override public void setJaxbElement(Worksheet jaxbElement) { super.setJaxbElement(jaxbElement); jaxbElement.setParent(this); // if you create a new WorksheetPart }
@Override public Worksheet unmarshal(org.w3c.dom.Element el) throws JAXBException { Worksheet w = super.unmarshal(el); w.setParent(this); // presume JAXB gets in wrong here too return w; }
/** * This method is invoked by the JAXB implementation on each instance when unmarshalling completes. * * @param parent * The parent object in the object tree. * @param unmarshaller * The unmarshaller that generated the instance. */ public void afterUnmarshal(Unmarshaller unmarshaller, Object parent) { setParent(parent); }
@Override public Worksheet unmarshal(org.w3c.dom.Element el) throws JAXBException { Worksheet w = super.unmarshal(el); w.setParent(this); // presume JAXB gets in wrong here too return w; }
@Override public void setJaxbElement(Worksheet jaxbElement) { super.setJaxbElement(jaxbElement); jaxbElement.setParent(this); // if you create a new WorksheetPart }
@Override public Worksheet unmarshal( java.io.InputStream is ) throws JAXBException { Worksheet w = super.unmarshal(is); w.setParent(this); // workaround for JAXB in Java 8 setting parent to JAXBElement! return w; }