Search in sources :

Example 1 with AbstractServiceInterface

use of org.opendaylight.controller.config.api.annotations.AbstractServiceInterface in project controller by opendaylight.

the class InterfacesHelper method getServiceInterfaceAnnotations.

private static Set<ServiceInterfaceAnnotation> getServiceInterfaceAnnotations(final Set<Class<? extends AbstractServiceInterface>> implementedServiceIntefaces) {
    Set<Class<? extends AbstractServiceInterface>> inspected = getAllAbstractServiceInterfaceClasses(implementedServiceIntefaces);
    Set<ServiceInterfaceAnnotation> result = new HashSet<>();
    // AbstractSI
    for (Class<?> clazz : inspected) {
        ServiceInterfaceAnnotation annotation = clazz.getAnnotation(ServiceInterfaceAnnotation.class);
        if (annotation != null) {
            result.add(annotation);
        }
    }
    return Collections.unmodifiableSet(result);
}
Also used : ServiceInterfaceAnnotation(org.opendaylight.controller.config.api.annotations.ServiceInterfaceAnnotation) AbstractServiceInterface(org.opendaylight.controller.config.api.annotations.AbstractServiceInterface) HashSet(java.util.HashSet)

Aggregations

HashSet (java.util.HashSet)1 AbstractServiceInterface (org.opendaylight.controller.config.api.annotations.AbstractServiceInterface)1 ServiceInterfaceAnnotation (org.opendaylight.controller.config.api.annotations.ServiceInterfaceAnnotation)1