Package org.jboss.kernel.plugins.validation.basic

Examples of org.jboss.kernel.plugins.validation.basic.BasicKernelBeanValidator$DisabledFlagReader


   public void testBVBLookup() throws Throwable
   {
      Kernel kernel = bootstrap();
      KernelController controller = kernel.getController();
      KernelBeanValidator validator = kernel.getValidator();
      BasicKernelBeanValidator bkbv = assertInstanceOf(validator, BasicKernelBeanValidator.class);
      bkbv.setDisabled(false);

      try
      {
         MockBeanValidatorBridge bridge = new MockBeanValidatorBridge();
         controller.install(new AbstractBeanMetaData("bvb", MockBeanValidatorBridge.class.getName()), bridge);

         BeanMetaDataBuilder builder = BeanMetaDataBuilder.createBuilder("tester", BVBTester.class.getName());
         builder.addPropertyMetaData("something", 123);
         builder.addInstall("invokeSomething", Object.class.getName(), "123");
         controller.install(builder.getBeanMetaData());

         assertNotNull(bridge.getJoinpoint());
         assertInstanceOf(bridge.getTarget(), BVBTester.class);
         assertEquals("something", bridge.getProperty());
         assertEquals("invokeSomething", bridge.getMethod());
      }
      finally
      {
         bkbv.setDisabled(true);
      }
   }
View Full Code Here

TOP

Related Classes of org.jboss.kernel.plugins.validation.basic.BasicKernelBeanValidator$DisabledFlagReader

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.