1 /* 2 * This file is part of gtkD. 3 * 4 * gtkD is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU Lesser General Public License 6 * as published by the Free Software Foundation; either version 3 7 * of the License, or (at your option) any later version, with 8 * some exceptions, please read the COPYING file. 9 * 10 * gtkD is distributed in the hope that it will be useful, 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 * GNU Lesser General Public License for more details. 14 * 15 * You should have received a copy of the GNU Lesser General Public License 16 * along with gtkD; if not, write to the Free Software 17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA 18 */ 19 20 // generated automatically - do not change 21 // find conversion definition on APILookup.txt 22 // implement new conversion functionalities on the wrap.utils pakage 23 24 25 module gst.mpegts.AtscSTT; 26 27 private import glib.ConstructionException; 28 private import glib.MemorySlice; 29 private import glib.PtrArray; 30 private import gobject.ObjectG; 31 private import gst.mpegts.c.functions; 32 public import gst.mpegts.c.types; 33 private import gstreamer.DateTime; 34 private import gtkd.Loader; 35 36 37 /** 38 * System Time Table (A65) 39 */ 40 public final class AtscSTT 41 { 42 /** the main Gtk struct */ 43 protected GstMpegtsAtscSTT* gstMpegtsAtscSTT; 44 protected bool ownedRef; 45 46 /** Get the main Gtk struct */ 47 public GstMpegtsAtscSTT* getAtscSTTStruct(bool transferOwnership = false) 48 { 49 if (transferOwnership) 50 ownedRef = false; 51 return gstMpegtsAtscSTT; 52 } 53 54 /** the main Gtk struct as a void* */ 55 protected void* getStruct() 56 { 57 return cast(void*)gstMpegtsAtscSTT; 58 } 59 60 /** 61 * Sets our main struct and passes it to the parent class. 62 */ 63 public this (GstMpegtsAtscSTT* gstMpegtsAtscSTT, bool ownedRef = false) 64 { 65 this.gstMpegtsAtscSTT = gstMpegtsAtscSTT; 66 this.ownedRef = ownedRef; 67 } 68 69 ~this () 70 { 71 if ( Linker.isLoaded(LIBRARY_GSTMPEGTS) && ownedRef ) 72 sliceFree(gstMpegtsAtscSTT); 73 } 74 75 76 /** 77 * The protocol version 78 */ 79 public @property ubyte protocolVersion() 80 { 81 return gstMpegtsAtscSTT.protocolVersion; 82 } 83 84 /** Ditto */ 85 public @property void protocolVersion(ubyte value) 86 { 87 gstMpegtsAtscSTT.protocolVersion = value; 88 } 89 90 /** 91 * The system time 92 */ 93 public @property uint systemTime() 94 { 95 return gstMpegtsAtscSTT.systemTime; 96 } 97 98 /** Ditto */ 99 public @property void systemTime(uint value) 100 { 101 gstMpegtsAtscSTT.systemTime = value; 102 } 103 104 /** 105 * The GPS to UTC offset 106 */ 107 public @property ubyte gpsUtcOffset() 108 { 109 return gstMpegtsAtscSTT.gpsUtcOffset; 110 } 111 112 /** Ditto */ 113 public @property void gpsUtcOffset(ubyte value) 114 { 115 gstMpegtsAtscSTT.gpsUtcOffset = value; 116 } 117 118 /** */ 119 public @property bool dsStatus() 120 { 121 return gstMpegtsAtscSTT.dsStatus != 0; 122 } 123 124 /** Ditto */ 125 public @property void dsStatus(bool value) 126 { 127 gstMpegtsAtscSTT.dsStatus = value; 128 } 129 130 /** 131 * The day of month 132 */ 133 public @property ubyte dsDayofmonth() 134 { 135 return gstMpegtsAtscSTT.dsDayofmonth; 136 } 137 138 /** Ditto */ 139 public @property void dsDayofmonth(ubyte value) 140 { 141 gstMpegtsAtscSTT.dsDayofmonth = value; 142 } 143 144 /** 145 * The hour 146 */ 147 public @property ubyte dsHour() 148 { 149 return gstMpegtsAtscSTT.dsHour; 150 } 151 152 /** Ditto */ 153 public @property void dsHour(ubyte value) 154 { 155 gstMpegtsAtscSTT.dsHour = value; 156 } 157 158 /** 159 * descriptors 160 */ 161 public @property PtrArray descriptors() 162 { 163 return new PtrArray(gstMpegtsAtscSTT.descriptors, false); 164 } 165 166 /** Ditto */ 167 public @property void descriptors(PtrArray value) 168 { 169 gstMpegtsAtscSTT.descriptors = value.getPtrArrayStruct(); 170 } 171 172 /** 173 * The UTC date and time 174 */ 175 public @property DateTime utcDatetime() 176 { 177 return ObjectG.getDObject!(DateTime)(gstMpegtsAtscSTT.utcDatetime, false); 178 } 179 180 /** Ditto */ 181 public @property void utcDatetime(DateTime value) 182 { 183 gstMpegtsAtscSTT.utcDatetime = value.getDateTimeStruct(); 184 } 185 186 /** */ 187 public static GType getType() 188 { 189 return gst_mpegts_atsc_stt_get_type(); 190 } 191 192 /** */ 193 public this() 194 { 195 auto __p = gst_mpegts_atsc_stt_new(); 196 197 if(__p is null) 198 { 199 throw new ConstructionException("null returned by new"); 200 } 201 202 this(cast(GstMpegtsAtscSTT*) __p); 203 } 204 205 /** */ 206 public DateTime getDatetimeUtc() 207 { 208 auto __p = gst_mpegts_atsc_stt_get_datetime_utc(gstMpegtsAtscSTT); 209 210 if(__p is null) 211 { 212 return null; 213 } 214 215 return ObjectG.getDObject!(DateTime)(cast(GstDateTime*) __p, true); 216 } 217 }