sangho | 6a9ff0d | 2017-03-27 11:23:37 +0900 | [diff] [blame^] | 1 | /* |
| 2 | * Copyright 2017-present Open Networking Laboratory |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | package org.onosproject.openstacknetworking.api; |
| 17 | |
| 18 | import org.openstack4j.model.network.SecurityGroup; |
| 19 | import org.openstack4j.model.network.SecurityGroupRule; |
| 20 | |
| 21 | /** |
| 22 | * Service for administering the inventory of Openstack security group. |
| 23 | */ |
| 24 | public interface OpenstackSecurityGroupAdminService { |
| 25 | /** |
| 26 | * Creates a security group. |
| 27 | * |
| 28 | * @param sg security group |
| 29 | */ |
| 30 | void createSecurityGroup(SecurityGroup sg); |
| 31 | |
| 32 | /** |
| 33 | * Removes the security group. |
| 34 | * |
| 35 | * @param sgId security group ID |
| 36 | */ |
| 37 | void removeSecurityGroup(String sgId); |
| 38 | |
| 39 | /** |
| 40 | * Creates a security group rule. |
| 41 | * |
| 42 | * @param sgRule security group rule |
| 43 | */ |
| 44 | void createSecurityGroupRule(SecurityGroupRule sgRule); |
| 45 | |
| 46 | /** |
| 47 | * Removes the security group rule. |
| 48 | * |
| 49 | * @param sgRuleId security group rule ID |
| 50 | */ |
| 51 | void removeSecurityGroupRule(String sgRuleId); |
| 52 | } |