final List<ComponentDescription> componentDescs = describedClass.getDescriptions(ComponentDescription.class); ComponentDescription found = null; if (!componentDescs.isEmpty()) {
/** * Get the first description of that type * @param descType The description class * @return THe first description or <code>null</code> */ public <T extends AbstractDescription> T getDescription(final Class<T> descType) { final List<T> result = this.getDescriptions(descType); if ( result.size() > 0 ) { return result.get(0); } return null; }
if ( desc != null ) { this.allDescriptions.put(annotatedClass.getName(), desc); if ( desc.getDescriptions(ComponentDescription.class).size() > 0) { result.add(desc); log.debug("Found component description " + desc + " in " + annotatedClass.getName());
final List<ComponentDescription> componentDescs = describedClass.getDescriptions(ComponentDescription.class); ComponentDescription found = null; if (!componentDescs.isEmpty()) {
final List<PropertyDescription> existingProps = describedClass.getDescriptions(PropertyDescription.class); PropertyDescription found = null; for(final PropertyDescription current : existingProps) {
final ComponentContainer component, final MetatypeContainer ocd) { for(final PropertyDescription pd : current.getDescriptions(PropertyDescription.class)) {
for(final ReferenceDescription rd : current.getDescriptions(ReferenceDescription.class)) { if ( rd.getPolicyOption() != ReferencePolicyOption.RELUCTANT ) { component.getComponentDescription().setSpecVersion(SpecVersion.VERSION_1_2);
if (desc.getDescriptions(ComponentDescription.class).size() > 1) { iLog.addError("Class has more than one component definition." + " Check the annotations and merge the definitions to a single definition.",