/** * @param annotation * @param store * @return a new qualifier instance for the given annotation */ public static QualifierInstance of(Annotation annotation, MetaAnnotationStore store) { Class<? extends Annotation> annotationType = annotation.annotationType(); if (Any.class == annotationType) { return ANY; } else if (Default.class == annotationType) { return DEFAULT; } else if (Named.class == annotationType) { Named named = (Named) annotation; return new QualifierInstance(annotationType, ImmutableMap.of("value", named.value())); } else { return new QualifierInstance(annotationType, createValues(annotation, store)); } }
/** * @param annotation * @param store * @return a new qualifier instance for the given annotation */ public static QualifierInstance of(Annotation annotation, MetaAnnotationStore store) { Class<? extends Annotation> annotationType = annotation.annotationType(); if (Any.class == annotationType) { return ANY; } else if (Default.class == annotationType) { return DEFAULT; } else if (Named.class == annotationType) { Named named = (Named) annotation; return new QualifierInstance(annotationType, ImmutableMap.of("value", named.value())); } else { return new QualifierInstance(annotationType, createValues(annotation, store)); } }
/** * @param annotation * @param store * @return a new qualifier instance for the given annotation */ public static QualifierInstance of(Annotation annotation, MetaAnnotationStore store) { Class<? extends Annotation> annotationType = annotation.annotationType(); if (Any.class == annotationType) { return ANY; } else if (Default.class == annotationType) { return DEFAULT; } else if (Named.class == annotationType) { Named named = (Named) annotation; return new QualifierInstance(annotationType, ImmutableMap.<String, Object>of("value", named.value())); } else { return new QualifierInstance(annotationType, createValues(annotation, store)); } }
/** * @param annotation * @param store * @return a new qualifier instance for the given annotation */ public static QualifierInstance of(Annotation annotation, MetaAnnotationStore store) { Class<? extends Annotation> annotationType = annotation.annotationType(); if (Any.class == annotationType) { return ANY; } else if (Default.class == annotationType) { return DEFAULT; } else if (Named.class == annotationType) { Named named = (Named) annotation; return new QualifierInstance(annotationType, ImmutableMap.of("value", named.value())); } else { return new QualifierInstance(annotationType, createValues(annotation, store)); } }
/** * @param annotation * @param store * @return a new qualifier instance for the given annotation */ public static QualifierInstance of(Annotation annotation, MetaAnnotationStore store) { Class<? extends Annotation> annotationType = annotation.annotationType(); if (Any.class == annotationType) { return ANY; } else if (Default.class == annotationType) { return DEFAULT; } else if (Named.class == annotationType) { Named named = (Named) annotation; return new QualifierInstance(annotationType, ImmutableMap.of("value", named.value())); } else { return new QualifierInstance(annotationType, createValues(annotation, store)); } }
/** * @param annotation * @param store * @return a new qualifier instance for the given annotation */ public static QualifierInstance of(Annotation annotation, MetaAnnotationStore store) { Class<? extends Annotation> annotationType = annotation.annotationType(); if (Any.class == annotationType) { return ANY; } else if (Default.class == annotationType) { return DEFAULT; } else if (Named.class == annotationType) { Named named = (Named) annotation; return new QualifierInstance(annotationType, ImmutableMap.of("value", named.value())); } else { return new QualifierInstance(annotationType, createValues(annotation, store)); } }