2 * Copyright (c) 2014, 2015 Red Hat, Inc. 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
9 package org.opendaylight.netvirt.openstack.netvirt.translator.crud.impl;
11 import java.util.List;
13 import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ProviderContext;
14 import org.opendaylight.netvirt.openstack.netvirt.translator.NeutronFirewallRule;
15 import org.opendaylight.netvirt.openstack.netvirt.translator.INeutronObject;
16 import org.opendaylight.netvirt.openstack.netvirt.translator.crud.INeutronFirewallRuleCRUD;
17 import org.opendaylight.yangtools.yang.binding.DataObject;
18 import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
19 import org.osgi.framework.BundleContext;
20 import org.osgi.framework.ServiceRegistration;
22 public class NeutronFirewallRuleInterface extends AbstractNeutronInterface implements INeutronFirewallRuleCRUD {
24 NeutronFirewallRuleInterface(ProviderContext providerContext) {
25 super(providerContext);
29 public boolean neutronFirewallRuleExists(String uuid) {
30 // TODO Auto-generated method stub
35 public NeutronFirewallRule getNeutronFirewallRule(String uuid) {
36 // TODO Auto-generated method stub
41 public List<NeutronFirewallRule> getAllNeutronFirewallRules() {
42 // TODO Auto-generated method stub
47 public boolean addNeutronFirewallRule(NeutronFirewallRule input) {
48 // TODO Auto-generated method stub
53 public boolean removeNeutronFirewallRule(String uuid) {
54 // TODO Auto-generated method stub
59 public boolean updateNeutronFirewallRule(String uuid,
60 NeutronFirewallRule delta) {
61 // TODO Auto-generated method stub
66 public boolean neutronFirewallRuleInUse(String uuid) {
67 // TODO Auto-generated method stub
72 protected InstanceIdentifier createInstanceIdentifier(DataObject item) {
73 // TODO Auto-generated method stub
78 protected DataObject toMd(INeutronObject neutronObject) {
79 // TODO Auto-generated method stub
84 protected DataObject toMd(String uuid) {
85 // TODO Auto-generated method stub
89 public static void registerNewInterface(BundleContext context,
90 ProviderContext providerContext,
91 List<ServiceRegistration<?>> registrations) {
92 NeutronFirewallRuleInterface neutronFirewallRuleInterface = new NeutronFirewallRuleInterface(providerContext);
93 ServiceRegistration<INeutronFirewallRuleCRUD> neutronFirewallRuleInterfaceRegistration = context.registerService(INeutronFirewallRuleCRUD.class, neutronFirewallRuleInterface, null);
94 if(neutronFirewallRuleInterfaceRegistration != null) {
95 registrations.add(neutronFirewallRuleInterfaceRegistration);