]> git.basschouten.com Git - openhab-addons.git/blob
1bcab88b2eefb13b778d63e69b9d24be6cf76c45
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2023 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.yamahamusiccast.internal.dto;
14
15 import com.google.gson.annotations.SerializedName;
16
17 /**
18  * This class represents the PlayInfo request requested from the Yamaha model/device via the API.
19  *
20  * @author Lennert Coopman - Initial contribution
21  */
22
23 public class PlayInfo {
24
25     @SerializedName("response_code")
26     private String responseCode;
27
28     @SerializedName("playback")
29     private String playback;
30
31     @SerializedName("artist")
32     private String artist;
33
34     @SerializedName("track")
35     private String track;
36
37     @SerializedName("album")
38     private String album;
39
40     @SerializedName("albumart_url")
41     private String albumarturl;
42
43     @SerializedName("repeat")
44     private String repeat;
45
46     @SerializedName("shuffle")
47     private String shuffle;
48
49     @SerializedName("play_time")
50     private int playTime = 0;
51
52     @SerializedName("total_time")
53     private int totalTime = 0;
54
55     public String getResponseCode() {
56         if (responseCode == null) {
57             responseCode = "";
58         }
59         return responseCode;
60     }
61
62     public String getPlayback() {
63         if (playback == null) {
64             playback = "";
65         }
66         return playback;
67     }
68
69     public String getArtist() {
70         if (artist == null) {
71             artist = "";
72         }
73         return artist;
74     }
75
76     public String getTrack() {
77         if (track == null) {
78             track = "";
79         }
80         return track;
81     }
82
83     public String getAlbum() {
84         if (album == null) {
85             album = "";
86         }
87         return album;
88     }
89
90     public String getAlbumArtUrl() {
91         if (albumarturl == null) {
92             albumarturl = "";
93         }
94         return albumarturl;
95     }
96
97     public String getRepeat() {
98         if (repeat == null) {
99             repeat = "";
100         }
101         return repeat;
102     }
103
104     public String getShuffle() {
105         if (shuffle == null) {
106             shuffle = "";
107         }
108         return shuffle;
109     }
110
111     public int getPlayTime() {
112         return playTime;
113     }
114
115     public int getTotalTime() {
116         return totalTime;
117     }
118 }