2 * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
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
8 * http://www.apache.org/licenses/LICENSE-2.0
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.
18 using Native = Interop.MediaControllerClient;
20 namespace Tizen.Multimedia.MediaController
23 /// Metadata represents a metadata of media for server application to play
25 public class MediaControllerMetadata
28 /// The constructor of MediaControllerMetadata class.
30 /// <since_tizen> 3 </since_tizen>
31 public MediaControllerMetadata()
36 internal MediaControllerMetadata(IntPtr handle)
38 if (handle == IntPtr.Zero)
40 throw new InvalidOperationException("MediaControllerMetadata is not valid.");
43 Title = Native.GetMetadata(handle, MediaControllerAttributes.Title);
44 Artist = Native.GetMetadata(handle, MediaControllerAttributes.Artist);
45 Album = Native.GetMetadata(handle, MediaControllerAttributes.Album);
46 Author = Native.GetMetadata(handle, MediaControllerAttributes.Author);
47 Genre = Native.GetMetadata(handle, MediaControllerAttributes.Genre);
48 Duration = Native.GetMetadata(handle, MediaControllerAttributes.Duration);
49 Date = Native.GetMetadata(handle, MediaControllerAttributes.Date);
50 Copyright = Native.GetMetadata(handle, MediaControllerAttributes.Copyright);
51 Description = Native.GetMetadata(handle, MediaControllerAttributes.Description);
52 TrackNumber = Native.GetMetadata(handle, MediaControllerAttributes.TrackNumber);
53 Picture = Native.GetMetadata(handle, MediaControllerAttributes.Picture);
57 /// Set/Get the Title of media
59 /// <since_tizen> 3 </since_tizen>
60 public string Title { get; set; }
63 /// Set/Get the Artist of media
65 /// <since_tizen> 3 </since_tizen>
66 public string Artist { get; set; }
69 /// Set/Get the Album of media
71 /// <since_tizen> 3 </since_tizen>
72 public string Album { get; set; }
75 /// Set/Get the Author of media
77 /// <since_tizen> 3 </since_tizen>
78 public string Author { get; set; }
81 /// Set/Get the Genre of media
83 /// <since_tizen> 3 </since_tizen>
84 public string Genre { get; set; }
87 /// Set/Get the Duration of media
89 /// <since_tizen> 3 </since_tizen>
90 public string Duration { get; set; }
93 /// Set/Get the Date of media
95 /// <since_tizen> 3 </since_tizen>
96 public string Date { get; set; }
99 /// Set/Get the Copyright of media
101 /// <since_tizen> 3 </since_tizen>
102 public string Copyright { get; set; }
105 /// Set/Get the Description of media
107 /// <since_tizen> 3 </since_tizen>
108 public string Description { get; set; }
111 /// Set/Get the Track Number of media
113 /// <since_tizen> 3 </since_tizen>
114 public string TrackNumber { get; set; }
117 /// Set/Get the Picture of media
119 /// <since_tizen> 3 </since_tizen>
120 public string Picture { get; set; }