]> git.basschouten.com Git - openhab-addons.git/blob
c8dac0e5df0e3cd2b259393ae55741eef1b374c6
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2020 Contributors to the openHAB project
3  *
4  * See the NOTICE file(s) distributed with this work for additional
5  * information.
6  *
7  * This program and the accompanying materials are made available under the
8  * terms of the Eclipse Public License 2.0 which is available at
9  * http://www.eclipse.org/legal/epl-2.0
10  *
11  * SPDX-License-Identifier: EPL-2.0
12  */
13 package org.openhab.binding.volvooncall.internal.dto;
14
15 import org.eclipse.jdt.annotation.NonNullByDefault;
16
17 import com.google.gson.annotations.SerializedName;
18
19 /**
20  * The {@link PostResponse} is responsible for storing
21  * elements given back after a post to VOC api
22  *
23  * @author GaĆ«l L'hopital - Initial contribution
24  */
25 @NonNullByDefault
26 public class PostResponse extends VocAnswer {
27
28     public static enum Status {
29         @SerializedName("Started")
30         STARTED,
31         @SerializedName("MessageDelivered")
32         DELIVERED,
33         @SerializedName("Failed")
34         FAILED,
35         @SerializedName("Successful")
36         SUCCESSFULL
37     }
38
39     public static enum ServiceType {
40         RHBLF, // Remote Honk and Blink Lights ?
41         RDU, // Remote door unlock
42         ERS, // Remote engine start
43         TN // Theft notification
44     }
45
46     public @NonNullByDefault({}) Status status;
47     public @NonNullByDefault({}) String vehicleId;
48     @SerializedName("service")
49     public @NonNullByDefault({}) String serviceURL;
50     public @NonNullByDefault({}) ServiceType serviceType;
51
52     /*
53      * Currently unused in the binding, maybe interesting in the future
54      *
55      * public static enum FailureReason {
56      *
57      * @SerializedName("TimeframePassed")
58      * TIME_FRAME_PASSED
59      * }
60      *
61      * private ZonedDateTime statusTimestamp;
62      * private ZonedDateTime startTime;
63      * private FailureReason failureReason;
64      *
65      * private Integer customerServiceId;
66      */
67 }