e513803182cb44f3a5ec0f434b72309724d3ad8e
[platform/upstream/gstreamer.git] / validate / gst / validate / gst-validate-runner.h
1 /* GStreamer
2  * Copyright (C) 2013 Thiago Santos <thiago.sousa.santos@collabora.com>
3  *
4  * gst-validate-runner.h - Validate Runner class
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Library General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Library General Public License for more details.
15  *
16  * You should have received a copy of the GNU Library General Public
17  * License along with this library; if not, write to the
18  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19  * Boston, MA 02111-1307, USA.
20  */
21
22 #ifndef __GST_VALIDATE_RUNNER_H__
23 #define __GST_VALIDATE_RUNNER_H__
24
25 #include <glib-object.h>
26 #include <gst/gst.h>
27
28 #include <gst/gsttracer.h>
29
30 typedef struct _GstValidateRunner GstValidateRunner;
31 typedef struct _GstValidateRunnerClass GstValidateRunnerClass;
32
33 #include <gst/validate/gst-validate-report.h>
34 #include <gst/validate/gst-validate-enums.h>
35
36 G_BEGIN_DECLS
37
38 #ifndef __GI_SCANNER__
39 #define GST_TYPE_VALIDATE_RUNNER                        (gst_validate_runner_get_type ())
40 #define GST_IS_VALIDATE_RUNNER(obj)                     (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_VALIDATE_RUNNER))
41 #define GST_IS_VALIDATE_RUNNER_CLASS(klass)             (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_VALIDATE_RUNNER))
42 #define GST_VALIDATE_RUNNER_GET_CLASS(obj)              (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_VALIDATE_RUNNER, GstValidateRunnerClass))
43 #define GST_VALIDATE_RUNNER(obj)                        (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_VALIDATE_RUNNER, GstValidateRunner))
44 #define GST_VALIDATE_RUNNER_CLASS(klass)                (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_VALIDATE_RUNNER, GstValidateRunnerClass))
45 #define GST_VALIDATE_RUNNER_CAST(obj)                 ((GstValidateRunner*)(obj))
46 #define GST_VALIDATE_RUNNER_CLASS_CAST(klass)         ((GstValidateRunnerClass*)(klass))
47 #endif
48
49 typedef struct _GstValidateRunnerPrivate GstValidateRunnerPrivate;
50
51 /**
52  * GstValidateRunner:
53  *
54  * GStreamer Validate Runner class.
55  *
56  * Class that manages a Validate test run for some pipeline
57  */
58 struct _GstValidateRunner {
59   GstTracer      object;
60
61   /* <private> */
62   GstValidateRunnerPrivate *priv;
63 };
64
65 /**
66  * GstValidateRunnerClass:
67  * @parent_class: parent
68  *
69  * GStreamer Validate Runner object class.
70  */
71 struct _GstValidateRunnerClass {
72   GstTracerClass        parent_class;
73 };
74
75 /* normal GObject stuff */
76 GST_VALIDATE_API
77 GType           gst_validate_runner_get_type            (void);
78
79 GST_VALIDATE_API
80 GstValidateRunner *   gst_validate_runner_new               (void);
81
82 GST_VALIDATE_API
83 void            gst_validate_runner_add_report  (GstValidateRunner * runner, GstValidateReport * report);
84
85 GST_VALIDATE_API
86 guint           gst_validate_runner_get_reports_count (GstValidateRunner * runner);
87 GST_VALIDATE_API
88 GList *         gst_validate_runner_get_reports (GstValidateRunner * runner);
89
90 GST_VALIDATE_API
91 int             gst_validate_runner_printf (GstValidateRunner * runner);
92 GST_VALIDATE_API
93 int             gst_validate_runner_exit (GstValidateRunner * runner, gboolean print_result);
94
95 GST_VALIDATE_API
96 GstValidateReportingDetails gst_validate_runner_get_default_reporting_level (GstValidateRunner *runner);
97 GST_VALIDATE_API
98 GstValidateReportingDetails gst_validate_runner_get_reporting_level_for_name (GstValidateRunner *runner,
99                                                                             const gchar *name);
100
101 G_END_DECLS
102
103 #endif /* __GST_VALIDATE_RUNNER_H__ */
104