blob: 8cd063aa213a2a5f62a316bc3e69bcfdf7aeb694 [file] [log] [blame]
Thomas Vachuska02aeb032015-01-06 22:36:30 -08001/*
2 * Copyright 2015 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.core;
17
18import java.net.URI;
Thomas Vachuskaebf5e542015-02-03 19:38:13 -080019import java.util.List;
Thomas Vachuska02aeb032015-01-06 22:36:30 -080020import java.util.Optional;
21import java.util.Set;
22
23/**
24 * Abstraction of a network control/management application.
25 */
26public interface Application {
27
28 /**
29 * Returns the application name id.
30 *
31 * @return application identifier
32 */
33 ApplicationId id();
34
35 /**
36 * Returns the application version.
37 *
38 * @return application version
39 */
40 Version version();
41
42 /**
43 * Returns description of the application.
44 *
45 * @return application description text
46 */
47 String description();
48
49 /**
50 * Returns the name of the application origin, group or company.
51 *
52 * @return application origin
53 */
54 String origin();
55
56 /**
Changhoon Yoonbdeb88a2015-05-12 20:35:31 +090057 * Returns the role of the application.
58 *
59 * @return application role
60 */
61 ApplicationRole role();
62
63 /**
Thomas Vachuska02aeb032015-01-06 22:36:30 -080064 * Returns the permissions requested by the application.
65 *
66 * @return requested permissions
67 */
68 Set<Permission> permissions();
69
70 /**
71 * Returns the feature repository URI. Null value signifies that the
72 * application did not provide its own features repository.
73 *
74 * @return optional feature repo URL
75 */
76 Optional<URI> featuresRepo();
77
78 /**
Thomas Vachuskaebf5e542015-02-03 19:38:13 -080079 * Returns the list of features comprising the application. At least one
Thomas Vachuska02aeb032015-01-06 22:36:30 -080080 * feature must be given.
81 *
82 * @return application features
83 */
Thomas Vachuskaebf5e542015-02-03 19:38:13 -080084 List<String> features();
Thomas Vachuska02aeb032015-01-06 22:36:30 -080085}