Fix java check style issue
[msb/discovery.git] / sdclient / discovery-service / src / main / java / org / onap / msb / sdclient / core / AgentService.java
1 /**
2  * Copyright 2016-2017 ZTE, Inc. and others.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
5  * in compliance with the License. You may obtain a copy of the License at
6  *
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software distributed under the License
10  * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
11  * or implied. See the License for the specific language governing permissions and limitations under
12  * the License.
13  */
14 package org.onap.msb.sdclient.core;
15
16 import java.io.Serializable;
17 import java.util.List;
18
19 import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
20 import com.fasterxml.jackson.annotation.JsonInclude;
21 import com.fasterxml.jackson.annotation.JsonInclude.Include;
22 import com.fasterxml.jackson.annotation.JsonProperty;
23
24 @JsonIgnoreProperties(ignoreUnknown = true)
25 public class AgentService implements Serializable {
26
27
28     private static final long serialVersionUID = 1L;
29
30     @JsonProperty("ID")
31     private String id;
32
33     @JsonProperty("Name")
34     private String name;
35
36     @JsonProperty("Tags")
37     private List<String> tags;
38
39     @JsonProperty("Address")
40     private String address;
41
42     @JsonProperty("Port")
43     private int port;
44
45     @JsonProperty("Check")
46     @JsonInclude(Include.NON_EMPTY)
47     private Check check;
48
49     @JsonInclude(Include.NON_EMPTY)
50     public class Check {
51
52         @JsonProperty("HTTP")
53         private String http;
54
55         @JsonProperty("TCP")
56         private String tcp;
57
58         @JsonProperty("TTL")
59         private String ttl;
60
61         @JsonProperty("Interval")
62         private String interval;
63
64         @JsonProperty("Timeout")
65         private String timeout;
66
67
68         private String status = "passing";
69
70         public String getTimeout() {
71             return timeout;
72         }
73
74         public void setTimeout(String timeout) {
75             this.timeout = timeout;
76         }
77
78         public String getHttp() {
79             return http;
80         }
81
82         public void setHttp(String http) {
83             this.http = http;
84         }
85
86         public String getTcp() {
87             return tcp;
88         }
89
90         public void setTcp(String tcp) {
91             this.tcp = tcp;
92         }
93
94         public String getTtl() {
95             return ttl;
96         }
97
98         public void setTtl(String ttl) {
99             this.ttl = ttl;
100         }
101
102         public String getInterval() {
103             return interval;
104         }
105
106         public void setInterval(String interval) {
107             this.interval = interval;
108         }
109
110         public String getStatus() {
111             return status;
112         }
113
114         public void setStatus(String status) {
115             this.status = status;
116         }
117
118
119     }
120
121     public String getId() {
122         return id;
123     }
124
125     public void setId(String id) {
126         this.id = id;
127     }
128
129
130
131     public String getName() {
132         return name;
133     }
134
135     public void setName(String name) {
136         this.name = name;
137     }
138
139     public List<String> getTags() {
140         return tags;
141     }
142
143     public void setTags(List<String> tags) {
144         this.tags = tags;
145     }
146
147     public String getAddress() {
148         return address;
149     }
150
151     public void setAddress(String address) {
152         this.address = address;
153     }
154
155     public int getPort() {
156         return port;
157     }
158
159     public void setPort(int port) {
160         this.port = port;
161     }
162
163     public Check getCheck() {
164         return check;
165     }
166
167     public void setCheck(Check check) {
168         this.check = check;
169     }
170
171     public Check createCheck() {
172         return new Check();
173
174     }
175 }