Pepper_42_C++_interfaces
extension_system_samsung.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2015 Samsung Electronics, Visual Display Division.
3  * All Rights Reserved.
4  *
5  * @author Marcin Kazmierczak <m.kazmiercz2@samsung.com>
6  *
7  * Use of this source code is governed by a BSD-style license that can be
8  * found in the Chromium-LICENSE file.
9  */
10 
11 #ifndef PPAPI_CPP_SAMSUNG_EXTENSION_SYSTEM_SAMSUNG_H_
12 #define PPAPI_CPP_SAMSUNG_EXTENSION_SYSTEM_SAMSUNG_H_
13 
14 #include "ppapi/c/samsung/ppb_extension_system_samsung.h"
15 #include "ppapi/cpp/instance_handle.h"
16 #include "ppapi/cpp/var.h"
17 
18 /// @file
19 /// This file defines APIs related to extension system provided by the browser.
20 
21 namespace pp {
22 
24  public:
25  /// GetEmbedderName() returns name of the extension system provider.
26  std::string GetEmbedderName() const;
27 
28  /// GetCurrentExtensionInfo() returns information about current extension.
29  /// If browser does not support extension system, it will return undefined
30  /// value.
32 
33  /// GenericSyncCall() communicates synchronously with extension system.
34  /// The extension system will execute operation |operation_name| with provided
35  /// arguments |operation_data|. See embedder documentation to know what
36  /// operations are possible.
37  ///
38  /// @param[in] operation_name The name of operation to execute.
39  /// @param[in] operation_data Additional arguments for operation execution.
40  Var GenericSyncCall(const Var& operation_name, const Var& operation_data);
41 
42  protected:
43  /// A constructor for creating a <code>ExtensionSystemSamsung</code>.
44  ///
45  /// @param[in] instance The instance with which this resource will be
46  /// associated.
47  explicit ExtensionSystemSamsung(const InstanceHandle& instance);
48 
49  /// Destructor.
51 
52  private:
53  InstanceHandle instance_;
54 };
55 
56 } // namespace pp
57 
58 #endif // PPAPI_CPP_SAMSUNG_EXTENSION_SYSTEM_SAMSUNG_H_
~ExtensionSystemSamsung()
Destructor.
std::string GetEmbedderName() const
GetEmbedderName() returns name of the extension system provider.
ExtensionSystemSamsung(const InstanceHandle &instance)
Var GenericSyncCall(const Var &operation_name, const Var &operation_data)
A generic type used for passing data types between the module and the page.
Definition: var.h:21