Package org.jboss.metatype.api.values

Examples of org.jboss.metatype.api.values.CompositeValueSupport.containsKey()


         return operationResult;
      }
      else if (val instanceof CompositeValueSupport)
      {
         CompositeValueSupport valueSupport = (CompositeValueSupport) val;
         if (valueSupport.containsKey("cause"))
         {
            CompositeValueSupport cause = (CompositeValueSupport) valueSupport.get("cause");
            SimpleValueSupport message = (SimpleValueSupport) cause.get("message");
            Exception exception = new Exception(message.toString());
            throw exception;
View Full Code Here


   public void testContainsKey() throws Exception
   {
      CompositeMetaType compositeMetaType = initCompositeMetaType();
      Map<String, MetaValue> map = initMapValues();
      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
      assertTrue("data should contain key name1", v.containsKey("name1"));
      assertTrue("data should contain key name2", v.containsKey("name2"));
      assertFalse("data should not contain key nameX", v.containsKey("nameX"));
      assertFalse("data should not contain key null", v.containsKey(null));
      assertFalse("data should not contain key <empty>", v.containsKey(""));
   }
View Full Code Here

   {
      CompositeMetaType compositeMetaType = initCompositeMetaType();
      Map<String, MetaValue> map = initMapValues();
      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
      assertTrue("data should contain key name1", v.containsKey("name1"));
      assertTrue("data should contain key name2", v.containsKey("name2"));
      assertFalse("data should not contain key nameX", v.containsKey("nameX"));
      assertFalse("data should not contain key null", v.containsKey(null));
      assertFalse("data should not contain key <empty>", v.containsKey(""));
   }
View Full Code Here

      CompositeMetaType compositeMetaType = initCompositeMetaType();
      Map<String, MetaValue> map = initMapValues();
      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
      assertTrue("data should contain key name1", v.containsKey("name1"));
      assertTrue("data should contain key name2", v.containsKey("name2"));
      assertFalse("data should not contain key nameX", v.containsKey("nameX"));
      assertFalse("data should not contain key null", v.containsKey(null));
      assertFalse("data should not contain key <empty>", v.containsKey(""));
   }

   /**
 
View Full Code Here

      Map<String, MetaValue> map = initMapValues();
      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
      assertTrue("data should contain key name1", v.containsKey("name1"));
      assertTrue("data should contain key name2", v.containsKey("name2"));
      assertFalse("data should not contain key nameX", v.containsKey("nameX"));
      assertFalse("data should not contain key null", v.containsKey(null));
      assertFalse("data should not contain key <empty>", v.containsKey(""));
   }

   /**
    * Test the containsValue for a composite value
View Full Code Here

      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
      assertTrue("data should contain key name1", v.containsKey("name1"));
      assertTrue("data should contain key name2", v.containsKey("name2"));
      assertFalse("data should not contain key nameX", v.containsKey("nameX"));
      assertFalse("data should not contain key null", v.containsKey(null));
      assertFalse("data should not contain key <empty>", v.containsKey(""));
   }

   /**
    * Test the containsValue for a composite value
    *
 
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.