]> git.basschouten.com Git - openhab-addons.git/blob
1628a490625c6c2d78791c7aeb76dea106c69d2c
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2022 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.sonos.internal;
14
15 import org.eclipse.jdt.annotation.NonNullByDefault;
16
17 /**
18  * The {@link SonosMetaData} is a datastructure to the metadata
19  * of audio in the Sonos ecosystem
20  *
21  * @author Karel Goderis - Initial contribution
22  */
23 @NonNullByDefault
24 public class SonosMetaData {
25
26     private final String id;
27     private final String parentId;
28     private final String resource;
29     private final String streamContent;
30     private final String albumArtUri;
31     private final String title;
32     private final String upnpClass;
33     private final String creator;
34     private final String album;
35     private final String albumArtist;
36
37     public SonosMetaData(String id, String parentId, String res, String streamContent, String albumArtUri, String title,
38             String upnpClass, String creator, String album, String albumArtist) {
39         this.id = id;
40         this.parentId = parentId;
41         this.resource = res;
42         this.streamContent = streamContent;
43         this.albumArtUri = albumArtUri;
44         this.title = title;
45         this.upnpClass = upnpClass;
46         this.creator = creator;
47         this.album = album;
48         this.albumArtist = albumArtist;
49     }
50
51     @Override
52     public String toString() {
53         return "SonosMetaData [id=" + id + ", parentID=" + parentId + ", resource=" + resource + " ,streamContent="
54                 + streamContent + ", arturi=" + albumArtUri + ", title=" + title + ", upnpclass=" + upnpClass
55                 + ", creator=" + creator + ", album=" + album + ", albumtartist=" + albumArtist + "]";
56     }
57
58     public String getAlbum() {
59         return album;
60     }
61
62     public String getAlbumArtist() {
63         return albumArtist;
64     }
65
66     public String getAlbumArtUri() {
67         return albumArtUri;
68     }
69
70     public String getCreator() {
71         return creator;
72     }
73
74     public String getResource() {
75         return resource;
76     }
77
78     public String getStreamContent() {
79         return streamContent;
80     }
81
82     public String getTitle() {
83         return title;
84     }
85
86     public String getUpnpClass() {
87         return upnpClass;
88     }
89
90     public String getId() {
91         return id;
92     }
93
94     public String getParentId() {
95         return parentId;
96     }
97 }