Package org.jboss.managed.plugins

Examples of org.jboss.managed.plugins.ManagedDeploymentImpl


      assertEquals(1, mda.types().length);
      assertEquals("jms", mda.types()[0]);

      // Create a ManagedDeployment for the root MO
      Map<String, ManagedObject> unitMOs = Collections.singletonMap(JmsDestinations.class.getName(), mo);
      ManagedDeploymentImpl md = new ManagedDeploymentImpl("testManagementDeploymentMO",
            "testManagementDeploymentMO", DeploymentPhase.APPLICATION, null, unitMOs);
      // Create ManagedComponents for the destinations
      ManagedProperty destinationsMP = mo.getProperty("destinations");
      assertNotNull(destinationsMP);
      CollectionValue destinationsValue = (CollectionValue) destinationsMP.getValue();
      assertNotNull(destinationsValue);
      assertEquals(1, destinationsValue.getSize());
      GenericValue q1GV = (GenericValue) destinationsValue.getElements()[0];
      assertNotNull(q1GV);
      ManagedObject q1MO = (ManagedObject) q1GV.getValue();
      assertNotNull(q1MO);

      ComponentType type = new ComponentType("JMSDestination", "queue");
      RunStateMapper stateMapper = null;
      ManagedComponentImpl mc = new ManagedComponentImpl(type, md, q1MO, stateMapper);
      md.addComponent(q1MO.getName(), mc);

      RunState state = mc.getRunState();
      assertEquals(RunState.RUNNING, state);
   }
View Full Code Here


         types = mdAnnotation.types();
      }
      if( phase == null )
         phase = DeploymentPhase.APPLICATION;
     
      ManagedDeployment md = new ManagedDeploymentImpl(unit.getName(), simpleName, phase, parent, validUnitMOs);
      if(types.length > 0)
      {
         for(String type : types)
            addType(md, type);
      }
View Full Code Here

/*    */   public ManagedDeployment build(DeploymentUnit unit, Map<String, ManagedObject> unitMOs, ManagedDeployment parent)
/*    */   {
/* 46 */     ManagedDeployment.DeploymentPhase phase = (ManagedDeployment.DeploymentPhase)unit.getAttachment(ManagedDeployment.DeploymentPhase.class);
/* 47 */     if (phase == null)
/* 48 */       phase = ManagedDeployment.DeploymentPhase.APPLICATION;
/* 49 */     ManagedDeployment md = new ManagedDeploymentImpl(unit.getName(), unit.getSimpleName(), phase, parent, unitMOs);
/*    */
/* 52 */     return md;
/*    */   }
View Full Code Here

TOP

Related Classes of org.jboss.managed.plugins.ManagedDeploymentImpl

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.