Simon Hunt | f844f63 | 2015-05-20 19:06:35 -0700 | [diff] [blame] | 1 | /* |
| 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 | * |
| 16 | */ |
| 17 | |
| 18 | package org.onosproject.cord.gui.model; |
| 19 | |
| 20 | /** |
| 21 | * Designates XOS Functions. |
| 22 | */ |
| 23 | public enum XosFunctionDescriptor { |
| 24 | /** |
| 25 | * Internet function. |
| 26 | */ |
| 27 | INTERNET("internet", |
| 28 | "Internet", |
| 29 | "Basic internet connectivity."), |
| 30 | |
| 31 | /** |
| 32 | * Firewall function. |
| 33 | */ |
| 34 | FIREWALL("firewall", |
| 35 | "Firewall", |
| 36 | "Normal firewall protection."), |
| 37 | |
| 38 | /** |
| 39 | * URL Filtering function (parental controls). |
| 40 | */ |
Simon Hunt | a29c87b | 2015-05-21 09:56:19 -0700 | [diff] [blame] | 41 | URL_FILTER("url_filter", |
| 42 | "Parental Control", |
| 43 | "Variable levels of URL filtering."); |
Simon Hunt | f844f63 | 2015-05-20 19:06:35 -0700 | [diff] [blame] | 44 | |
| 45 | private final String id; |
| 46 | private final String displayName; |
| 47 | private final String description; |
| 48 | |
| 49 | XosFunctionDescriptor(String id, String displayName, String description) { |
| 50 | this.id = id; |
| 51 | this.displayName = displayName; |
| 52 | this.description = description; |
| 53 | } |
| 54 | |
| 55 | /** |
| 56 | * Returns this function's internal identifier. |
| 57 | * |
| 58 | * @return the identifier |
| 59 | */ |
| 60 | public String id() { |
| 61 | return id; |
| 62 | } |
| 63 | |
| 64 | /** |
| 65 | * Returns this function's display name. |
| 66 | * |
| 67 | * @return display name |
| 68 | */ |
| 69 | public String displayName() { |
| 70 | return displayName; |
| 71 | } |
| 72 | |
| 73 | /** |
| 74 | * Returns a short, textual description of the function. |
| 75 | * |
| 76 | * @return textual description |
| 77 | */ |
| 78 | public String description() { |
| 79 | return description; |
| 80 | } |
| 81 | |
| 82 | } |