Package org.apache.geronimo.jee.web

Examples of org.apache.geronimo.jee.web.WebApp


        Trace.tracePoint("Enter", "DependencyHelper.getEnvironment", module);

        Environment environment = null;
        if (GeronimoUtils.isWebModule(module)) {
            if (getWebDeploymentPlan(module) != null) {
                WebApp plan = getWebDeploymentPlan(module).getValue();
                if (plan != null)
                    environment = plan.getEnvironment();
            }
        }
        else if (GeronimoUtils.isEjbJarModule(module)) {
            if (getOpenEjbDeploymentPlan(module) != null) {
                OpenejbJar plan = getOpenEjbDeploymentPlan(module).getValue();
                if (plan != null)
                    environment = plan.getEnvironment();
            }
        }
        else if (GeronimoUtils.isEarModule(module)) {
            if (getApplicationDeploymentPlan(module) != null) {
                Application plan = getApplicationDeploymentPlan(module).getValue();
                if (plan != null)
                    environment = plan.getEnvironment();
            }
        }
        else if (GeronimoUtils.isRARModule(module)) {
            if (getConnectorDeploymentPlan(module) != null) {
                Connector plan = getConnectorDeploymentPlan(module).getValue();
                if (plan != null)
                    environment = plan.getEnvironment();
            }
        }else if (GeronimoUtils.isAppClientModule(module)) {
            if (getAppClientDeploymentPlan(module) != null) {
                ApplicationClient plan = getAppClientDeploymentPlan(module).getValue();
                if (plan != null)
                    environment = plan.getServerEnvironment();
            }
        }

        Trace.tracePoint("Exit ", "DependencyHelper.getEnvironment", environment);
        return environment;
