summaryrefslogtreecommitdiff
path: root/tools/gobject.c
blob: dc5392d86011fc3c1e94603ef95a6e3d8e1e4e23 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80

% includes
% prototypes

static void gst_replace_set_property (GObject * object,
    guint property_id, const GValue * value, GParamSpec * pspec);
static void gst_replace_get_property (GObject * object,
    guint property_id, GValue * value, GParamSpec * pspec);
static void gst_replace_dispose (GObject * object);
static void gst_replace_finalize (GObject * object);

% declare-class
  GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
% set-methods
  gobject_class->set_property = gst_replace_set_property;
  gobject_class->get_property = gst_replace_get_property;
  gobject_class->dispose = gst_replace_dispose;
  gobject_class->finalize = gst_replace_finalize;
% methods

void
gst_replace_set_property (GObject * object, guint property_id,
    const GValue * value, GParamSpec * pspec)
{
  GstReplace *replace;

  g_return_if_fail (GST_IS_REPLACE (object));
  replace = GST_REPLACE (object);

  switch (property_id) {
    default:
      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
      break;
  }
}

void
gst_replace_get_property (GObject * object, guint property_id,
    GValue * value, GParamSpec * pspec)
{
  GstReplace *replace;

  g_return_if_fail (GST_IS_REPLACE (object));
  replace = GST_REPLACE (object);

  switch (property_id) {
    default:
      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
      break;
  }
}

void
gst_replace_dispose (GObject * object)
{
  GstReplace *replace;

  g_return_if_fail (GST_IS_REPLACE (object));
  replace = GST_REPLACE (object);

  /* clean up as possible.  may be called multiple times */

  G_OBJECT_CLASS (parent_class)->dispose (object);
}

void
gst_replace_finalize (GObject * object)
{
  GstReplace *replace;

  g_return_if_fail (GST_IS_REPLACE (object));
  replace = GST_REPLACE (object);

  /* clean up object here */

  G_OBJECT_CLASS (parent_class)->finalize (object);
}

% end