@Init public void init() { // introspect the interface once contract = contractProcessor.introspect(DataSource.class, new DefaultIntrospectionContext()); }
@Init public void init() { // introspect the interface once contract = contractProcessor.introspect(DataSource.class, new DefaultIntrospectionContext()); }
private Service<ComponentType> createServiceDefinition(Class<?> serviceInterface, InjectingComponentType componentType, IntrospectionContext context) { ServiceContract contract = contractProcessor.introspect(serviceInterface, context, componentType); return new Service<>(contract.getInterfaceName(), contract); } }
@Init public void init() { // introspect the interface once contract = contractProcessor.introspect(ExecutorService.class, new DefaultIntrospectionContext()); }
@Init public void init() { // introspect the interface once contract = contractProcessor.introspect(DataSource.class, new DefaultIntrospectionContext()); }
@Init public void init() { // introspect the interface once contract = contractProcessor.introspect(DataSource.class, new DefaultIntrospectionContext()); }
public <T> JavaServiceContract introspect(Class<T> interfaze) throws Fabric3Exception { DefaultIntrospectionContext context = new DefaultIntrospectionContext(); JavaServiceContract contract = contractProcessor.introspect(interfaze, context); StringBuilder builder = new StringBuilder(); if (context.hasErrors()) { for (ValidationFailure failure : context.getErrors()) { builder.append(failure.getMessage()).append("\n"); } throw new Fabric3Exception(builder.toString()); } return contract; }
public PersistenceContextProcessor(@Reference JavaContractProcessor contractProcessor) { super(PersistenceContext.class); IntrospectionContext context = new DefaultIntrospectionContext(); factoryServiceContract = contractProcessor.introspect(EntityManager.class, context); assert !context.hasErrors(); // should not happen }
private Callback createDefinition(String name, Type type, Class<?> implClass, InjectingComponentType componentType, IntrospectionContext context) { TypeMapping typeMapping = context.getTypeMapping(implClass); Class<?> baseType = helper.getBaseType(type, typeMapping); ServiceContract contract = contractProcessor.introspect(baseType, implClass, context, componentType); return new Callback(name, contract); }
private void addService(Class<?> interfaze, Component<?> definition) throws ValidationDeploymentException { URI uri = ContributionResolver.getContribution(); DefaultIntrospectionContext context = new DefaultIntrospectionContext(uri, getClass().getClassLoader()); JavaServiceContract contract = contractProcessor.introspect(interfaze, context); Service<ComponentType> service = new Service<>(interfaze.getSimpleName(), contract); definition.getComponentType().add(service); checkErrors(context); }
public PersistenceUnitProcessor(@Reference JavaContractProcessor contractProcessor) { super(PersistenceUnit.class); IntrospectionContext context = new DefaultIntrospectionContext(); factoryServiceContract = contractProcessor.introspect(EntityManagerFactory.class, context); assert !context.hasErrors(); // should not happen }
private CallbackDefinition createDefinition(String name, Type type, Class<?> implClass, InjectingComponentType componentType, IntrospectionContext context) { TypeMapping typeMapping = context.getTypeMapping(implClass); Class<?> baseType = helper.getBaseType(type, typeMapping); ServiceContract contract = contractProcessor.introspect(baseType, implClass, context, componentType); return new CallbackDefinition(name, contract); }
public void visitType(Remotable annotation, Class<?> type, InjectingComponentType componentType, IntrospectionContext context) { ServiceContract serviceContract = contractProcessor.introspect(type, context, componentType); ServiceDefinition definition = new ServiceDefinition(serviceContract.getInterfaceName(), serviceContract); componentType.add(definition); } }
private void addService(Class<?> interfaze, Component<?> definition) throws ValidationDeploymentException { URI uri = ContributionResolver.getContribution(); DefaultIntrospectionContext context = new DefaultIntrospectionContext(uri, getClass().getClassLoader()); JavaServiceContract contract = contractProcessor.introspect(interfaze, context); Service<ComponentType> service = new Service<>(interfaze.getSimpleName(), contract); definition.getComponentType().add(service); checkErrors(context); }
public PersistenceContextProcessor(@Reference JavaContractProcessor contractProcessor, @Reference IntrospectionHelper helper) { super(PersistenceContext.class); this.helper = helper; IntrospectionContext context = new DefaultIntrospectionContext(); factoryServiceContract = contractProcessor.introspect(EntityManager.class, context); assert !context.hasErrors(); // should not happen }
public ChannelAnnotationProcessor(@Reference JavaContractProcessor contractProcessor, @Reference IntrospectionHelper helper) { super(Channel.class); this.helper = helper; IntrospectionContext context = new DefaultIntrospectionContext(); contextContract = contractProcessor.introspect(ChannelContext.class, context); assert !context.hasErrors(); // should not happen }
public ChannelAnnotationProcessor(@Reference JavaContractProcessor contractProcessor, @Reference IntrospectionHelper helper) { super(Channel.class); this.helper = helper; IntrospectionContext context = new DefaultIntrospectionContext(); contextContract = contractProcessor.introspect(ChannelContext.class, context); assert !context.hasErrors(); // should not happen }
public PersistenceContextProcessor(@Reference JavaContractProcessor contractProcessor, @Reference IntrospectionHelper helper) { super(PersistenceContext.class); this.helper = helper; IntrospectionContext context = new DefaultIntrospectionContext(); factoryServiceContract = contractProcessor.introspect(EntityManager.class, context); assert !context.hasErrors(); // should not happen }
public PersistenceContextProcessor(@Reference JavaContractProcessor contractProcessor, @Reference IntrospectionHelper helper) { super(PersistenceContext.class); this.helper = helper; IntrospectionContext context = new DefaultIntrospectionContext(); factoryServiceContract = contractProcessor.introspect(EntityManager.class, context); assert !context.hasErrors(); // should not happen }
public JpaImplementationLoader(@Reference JavaImplementationProcessor implementationProcessor, @Reference JavaContractProcessor contractProcessor) { this.implementationProcessor = implementationProcessor; IntrospectionContext context = new DefaultIntrospectionContext(); factoryServiceContract = contractProcessor.introspect(EntityManager.class, context); assert !context.hasErrors(); // should not happen }