View Full Code Here


     *
     * @see org.apache.geronimo.ui.pages.AbstractGeronimoFormPage#fillBody(org.eclipse.ui.forms.IManagedForm)
     */
    protected void fillBody(IManagedForm managedForm) {
        if (WebApp.class.isInstance (getDeploymentPlan().getValue())) {
            WebApp webapp = (WebApp)((AbstractGeronimoDeploymentPlanEditor) getEditor()).getDeploymentPlan().getValue();
            managedForm.addPart(new EjbRefSection(getDeploymentPlan(), body, toolkit, getStyle(), webapp.getEjbRef()));
            managedForm.addPart(new ResourceRefSection(getDeploymentPlan(), body, toolkit, getStyle(), webapp.getResourceRef()));
            managedForm.addPart(new ServiceRefSection(getDeploymentPlan(), body, toolkit, getStyle(), webapp.getServiceRef()));
            managedForm.addPart(new ResourceEnvRefSection(getDeploymentPlan(), body, toolkit, getStyle(), webapp.getResourceEnvRef()));
            managedForm.addPart(new EjbLocalRefSection(getDeploymentPlan(), body, toolkit, getStyle(), webapp.getEjbLocalRef()));
            managedForm.addPart(new GBeanRefSection(getDeploymentPlan(), body, toolkit, getStyle(), webapp.getAbstractNamingEntry()));
            managedForm.addPart(new PersContextRefSection(getDeploymentPlan(), body, toolkit, getStyle(), webapp.getAbstractNamingEntry()));
            managedForm.addPart(new PersUnitRefSection(getDeploymentPlan(), body, toolkit, getStyle(), webapp.getAbstractNamingEntry()));
            managedForm.addPart(new MessageDestSection(getDeploymentPlan(), body, toolkit, getStyle(), webapp.getMessageDestination()));
        }
        else if (ApplicationClient.class.isInstance (getDeploymentPlan().getValue())){
            ApplicationClient appClient = (ApplicationClient)((AbstractGeronimoDeploymentPlanEditor) getEditor()).getDeploymentPlan().getValue();
            managedForm.addPart(new EjbRefSection(getDeploymentPlan(), body, toolkit, getStyle(), appClient.getEjbRef()));
            managedForm.addPart(new ResourceRefSection(getDeploymentPlan(), body, toolkit, getStyle(), appClient.getResourceRef()));
View Full Code Here

            Security security = (Security)source;
            if (security.getRoleMappings() != null && security.getRoleMappings().getRole().size() == 0) {
                security.setRoleMappings(null);
            }
        } else if (source instanceof WebApp) {
            WebApp webapp = (WebApp)source;
            GbeanLocator gbeanlocator = webapp.getWebContainer();
            if (gbeanlocator != null && isEmpty(gbeanlocator.getGbeanLink()) && isEmpty(gbeanlocator.getPattern())) {
                webapp.setWebContainer(null);
            }
        } else if (source instanceof OpenejbJar) {
            OpenejbJar openejb = (OpenejbJar)source;
            ResourceLocator locator = openejb.getCmpConnectionFactory();
            if (locator != null && isEmpty(locator.getResourceLink()) && isEmpty(locator.getUrl()) && isEmpty(locator.getPattern())) {
View Full Code Here

  public JAXBElement createGeronimoWebDeploymentPlan(IFile dpFile) throws Exception {
      Trace.tracePoint("Entry", "V21DeploymentPlanCreationOperation.createGeronimoWebDeploymentPlan",
        dpFile, dpFile.getFullPath());

    org.apache.geronimo.jee.web.ObjectFactory webFactory = new org.apache.geronimo.jee.web.ObjectFactory();
    WebApp web = webFactory.createWebApp();

    web.setContextRoot("/" + getProject().getName());
    web.setEnvironment(getConfigEnvironment());

    JAXBElement jaxbElement = webFactory.createWebApp(web);
    JAXBUtils.marshalDeploymentPlan(jaxbElement, dpFile);

    Trace.tracePoint("Exit ", "V21DeploymentPlanCreationOperation.createGeronimoWebDeploymentPlan", jaxbElement);
View Full Code Here

        Trace.tracePoint("ENTRY", "GeronimoV21Utils.getConfigId", module);

        Environment environment = null;
        if (isWebModule(module)) {
            if (getWebDeploymentPlan(module)!=null) {
              WebApp plan = getWebDeploymentPlan(module).getValue();
              if (plan != null)
                environment = plan.getEnvironment();
            }
        }
        else if (isEjbJarModule(module)) {
             if (getOpenEjbDeploymentPlan(module)!=null) {
                OpenejbJar plan = getOpenEjbDeploymentPlan(module).getValue();
                if (plan != null)
                  environment = plan.getEnvironment();
             }
        }
        else if (isEarModule(module)) {
          if (getApplicationDeploymentPlan(module)!=null) {
            Application plan = getApplicationDeploymentPlan(module).getValue();
            if (plan != null)
              environment = plan.getEnvironment();
          }
        }
        else if (isRARModule(module)) {
          if (getConnectorDeploymentPlan(module)!=null) {
              Connector plan = getConnectorDeploymentPlan(module).getValue();
              if (plan != null)
                  environment = plan.getEnvironment();
          }
        }

        if (environment != null
            && environment.getModuleId() != null) {
View Full Code Here

    //}

    public static String getContextRoot(IModule module) throws Exception {
        String contextRoot = null;

        WebApp deploymentPlan = getWebDeploymentPlan(module).getValue();
        if (deploymentPlan != null)
            contextRoot = deploymentPlan.getContextRoot();

        if (contextRoot == null)
            contextRoot = GeronimoUtils.getContextRoot(module);

        return contextRoot;
View Full Code Here

      // add the gbean into plan
      JAXBElement<Gbean> gbeanElement = objectFactory.createGbean(gbean);
      application.getService().add(gbeanElement);
  } else if (WebApp.class.isInstance(planValue)) {
      WebApp webapp = (WebApp) planValue;

      // set dependency
      Environment env = webapp.getEnvironment();
      if (env == null) {
    env = new Environment();
    webapp.setEnvironment(env);
      }
      setDependency(env);

      // add the gbean into plan
      JAXBElement<Gbean> gbeanElement = objectFactory.createGbean(gbean);
      webapp.getServiceOrPersistence().add(gbeanElement);
  } else if (OpenejbJar.class.isInstance(planValue)) {
      OpenejbJar openejbJar = (OpenejbJar) planValue;

      // set dependency
      Environment env = openejbJar.getEnvironment();
View Full Code Here

TOP

Related Classes of org.apache.geronimo.jee.web.WebApp

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.