/** * Read the deployment XML for the given resources. */ public static List<XmEbean> readByResourceList(List<Resource> resourceList){ try { List<XmEbean> mappings = new ArrayList<>(); for (Resource xmlMappingRes : resourceList) { try (InputStream is = new FileInputStream(xmlMappingRes.getLocationOnDisk())) { mappings.add(XmlMappingReader.read(is)); } } return mappings; } catch (IOException e) { throw new RuntimeException("Error reading ebean xml mapping", e); } } }
/** * Read the deployment XML for the given resources. */ public static List<XmEbean> readByResourceList(List<Resource> resourceList){ try { List<XmEbean> mappings = new ArrayList<>(); for (Resource xmlMappingRes : resourceList) { try (InputStream is = new FileInputStream(xmlMappingRes.getLocationOnDisk())) { mappings.add(XmlMappingReader.read(is)); } } return mappings; } catch (IOException e) { throw new RuntimeException("Error reading ebean xml mapping", e); } } }