]> git.basschouten.com Git - openhab-addons.git/blob
f0a57e097d1fe0b9b6ecd8a66560a067d66bcb65
[openhab-addons.git] /
1 /**
2  * Copyright 2017-2018 Gregory Moyer and contributors.
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 package org.openhab.binding.lametrictime.api.local.model;
17
18 import java.time.LocalDateTime;
19
20 public class Notification
21 {
22     private String id;
23     private String type;
24     private LocalDateTime created;
25     private LocalDateTime expirationDate;
26     private String priority;
27     private String iconType;
28     private Integer lifetime;
29     private NotificationModel model;
30
31     public String getId()
32     {
33         return id;
34     }
35
36     public void setId(String id)
37     {
38         this.id = id;
39     }
40
41     public Notification withId(String id)
42     {
43         this.id = id;
44         return this;
45     }
46
47     public String getType()
48     {
49         return type;
50     }
51
52     public void setType(String type)
53     {
54         this.type = type;
55     }
56
57     public Notification withType(String type)
58     {
59         this.type = type;
60         return this;
61     }
62
63     public LocalDateTime getCreated()
64     {
65         return created;
66     }
67
68     public void setCreated(LocalDateTime created)
69     {
70         this.created = created;
71     }
72
73     public Notification withCreated(LocalDateTime created)
74     {
75         this.created = created;
76         return this;
77     }
78
79     public LocalDateTime getExpirationDate()
80     {
81         return expirationDate;
82     }
83
84     public void setExpirationDate(LocalDateTime expirationDate)
85     {
86         this.expirationDate = expirationDate;
87     }
88
89     public Notification withExpirationDate(LocalDateTime expirationDate)
90     {
91         this.expirationDate = expirationDate;
92         return this;
93     }
94
95     public String getPriority()
96     {
97         return priority;
98     }
99
100     public void setPriority(String priority)
101     {
102         this.priority = priority;
103     }
104
105     public Notification withPriority(String priority)
106     {
107         this.priority = priority;
108         return this;
109     }
110
111     public String getIconType()
112     {
113         return iconType;
114     }
115
116     public void setIconType(String iconType)
117     {
118         this.iconType = iconType;
119     }
120
121     public Notification withIconType(String iconType)
122     {
123         this.iconType = iconType;
124         return this;
125     }
126
127     public Integer getLifetime()
128     {
129         return lifetime;
130     }
131
132     public void setLifetime(Integer lifetime)
133     {
134         this.lifetime = lifetime;
135     }
136
137     public Notification withLifetime(Integer lifetime)
138     {
139         this.lifetime = lifetime;
140         return this;
141     }
142
143     public NotificationModel getModel()
144     {
145         return model;
146     }
147
148     public void setModel(NotificationModel model)
149     {
150         this.model = model;
151     }
152
153     public Notification withModel(NotificationModel model)
154     {
155         this.model = model;
156         return this;
157     }
158
159     @Override
160     public String toString()
161     {
162         StringBuilder builder = new StringBuilder();
163         builder.append("Notification [id=");
164         builder.append(id);
165         builder.append(", type=");
166         builder.append(type);
167         builder.append(", created=");
168         builder.append(created);
169         builder.append(", expirationDate=");
170         builder.append(expirationDate);
171         builder.append(", priority=");
172         builder.append(priority);
173         builder.append(", iconType=");
174         builder.append(iconType);
175         builder.append(", lifetime=");
176         builder.append(lifetime);
177         builder.append(", model=");
178         builder.append(model);
179         builder.append("]");
180         return builder.toString();
181     }
182 }