Examples of resolveClassAnnotation()


Examples of org.jboss.ejb3.metadata.annotation.AnnotationRepositoryToMetaData.resolveClassAnnotation()

      List<MetaDataBridge<InterceptorMetaData>> interceptorBridges = new ArrayList<MetaDataBridge<InterceptorMetaData>>();
      interceptorBridges.add(new InterceptorMetaDataBridge());
      repository.addComponentMetaDataLoaderFactory(new InterceptorComponentMetaDataLoaderFactory(interceptorBridges));
      repository.addMetaDataBridge(new BeanInterceptorMetaDataBridge());
     
      Interceptors interceptors = (Interceptors) repository.resolveClassAnnotation(Interceptors.class);
      assertNotNull(interceptors);
      Class<?> expected[] = { DummyInterceptor.class };
      assertArrayEquals(expected, interceptors.value());
     
      Class<?> parameterTypes[] = { InvocationContext.class };
View Full Code Here

Examples of org.jboss.ejb3.metadata.annotation.AnnotationRepositoryToMetaData.resolveClassAnnotation()

      String canonicalObjectName = "Not important";
      ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
      AnnotationRepositoryToMetaData repository = new AnnotationRepositoryToMetaData(SecurityDomainBean.class, beanMetaData, canonicalObjectName, classLoader);
      repository.addMetaDataBridge(new SecurityDomainMetaDataBridge());
     
      SecurityDomain securityDomain = (SecurityDomain) repository.resolveClassAnnotation(SecurityDomain.class);
      assertNotNull(securityDomain);
      assertEquals("test", securityDomain.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.