blob: a0ed9951005d9d9f5bf74cbf3a597db4216ad3c8 [file] [log] [blame]
Yi Tsengf4e13e32017-03-30 15:38:39 -07001/*
Brian O'Connora09fe5b2017-08-03 21:12:30 -07002 * Copyright 2017-present Open Networking Foundation
Yi Tsengf4e13e32017-03-30 15:38:39 -07003 *
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.vpls.api;
17
18import org.onosproject.store.Store;
19import org.onosproject.store.StoreDelegate;
20import org.onosproject.vpls.store.VplsStoreEvent;
21
22import java.util.Collection;
23
24/**
25 * Definition of the operations regarding the management of the VPLS elements.
26 */
27public interface VplsStore extends Store<VplsStoreEvent, StoreDelegate<VplsStoreEvent>> {
28 /**
29 * Adds a VPLS to the configuration.
30 *
31 * @param vplsData the VPLS to add
32 */
33 void addVpls(VplsData vplsData);
34
35 /**
36 * Removes a VPLS from the configuration.
37 *
38 * @param vplsData the VPLS to remove
39 */
40 void removeVpls(VplsData vplsData);
41
42 /**
43 * Updates a VPLS.
44 *
45 * @param vplsData the VPLS to update
46 */
47 void updateVpls(VplsData vplsData);
48
49 /**
50 * Gets a VPLS by name.
51 *
52 * @param vplsName the VPLS name
53 * @return the VPLS instance if it exists; null otherwise
54 */
55 VplsData getVpls(String vplsName);
56
57 /**
58 * Gets all the VPLSs.
59 *
60 * @return all the VPLSs
61 */
62 Collection<VplsData> getAllVpls();
63}