2 * Copyright (c) 2020 PANTHEON.tech, s.r.o. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
8 package org.opendaylight.mdsal.binding.dom.adapter.osgi;
10 import com.google.common.annotations.Beta;
13 import org.eclipse.jdt.annotation.NonNull;
14 import org.opendaylight.mdsal.binding.api.ActionService;
15 import org.opendaylight.mdsal.binding.api.DataTreeIdentifier;
16 import org.opendaylight.yangtools.yang.binding.Action;
17 import org.opendaylight.yangtools.yang.binding.DataObject;
18 import org.osgi.service.component.annotations.Activate;
19 import org.osgi.service.component.annotations.Component;
20 import org.osgi.service.component.annotations.Deactivate;
23 @Component(factory = OSGiActionService.FACTORY_NAME)
24 public final class OSGiActionService extends AbstractAdaptedService<ActionService> implements ActionService {
25 // OSGi DS Component Factory name
26 static final String FACTORY_NAME = "org.opendaylight.mdsal.binding.dom.adapter.osgi.OSGiActionService";
28 public OSGiActionService() {
29 super(ActionService.class);
33 public <O extends @NonNull DataObject, T extends @NonNull Action<?, ?, ?>> T getActionHandle(
34 final Class<T> actionInterface, final Set<@NonNull DataTreeIdentifier<O>> validNodes) {
35 return delegate().getActionHandle(actionInterface, validNodes);
39 void activate(final Map<String, ?> properties) {
44 void deactivate(final int reason) {