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  * Conversion parameters:
26  * inFile  = gstreamer-GstParamSpec.html
27  * outPack = gstreamer
28  * outFile = ParamSpecFraction
29  * strct   = GstParamSpecFraction
30  * realStrct=
31  * ctorStrct=
32  * clss    = ParamSpecFraction
33  * interf  = 
34  * class Code: Yes
35  * interface Code: No
36  * template for:
37  * extend  = 
38  * implements:
39  * prefixes:
40  * 	- gst_param_spec_fraction_
41  * omit structs:
42  * omit prefixes:
43  * omit code:
44  * 	- gst_param_spec_fraction
45  * omit signals:
46  * imports:
47  * 	- glib.Str
48  * structWrap:
49  * module aliases:
50  * local aliases:
51  * overrides:
52  */
53 
54 module gstreamer.ParamSpecFraction;
55 
56 public  import gstreamerc.gstreamertypes;
57 
58 private import gstreamerc.gstreamer;
59 private import glib.ConstructionException;
60 private import gobject.ObjectG;
61 
62 
63 private import glib.Str;
64 
65 
66 
67 
68 /**
69  * GParamSpec implementations specific to GStreamer.
70  *
71  * Last reviewed on 2008-03-11 (0.10.18)
72  */
73 public class ParamSpecFraction
74 {
75 	
76 	/** the main Gtk struct */
77 	protected GstParamSpecFraction* gstParamSpecFraction;
78 	
79 	
80 	public GstParamSpecFraction* getParamSpecFractionStruct()
81 	{
82 		return gstParamSpecFraction;
83 	}
84 	
85 	
86 	/** the main Gtk struct as a void* */
87 	protected void* getStruct()
88 	{
89 		return cast(void*)gstParamSpecFraction;
90 	}
91 	
92 	/**
93 	 * Sets our main struct and passes it to the parent class
94 	 */
95 	public this (GstParamSpecFraction* gstParamSpecFraction)
96 	{
97 		this.gstParamSpecFraction = gstParamSpecFraction;
98 	}
99 	
100 	/**
101 	 * This function creates a fraction GParamSpec for use by objects/elements
102 	 * that want to expose properties of fraction type. This function is typically
103 	 * used in connection with g_object_class_install_property() in a GObjects's
104 	 * instance_init function.
105 	 * Params:
106 	 * name = canonical name of the property specified
107 	 * nick = nick name for the property specified
108 	 * blurb = description of the property specified
109 	 * minNum = minimum value (fraction numerator)
110 	 * minDenom = minimum value (fraction denominator)
111 	 * maxNum = maximum value (fraction numerator)
112 	 * maxDenom = maximum value (fraction denominator)
113 	 * defaultNum = default value (fraction numerator)
114 	 * defaultDenom = default value (fraction denominator)
115 	 * flags = flags for the property specified
116 	 * Returns: a newly created parameter specification. [transfer full]
117 	 */
118 	public this(string name, string nick, string blurb, int minNum, int minDenom, int maxNum, int maxDenom, int defaultNum, int defaultDenom, GParamFlags flags)
119 	{
120 		// GParamSpec * gst_param_spec_fraction (const gchar *name,  const gchar *nick,  const gchar *blurb,  gint min_num,  gint min_denom,  gint max_num,  gint max_denom,  gint default_num,  gint default_denom,  GParamFlags flags);
121 		auto p = gst_param_spec_fraction(Str.toStringz(name), Str.toStringz(nick), Str.toStringz(blurb), minNum, minDenom, maxNum, maxDenom, defaultNum, defaultDenom, flags);
122 		if(p is null)
123 		{
124 			throw new ConstructionException("null returned by gst_param_spec_fraction");
125 		}
126 		this(cast(GstParamSpecFraction*) p);
127 	}
128 	
129 	/**
130 	 */
131 }