/** * @return a @see java.io.InputStream for an existing entry in * the current abstract archive * @param the entry name */ public InputStream getEntry(String name) throws IOException { return deployObject.getEntry(name); }
/** * @return a @see java.io.InputStream for an existing entry in * the current abstract archive * @param the entry name */ public InputStream getEntry(String name) throws IOException { return deployObject.getEntry(name); }
private static XmlObject loadDefaultData(DDBeanRoot root) { InputStream in = root.getDeployableObject().getEntry("META-INF/geronimo-ra.xml"); if(in == null) { GerConnectorDocument doc = GerConnectorDocument.Factory.newInstance(); doc.addNewConnector().addNewResourceadapter(); return doc; } else { try { XmlObject result = GerConnectorDocument.Factory.parse(in); in.close(); return result; } catch (XmlException e) { throw new RuntimeException("Unable to load default Geronimo RA data", e); } catch (IOException e) { throw new RuntimeException("Unable to load default Geronimo RA data", e); } } }
private static XmlObject loadDefaultData(DDBeanRoot root) { InputStream in = root.getDeployableObject().getEntry("META-INF/geronimo-ra.xml"); if(in == null) { GerConnectorDocument doc = GerConnectorDocument.Factory.newInstance(); doc.addNewConnector().addNewResourceadapter(); return doc; } else { try { XmlObject result = GerConnectorDocument.Factory.parse(in); in.close(); return result; } catch (XmlException e) { throw new RuntimeException("Unable to load default Geronimo RA data", e); } catch (IOException e) { throw new RuntimeException("Unable to load default Geronimo RA data", e); } } }
private XmlObject loadDefaultData(DDBeanRoot root) { InputStream in = root.getDeployableObject().getEntry("META-INF/geronimo-ra.xml"); if(in == null) { GerConnectorDocument doc = GerConnectorDocument.Factory.newInstance(); DDBean[] list = root.getChildBean("connector"); if(list.length > 0) { connector = new ConnectorDCB(list[0], doc.addNewConnector()); } return doc; } else { try { GerConnectorDocument result = GerConnectorDocument.Factory.parse(in); in.close(); DDBean[] list = root.getChildBean("connector"); if(list.length > 0) { connector = new ConnectorDCB(list[0], result.getConnector()); } return result; } catch (XmlException e) { throw new RuntimeException("Unable to load default Geronimo RA data", e); } catch (IOException e) { throw new RuntimeException("Unable to load default Geronimo RA data", e); } } }
private XmlObject loadDefaultData(DDBeanRoot root) { InputStream in = root.getDeployableObject().getEntry("META-INF/geronimo-ra.xml"); if(in == null) { GerConnectorDocument doc = GerConnectorDocument.Factory.newInstance(); DDBean[] list = root.getChildBean("connector"); if(list.length > 0) { connector = new ConnectorDCB(list[0], doc.addNewConnector()); } return doc; } else { try { GerConnectorDocument result = GerConnectorDocument.Factory.parse(in); in.close(); DDBean[] list = root.getChildBean("connector"); if(list.length > 0) { connector = new ConnectorDCB(list[0], result.getConnector()); } return result; } catch (XmlException e) { throw new RuntimeException("Unable to load default Geronimo RA data", e); } catch (IOException e) { throw new RuntimeException("Unable to load default Geronimo RA data", e); } } }