blob: 6b9f4c0fac9ef1fa0b95a9864dbf09412a4b6e7a [file] [log] [blame]
sangho6a9ff0d2017-03-27 11:23:37 +09001/*
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 */
16package org.onosproject.openstacknetworking.api;
17
18import org.onosproject.event.ListenerService;
19import org.openstack4j.model.network.SecurityGroup;
Hyunsun Moonae51e732017-04-25 17:46:21 +090020
21import java.util.Set;
sangho6a9ff0d2017-03-27 11:23:37 +090022
23/**
24 * Service for interfacing OpenStack SecurityGroup events and SecurityGroup store.
sangho6a9ff0d2017-03-27 11:23:37 +090025 */
26public interface OpenstackSecurityGroupService
27 extends ListenerService<OpenstackSecurityGroupEvent, OpenstackSecurityGroupListener> {
28
29 /**
Hyunsun Moonae51e732017-04-25 17:46:21 +090030 * Returns all security groups.
31 *
32 * @return set of security group
33 */
34 Set<SecurityGroup> securityGroups();
35
36 /**
sangho6a9ff0d2017-03-27 11:23:37 +090037 * Returns the security group for the sgId.
38 *
39 * @param sgId security group Id
40 * @return security group
41 */
42 SecurityGroup securityGroup(String sgId);
sangho6a9ff0d2017-03-27 11:23:37 +090043}