Fix Spike Event Processing with Common Format
[aai/data-router.git] / src / main / java / org / onap / aai / datarouter / entity / SpikeEventHeader.java
1 /**
2  * ============LICENSE_START=======================================================
3  * org.onap.aai
4  * ================================================================================
5  * Copyright © 2017-2018 AT&T Intellectual Property. All rights reserved.
6  * Copyright © 2017-2018 Amdocs
7  * ================================================================================
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  *       http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19  * ============LICENSE_END=========================================================
20  */
21 package org.onap.aai.datarouter.entity;
22
23 import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
24 import com.fasterxml.jackson.annotation.JsonProperty;
25
26 @JsonIgnoreProperties(ignoreUnknown = true)
27 public class SpikeEventHeader {
28
29   @JsonProperty("request-id")
30   private String requestId;
31
32   private String timestamp;
33
34   @JsonProperty("source-name")
35   private String sourceName;
36
37   @JsonProperty("event-type")
38   private String eventType;
39
40   public String getRequestId() {
41     return requestId;
42   }
43
44   public void setRequestId(String requestId) {
45     this.requestId = requestId;
46   }
47
48   public String getTimestamp() {
49     return timestamp;
50   }
51
52   public void setTimestamp(String timestamp) {
53     this.timestamp = timestamp;
54   }
55
56   public String getSourceName() {
57     return sourceName;
58   }
59
60   public void setSourceName(String sourceName) {
61     this.sourceName = sourceName;
62   }
63
64   public String getEventType() {
65     return eventType;
66   }
67
68   public void setEventType(String eventType) {
69     this.eventType = eventType;
70   }
71
72   @Override
73   public String toString() {
74     return "SpikeEventHeader [" + (requestId != null ? "requestId=" + requestId + ", " : "")
75         + (timestamp != null ? "timestamp=" + timestamp + ", " : "")
76         + (sourceName != null ? "sourceName=" + sourceName + ", " : "")
77         + (eventType != null ? "eventType=" + eventType : "") + "]";
78   }
79
80 }