private UnifiedVirtualFile getWebservicesFile(DeploymentUnit unit) { VirtualFile vf = ((VFSDeploymentUnit)unit).getMetaDataFile("webservices.xml"); return (vf != null ? new VirtualFileAdaptor(vf) : null); } }
private UnifiedVirtualFile getWebservicesFile(DeploymentUnit unit) { UnifiedVirtualFile wsFile = null; if (unit instanceof VFSDeploymentUnit) { VirtualFile vf = ((VFSDeploymentUnit)unit).getMetaDataFile("webservices.xml"); wsFile = vf != null ? new VirtualFileAdaptor(vf) : null; } return wsFile; } }
private UnifiedVirtualFile getWebservicesFile(DeploymentUnit unit) { UnifiedVirtualFile wsFile = null; if (unit instanceof VFSDeploymentUnit) { VirtualFile vf = ((VFSDeploymentUnit)unit).getMetaDataFile("webservices.xml"); wsFile = vf != null ? new VirtualFileAdaptor(vf) : null; } return wsFile; } }
private UnifiedVirtualFile getWebservicesFile(DeploymentUnit unit) { UnifiedVirtualFile wsFile = null; if (unit instanceof VFSDeploymentUnit) { VirtualFile vf = ((VFSDeploymentUnit)unit).getMetaDataFile("webservices.xml"); wsFile = vf != null ? new VirtualFileAdaptor(vf) : null; } return wsFile; } }
private UnifiedVirtualFile getWebservicesFile(DeploymentUnit unit) { UnifiedVirtualFile wsFile = null; if (unit instanceof VFSDeploymentUnit) { VirtualFile vf = ((VFSDeploymentUnit)unit).getMetaDataFile("webservices.xml"); wsFile = vf != null ? new VirtualFileAdaptor(vf) : null; } return wsFile; } }
public UnifiedVirtualFile findChild(String child) throws IOException { VirtualFile vf = root; while (child.startsWith("./")) { child = child.substring(2); } while (child.startsWith("../")) { child = child.substring(3); vf = vf.getParent(); } vf = vf.findChild(child); return new VirtualFileAdaptor(vf); }
public List<UnifiedVirtualFile> getChildren() throws IOException { List<VirtualFile> vfList = getFile().getChildren(); if (vfList == null) return null; List<UnifiedVirtualFile> uvfList = new LinkedList<UnifiedVirtualFile>(); for (VirtualFile vf : vfList) { uvfList.add(new VirtualFileAdaptor(vf)); } return uvfList; }
@SuppressWarnings("deprecation") public UnifiedVirtualFile findChild(String child) throws IOException { VirtualFile vf = getFile().findChild(child); return new VirtualFileAdaptor(vf); }
private void linkServiceRefs(DeploymentUnit unit, ServiceReferencesMetaData serviceRefs, Context envCtx) throws NamingException { if (unit instanceof VFSDeploymentUnit) { VFSDeploymentUnit vfsUnit = (VFSDeploymentUnit)unit; ClassLoader loader = unit.getClassLoader(); UnifiedVirtualFile vfsRoot = new VirtualFileAdaptor(vfsUnit.getRoot()); for (ServiceReferenceMetaData sref : serviceRefs) { String refName = sref.getServiceRefName(); new ServiceReferenceHandler().bindServiceRef(envCtx, refName, vfsRoot, loader, sref); } } }
@Override public Deployment createDeployment(DeploymentUnit unit) { ArchiveDeployment dep = newDeployment(unit); dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot())); dep.setRuntimeClassLoader(unit.getClassLoader()); dep.setType(getDeploymentType()); Service service = dep.getService(); Ejb3Deployment ejb3Deployment = unit.getAttachment(Ejb3Deployment.class); if (ejb3Deployment == null) throw new IllegalStateException("Deployment unit does not contain ejb3 deployment"); // Copy the attachments dep.addAttachment(Ejb3Deployment.class, ejb3Deployment); Iterator it = ejb3Deployment.getEjbContainers().values().iterator(); while (it.hasNext()) { EJBContainer container = (EJBContainer)it.next(); if (isWebServiceBean(container)) { String ejbName = container.getEjbName(); String epBean = container.getBeanClassName(); // Create the endpoint Endpoint ep = newEndpoint(epBean); ep.setShortName(ejbName); service.addEndpoint(ep); } } return dep; }
dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot())); dep.setRuntimeClassLoader(unit.getClassLoader()); dep.setType(getDeploymentType());
dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot())); dep.setRuntimeClassLoader(unit.getClassLoader()); dep.setType(getDeploymentType());
dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot())); dep.setRuntimeClassLoader(unit.getClassLoader()); dep.setType(getDeploymentType());
dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot())); dep.setRuntimeClassLoader(unit.getClassLoader()); dep.setType(getDeploymentType());
@Override public Deployment createDeployment(DeploymentUnit unit) { ArchiveDeployment dep = newDeployment(unit); dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot())); dep.setType(getDeploymentType()); Service service = dep.getService(); JBossWebMetaData webMetaData = unit.getAttachment(JBossWebMetaData.class); if (webMetaData == null) throw new IllegalStateException("Deployment unit does not contain web meta data"); // Copy the attachments dep.addAttachment(JBossWebMetaData.class, webMetaData); List<ServletMetaData> servlets = getRelevantServlets(webMetaData, unit.getClassLoader()); for (ServletMetaData servlet : servlets) { String servletName = servlet.getName(); String targetBean = getTargetBean(servlet); // Create the endpoint Endpoint ep = newEndpoint(targetBean); ep.setShortName(servletName); service.addEndpoint(ep); } return dep; }
@Override public Deployment createDeployment(DeploymentUnit unit) { ArchiveDeployment dep = newDeployment(unit); dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot())); dep.setType(getDeploymentType()); Service service = dep.getService(); JBossWebMetaData webMetaData = unit.getAttachment(JBossWebMetaData.class); if (webMetaData == null) throw new IllegalStateException("Deployment unit does not contain web meta data"); // Copy the attachments dep.addAttachment(JBossWebMetaData.class, webMetaData); List<ServletMetaData> servlets = getRelevantServlets(webMetaData, unit.getClassLoader()); for (ServletMetaData servlet : servlets) { String servletName = servlet.getName(); String targetBean = getTargetBean(servlet); // Create the endpoint Endpoint ep = newEndpoint(targetBean); ep.setShortName(servletName); service.addEndpoint(ep); } return dep; }
@Override public Deployment createDeployment(DeploymentUnit unit) { ArchiveDeployment dep = newDeployment(unit); dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot())); dep.setType(getDeploymentType()); Service service = dep.getService(); JBossWebMetaData webMetaData = unit.getAttachment(JBossWebMetaData.class); if (webMetaData == null) throw new IllegalStateException("Deployment unit does not contain web meta data"); // Copy the attachments dep.addAttachment(JBossWebMetaData.class, webMetaData); List<ServletMetaData> servlets = getRelevantServlets(webMetaData, unit.getClassLoader()); for (ServletMetaData servlet : servlets) { String servletName = servlet.getName(); String targetBean = getTargetBean(servlet); // Create the endpoint Endpoint ep = newEndpoint(targetBean); ep.setShortName(servletName); service.addEndpoint(ep); } return dep; }
@Override public Deployment createDeployment(DeploymentUnit unit) { ArchiveDeployment dep = newDeployment(unit); dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot())); dep.setType(getDeploymentType()); Service service = dep.getService(); JBossWebMetaData webMetaData = unit.getAttachment(JBossWebMetaData.class); if (webMetaData == null) throw new IllegalStateException("Deployment unit does not contain web meta data"); // Copy the attachments dep.addAttachment(JBossWebMetaData.class, webMetaData); List<ServletMetaData> servlets = getRelevantServlets(webMetaData, unit.getClassLoader()); for (ServletMetaData servlet : servlets) { String servletName = servlet.getName(); String targetBean = getTargetBean(servlet); // Create the endpoint Endpoint ep = newEndpoint(targetBean); ep.setShortName(servletName); service.addEndpoint(ep); } return dep; }
@Override public Deployment createDeployment(DeploymentUnit unit) { ArchiveDeployment dep = newDeployment(unit); dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit)unit).getRoot())); dep.setType(getDeploymentType()); Service service = dep.getService(); JBossWebMetaData webMetaData = unit.getAttachment(JBossWebMetaData.class); if (webMetaData == null) throw new IllegalStateException("Deployment unit does not contain web meta data"); // Copy the attachments dep.addAttachment(JBossWebMetaData.class, webMetaData); List<ServletMetaData> servlets = getRelevantServlets(webMetaData, unit.getClassLoader()); for (ServletMetaData servlet : servlets) { String servletName = servlet.getName(); String targetBean = getTargetBean(servlet); // Create the endpoint Endpoint ep = newEndpoint(targetBean); ep.setShortName(servletName); service.addEndpoint(ep); } return dep; }
dep.setRootFile(new VirtualFileAdaptor(((VFSDeploymentUnit) unit).getRoot()));