blob: 1e545c53cc2718ae708091f0600329aa0ae49cbc [file] [log] [blame]
Thomas Vachuska0fa2aa12015-08-18 12:53:04 -07001/*
Brian O'Connor5ab426f2016-04-09 01:19:45 -07002 * Copyright 2015-present Open Networking Laboratory
Thomas Vachuska0fa2aa12015-08-18 12:53:04 -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.rest;
17
18import com.google.common.annotations.Beta;
19
20import java.util.Set;
21
22/**
23 * Service for registering REST API documentation resources.
24 */
25@Beta
26public interface ApiDocService {
27
28 /**
29 * Registers the specified REST API documentation provider.
30 *
31 * @param provider REST API documentation provider
32 */
33 void register(ApiDocProvider provider);
34
35 /**
36 * Unregisters the specified REST API documentation provider.
37 *
38 * @param provider REST API documentation provider
39 */
40 void unregister(ApiDocProvider provider);
41
42 /**
43 * Returns the set of all registered REST API documentation providers.
44 *
45 * @return set of registered documentation providers
46 */
47 Set<ApiDocProvider> getDocProviders();
48
49 /**
50 * Returns the specified REST API documentation provider with the specified
51 * key.
52 *
53 * @param key REST API key
54 * @return documentation provider
55 */
56 ApiDocProvider getDocProvider(String key);
57
58}