protected boolean shouldConfigure( ComponentDescriptor<T> descriptor ) { String configuratorId = descriptor.getComponentConfigurator(); if (StringUtils.isEmpty(configuratorId)) { return true; } try { ComponentConfigurator componentConfigurator = getContainer().lookup(ComponentConfigurator.class, configuratorId); return componentConfigurator == null || componentConfigurator.getClass().equals(BasicComponentConfigurator.class); } catch (ComponentLookupException e) { } return true; } protected String fromXML(String elementName) {
} else { String roleHint = requirement.getRoleHint(); assignment = container.lookup(propertyType, role, roleHint);
protected T lookup( ComponentDescriptor<T> componentDescriptor ) { T component = null; try { if ( componentDescriptor != null ) { component = container.lookup( componentDescriptor ); } } catch ( ComponentLookupException e ) { logger.debug( "Failed to lookup a member of active collection with role: " + role + " and role-hint: " + componentDescriptor.getRoleHint(), e ); } return component; }
value = container.lookup(role, hint); } else if ("single".equals(mappingType)) { value = container.lookup(role, hint); } else if ("map".equals(mappingType)) { value = container.lookupMap(role); value = new HashSet<Object>(cast(container.lookupList(role))); } else { value = container.lookup(role, hint);
ComponentConfigurator componentConfigurator = manager.getContainer().lookup( ComponentConfigurator.class, configuratorId );
protected boolean shouldConfigure(ComponentDescriptor descriptor, ClassRealm realm) { String configuratorId = descriptor.getComponentConfigurator(); if (StringUtils.isEmpty(configuratorId)) { return true; } try { ComponentConfigurator componentConfigurator = (ComponentConfigurator) getContainer().lookup(ComponentConfigurator.ROLE, configuratorId, realm); return componentConfigurator == null || componentConfigurator.getClass().equals(BasicComponentConfigurator.class); } catch (ComponentLookupException e) { } return true; } protected String fromXML(String elementName) {
ComponentConfigurator componentConfigurator = (ComponentConfigurator) manager.getContainer().lookup( ComponentConfigurator.ROLE, configuratorId, realm );
ComponentConfigurator componentConfigurator = (ComponentConfigurator) manager.getContainer().lookup( ComponentConfigurator.ROLE, configuratorId, lookupRealm );