Flutter Engine
fl_plugin_registry.h
Go to the documentation of this file.
1 // Copyright 2013 The Flutter Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 #ifndef FLUTTER_SHELL_PLATFORM_LINUX_FL_PLUGIN_REGISTRY_H_
6 #define FLUTTER_SHELL_PLATFORM_LINUX_FL_PLUGIN_REGISTRY_H_
7 
8 #if !defined(__FLUTTER_LINUX_INSIDE__) && !defined(FLUTTER_LINUX_COMPILATION)
9 #error "Only <flutter_linux/flutter_linux.h> can be included directly."
10 #endif
11 
12 #include <glib-object.h>
13 
14 #include "fl_plugin_registrar.h"
15 
16 G_BEGIN_DECLS
17 
18 G_DECLARE_INTERFACE(FlPluginRegistry,
19  fl_plugin_registry,
20  FL,
21  PLUGIN_REGISTRY,
22  GObject)
23 
24 /**
25  * FlPluginRegistry:
26  *
27  * #FlPluginRegistry vends #FlPluginRegistrar objects for named plugins.
28  */
29 
30 struct _FlPluginRegistryInterface {
31  GTypeInterface g_iface;
32 
33  /**
34  * FlPluginRegistry::get_registrar_for_plugin:
35  * @registry: an #FlPluginRegistry.
36  * @name: plugin name.
37  *
38  * Gets the plugin registrar for the the plugin with @name.
39  *
40  * Returns: (transfer full): an #FlPluginRegistrar.
41  */
42  FlPluginRegistrar* (*get_registrar_for_plugin)(FlPluginRegistry* registry,
43  const gchar* name);
44 };
45 
46 /**
47  * fl_plugin_registry_get_registrar_for_plugin:
48  * @registry: an #FlPluginRegistry.
49  * @name: plugin name.
50  *
51  * Gets the plugin registrar for the the plugin with @name.
52  *
53  * Returns: (transfer full): an #FlPluginRegistrar.
54  */
56  FlPluginRegistry* registry,
57  const gchar* name);
58 
59 G_END_DECLS
60 
61 #endif // FLUTTER_SHELL_PLATFORM_LINUX_FL_PLUGIN_REGISTRY_H_
FlPluginRegistrar * fl_plugin_registry_get_registrar_for_plugin(FlPluginRegistry *registry, const gchar *name)
const char * name
Definition: fuchsia.cc:50
G_BEGIN_DECLS FL