Package org.jboss.metatype.api.values

Examples of org.jboss.metatype.api.values.SimpleValueSupport


  
   protected CompositeValue createCompositeValue(Boolean read, Boolean write, Boolean create)
   {
      Map<String, MetaValue> map = new HashMap<String, MetaValue>();
     
      map.put("read", new SimpleValueSupport(SimpleMetaType.BOOLEAN, read));
      map.put("write", new SimpleValueSupport(SimpleMetaType.BOOLEAN, write));
      map.put("create", new SimpleValueSupport(SimpleMetaType.BOOLEAN, create));
     
      return new CompositeValueSupport(composite, map);
   }
View Full Code Here


      MetaValue integer = nested.get("integer");
      assertNotNull(integer);

      // Change values
      Map<String, MetaValue> changedMap = new HashMap<String, MetaValue>();
      changedMap.put("name", new SimpleValueSupport(
            (SimpleMetaType) name.getMetaType(), "newName"));
      changedMap.put("integer", new SimpleValueSupport(
            (SimpleMetaType) integer.getMetaType(), 111));
     
      // Set new values
      p.setValue(
            new CompositeValueSupport(nested.getMetaType(), changedMap)
View Full Code Here

      assertNotNull(p);
     
      ArrayValue a = (ArrayValue) p.getValue();
      assertNotNull(a);
     
      SimpleValueSupport svs = (SimpleValueSupport) a.getValue(1);
      assertNotNull(svs);
      svs.setValue('H');
     
      PersistedManagedObject restored = restore(mo);
      assertNotNull(restored);
     
      //
View Full Code Here

      Boolean value = null;
      if(element.getAttributeNode(attributeName) != null)
      {
         value = Boolean.valueOf(element.getAttribute(attributeName));
      }
      return new SimpleValueSupport(SimpleMetaType.BOOLEAN, value);
   }
View Full Code Here

  
   protected CompositeValue createCompositeValue(Boolean read, Boolean write, Boolean create)
   {
      Map<String, MetaValue> map = new HashMap<String, MetaValue>();

      map.put("read", new SimpleValueSupport(SimpleMetaType.BOOLEAN, read));
      map.put("write", new SimpleValueSupport(SimpleMetaType.BOOLEAN, write));
      map.put("create", new SimpleValueSupport(SimpleMetaType.BOOLEAN, create));

      return new CompositeValueSupport(compositeMetaType, map);
   }
View Full Code Here

      assertNotNull(configProperty);
      MetaValue value = configProperty.getValue();
      assertTrue("MapCompositeMetaType", value.getMetaType() instanceof MapCompositeMetaType);
     
      MapCompositeValueSupport cValue = (MapCompositeValueSupport) value;
      cValue.put("testKey", new SimpleValueSupport(SimpleMetaType.STRING, "testValue"));
     
      mgtView.updateComponent(dsMC);

      mgtView = getManagementView();
      dsMC = getManagedComponent(mgtView, compType, jndiName);
View Full Code Here

   protected CompositeValue createCompositeValue(Boolean read, Boolean write, Boolean create)
   {
      Map<String, MetaValue> map = new HashMap<String, MetaValue>();
     
      map.put("read", new SimpleValueSupport(SimpleMetaType.BOOLEAN, read));
      map.put("write", new SimpleValueSupport(SimpleMetaType.BOOLEAN, write));
      map.put("create", new SimpleValueSupport(SimpleMetaType.BOOLEAN, create));
     
      return new CompositeValueSupport(composite, map);
   }
View Full Code Here

  
   protected CompositeValue createCompositeValue(Boolean read, Boolean write, Boolean create)
   {
      Map<String, MetaValue> map = new HashMap<String, MetaValue>();
     
      map.put("read", new SimpleValueSupport(SimpleMetaType.BOOLEAN, read));
      map.put("write", new SimpleValueSupport(SimpleMetaType.BOOLEAN, write));
      map.put("create", new SimpleValueSupport(SimpleMetaType.BOOLEAN, create));
     
      return new CompositeValueSupport(composite, map);
   }
View Full Code Here

      createRoles(configurationUpdateReport, name, sendRoles, consumeRoles, createNonDurableRoles, deleteNonDurableRoles, createDurableRoles, deleteDurableRoles);
      try
      {
         ManagedOperation operation = ManagementSupport.getOperation(view, JMSConstants.Topic.COMPONENT_NAME,
               "updateTopicConfiguration", JMSConstants.Topic.COMPONENT_TYPE);
         operation.invoke(new SimpleValueSupport(SimpleMetaType.STRING, resourceContext.getResourceKey()),
             new SimpleValueSupport(SimpleMetaType.STRING, jndiName),
             new SimpleValueSupport(SimpleMetaType.STRING, DLA),
             new SimpleValueSupport(SimpleMetaType.STRING, expiryAddress),
             new SimpleValueSupport(SimpleMetaType.INTEGER_PRIMITIVE, maxSize),
             new SimpleValueSupport(SimpleMetaType.INTEGER_PRIMITIVE, pageSize),
             new SimpleValueSupport(SimpleMetaType.INTEGER_PRIMITIVE, pageMaxCacheSize),
             new SimpleValueSupport(SimpleMetaType.INTEGER_PRIMITIVE, maxDeliveryAttempts),
             new SimpleValueSupport(SimpleMetaType.LONG_PRIMITIVE, redeliveryDelay),
             new SimpleValueSupport(SimpleMetaType.BOOLEAN_PRIMITIVE, lastValueQueue),
             new SimpleValueSupport(SimpleMetaType.LONG_PRIMITIVE, redistributionDelay),
             new SimpleValueSupport(SimpleMetaType.BOOLEAN_PRIMITIVE, sendToDLAOnNoRoute),
             new SimpleValueSupport(SimpleMetaType.STRING, addressFullMessagePolicy),
             new SimpleValueSupport(SimpleMetaType.STRING, sendRoles.toString()),
             new SimpleValueSupport(SimpleMetaType.STRING, consumeRoles.toString()),
             new SimpleValueSupport(SimpleMetaType.STRING, createDurableRoles.toString()),
             new SimpleValueSupport(SimpleMetaType.STRING, deleteDurableRoles.toString()),
             new SimpleValueSupport(SimpleMetaType.STRING, createNonDurableRoles.toString()),
             new SimpleValueSupport(SimpleMetaType.STRING, deleteNonDurableRoles.toString()));
      }
      catch (Exception e)
      {
         configurationUpdateReport.setStatus(ConfigurationUpdateStatus.FAILURE);
         configurationUpdateReport.setErrorMessage(e.getMessage());
View Full Code Here

      ArrayValueSupport value = (ArrayValueSupport) operation.invoke();

      for (int i = 0; i < value.getLength(); i++)
      {
         SimpleValueSupport queue = (SimpleValueSupport) value.getValue(i);
         ResourceType resourceType = resourceDiscoveryContext.getResourceType();
         String queueName = "jms.queue." + queue.getValue();
         set.add(new DiscoveredResourceDetails(resourceType,
             queueName,
             queueName,
             "a JMS Queue",
             "",
View Full Code Here

TOP

Related Classes of org.jboss.metatype.api.values.SimpleValueSupport

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.