Groonga 3.0.9 Source Code Document
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
bench-reporter.h
Go to the documentation of this file.
1 /* -*- c-basic-offset: 2; coding: utf-8 -*- */
2 /*
3  Copyright (C) 2008 Kouhei Sutou <kou@cozmixng.org>
4 
5  This library is free software; you can redistribute it and/or
6  modify it under the terms of the GNU Lesser General Public
7  License version 2.1 as published by the Free Software Foundation.
8 
9  This library is distributed in the hope that it will be useful,
10  but WITHOUT ANY WARRANTY; without even the implied warranty of
11  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  Lesser General Public License for more details.
13 
14  You should have received a copy of the GNU Lesser General Public
15  License along with this library; if not, write to the Free Software
16  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17 */
18 
19 #ifndef __BENCH_REPORTER_H__
20 #define __BENCH_REPORTER_H__
21 
22 #include <glib-object.h>
23 
24 G_BEGIN_DECLS
25 
26 #define BENCH_TYPE_REPORTER (bench_reporter_get_type())
27 #define BENCH_REPORTER(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), BENCH_TYPE_REPORTER, BenchReporter))
28 #define BENCH_REPORTER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), BENCH_TYPE_REPORTER, BenchReporterClass))
29 #define BENCH_IS_REPORTER(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), BENCH_TYPE_REPORTER))
30 #define BENCH_IS_REPORTER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), BENCH_TYPE_REPORTER))
31 #define BENCH_REPORTER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), BENCH_TYPE_REPORTER, BenchReporterClass))
32 
35 
36 typedef void (*BenchSetupFunc) (gpointer user_data);
37 typedef void (*BenchFunc) (gpointer user_data);
38 typedef void (*BenchTeardownFunc) (gpointer user_data);
39 
41 {
42  GObject object;
43 };
44 
46 {
47  GObjectClass parent_class;
48 };
49 
50 GType bench_reporter_get_type (void) G_GNUC_CONST;
51 
54  const gchar *label,
55  gint n,
56  BenchSetupFunc bench_setup,
57  BenchFunc bench,
58  BenchTeardownFunc bench_teardown,
59  gpointer data);
60 void bench_reporter_run (BenchReporter *reporter);
61 
62 #endif /* __BENCH_REPORTER_H__ */
63 
64