package org.opendaylight.controller.sal.binding.api;
import org.opendaylight.controller.md.sal.common.api.routing.RoutedRegistration;
-import org.opendaylight.controller.sal.binding.api.BindingAwareProvider.ProviderFunctionality;
-import org.opendaylight.controller.sal.binding.api.data.DataBrokerService;
-import org.opendaylight.controller.sal.binding.api.data.DataProviderService;
import org.opendaylight.yangtools.concepts.ObjectRegistration;
import org.opendaylight.yangtools.yang.binding.BaseIdentity;
import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
* <li>Notification Service - see {@link NotificationService} and
* {@link NotificationProviderService}
* <li>Functionality and Data model
- * <li>Data Store access and modification - see {@link DataBrokerService} and
- * {@link DataProviderService}
+ * <li>Data Store access and modification - see {@link org.opendaylight.controller.sal.binding.api.data.DataBrokerService} and
+ * {@link org.opendaylight.controller.sal.binding.api.data.DataProviderService}
* </ul>
*
* The services are exposed via session.
*
* For more information about session-based access see {@link ConsumerContext}
* and {@link ProviderContext}
- *
- *
- *
*/
public interface BindingAwareBroker {
+ /*
+ * @deprecated Use registerConsumer(BindingAwareConsumer cons) instead (BundleContext is no longer used)
+ */
+ @Deprecated
+ ConsumerContext registerConsumer(BindingAwareConsumer consumer, BundleContext ctx);
+
/**
* Registers the {@link BindingAwareConsumer}, which will use the SAL layer.
*
* @throws IllegalStateException
* If the consumer is already registered.
*/
- ConsumerContext registerConsumer(BindingAwareConsumer consumer, BundleContext ctx);
+ ConsumerContext registerConsumer(BindingAwareConsumer consumer);
+
+ /*
+ * @deprecated Use registerProvider(BindingAwareProvider prov) instead (BundleContext is no longer used)
+ */
+ @Deprecated
+ ProviderContext registerProvider(BindingAwareProvider provider, BundleContext ctx);
/**
* Registers the {@link BindingAwareProvider}, which will use the SAL layer.
* @throws IllegalStateException
* If the consumer is already registered.
*/
- ProviderContext registerProvider(BindingAwareProvider provider, BundleContext ctx);
+ ProviderContext registerProvider(BindingAwareProvider provider);
/**
* {@link BindingAwareConsumer} specific access to the SAL functionality.
* functionality) for the consumer and provides access to the SAL
* infrastructure services and other functionality provided by
* {@link Provider}s.
- *
- *
- *
*/
public interface ConsumerContext extends RpcConsumerRegistry {
* @return Session specific implementation of service
*/
<T extends BindingAwareService> T getSALService(Class<T> service);
-
-
}
/**
*/
public interface ProviderContext extends ConsumerContext, RpcProviderRegistry {
- @Deprecated
- void registerFunctionality(ProviderFunctionality functionality);
-
- @Deprecated
- void unregisterFunctionality(ProviderFunctionality functionality);
}
+ /**
+ * Represents an RPC implementation registration. Users should call the
+ * {@link ObjectRegistration#close close} method when the registration is no longer needed.
+ *
+ * @param <T> the implemented RPC service interface
+ */
public interface RpcRegistration<T extends RpcService> extends ObjectRegistration<T> {
+ /**
+ * Returns the implemented RPC service interface.
+ */
Class<T> getServiceType();
+
+ @Override
+ void close();
}
+ /**
+ * Represents a routed RPC implementation registration. Users should call the
+ * {@link RoutedRegistration#close close} method when the registration is no longer needed.
+ *
+ * @param <T> the implemented RPC service interface
+ */
public interface RoutedRpcRegistration<T extends RpcService> extends RpcRegistration<T>,
RoutedRegistration<Class<? extends BaseIdentity>, InstanceIdentifier<?>, T> {