blob: 2ffec86293b6b9f0f73d8e530331ea4d31fe8135 [file] [log] [blame]
sangho6a9ff0d2017-03-27 11:23:37 +09001/*
Brian O'Connora09fe5b2017-08-03 21:12:30 -07002 * Copyright 2017-present Open Networking Foundation
sangho6a9ff0d2017-03-27 11:23:37 +09003 *
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 */
16package org.onosproject.openstacknetworking.api;
17
18import org.openstack4j.model.network.SecurityGroup;
19import org.openstack4j.model.network.SecurityGroupRule;
20
21/**
22 * Service for administering the inventory of Openstack security group.
23 */
Jian Li21536592018-03-06 15:10:55 +090024public interface OpenstackSecurityGroupAdminService extends OpenstackSecurityGroupService {
sangho6a9ff0d2017-03-27 11:23:37 +090025 /**
26 * Creates a security group.
27 *
28 * @param sg security group
29 */
30 void createSecurityGroup(SecurityGroup sg);
31
32 /**
Hyunsun Moonae51e732017-04-25 17:46:21 +090033 * Updates the security group.
34 *
35 * @param sg security group
36 */
37 void updateSecurityGroup(SecurityGroup sg);
38
39 /**
sangho6a9ff0d2017-03-27 11:23:37 +090040 * Removes the security group.
41 *
42 * @param sgId security group ID
43 */
44 void removeSecurityGroup(String sgId);
45
46 /**
47 * Creates a security group rule.
48 *
49 * @param sgRule security group rule
50 */
51 void createSecurityGroupRule(SecurityGroupRule sgRule);
52
53 /**
54 * Removes the security group rule.
55 *
56 * @param sgRuleId security group rule ID
57 */
58 void removeSecurityGroupRule(String sgRuleId);
Hyunsun Moonae51e732017-04-25 17:46:21 +090059
60 /**
61 * Removes the existing security groups.
62 */
63 void clear();
sangho6a9ff0d2017-03-27 11:23:37 +090064}