Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Classes | Namespaces | Macros | Functions
dart_wrappable.h File Reference
#include "third_party/dart/runtime/include/dart_api.h"
#include "tonic/common/macros.h"
#include "tonic/converter/dart_converter.h"
#include "tonic/dart_state.h"
#include "tonic/dart_weak_persistent_value.h"
#include "tonic/dart_wrapper_info.h"
#include "tonic/logging/dart_error.h"
#include <type_traits>

Go to the source code of this file.

Classes

class  tonic::DartWrappable
 
struct  tonic::DartConverterWrappable
 
struct  tonic::DartConverter< T *, typename std::enable_if< std::is_convertible< T *, const DartWrappable * >::value >::type >
 
struct  tonic::DartConverter< PTR< T > >
 

Namespaces

namespace  tonic
 

Macros

#define DEFINE_WRAPPERTYPEINFO()
 
#define IMPLEMENT_WRAPPERTYPEINFO(LibraryName, ClassName)
 

Functions

template<typename T >
Ttonic::GetReceiver (Dart_NativeArguments args)
 

Macro Definition Documentation

◆ DEFINE_WRAPPERTYPEINFO

#define DEFINE_WRAPPERTYPEINFO ( )
Value:
public: \
const tonic::DartWrapperInfo& GetDartWrapperInfo() const override { \
return dart_wrapper_info_; \
} \
static Dart_PersistentHandle GetDartType(tonic::DartState* dart_state) { \
return GetTypeForWrapper(dart_state, dart_wrapper_info_); \
} \
\
private: \
static const tonic::DartWrapperInfo& dart_wrapper_info_
Dart_Handle Dart_PersistentHandle
Definition dart_api.h:259

Definition at line 66 of file dart_wrappable.h.

67 : \
68 const tonic::DartWrapperInfo& GetDartWrapperInfo() const override { \
69 return dart_wrapper_info_; \
70 } \
71 static Dart_PersistentHandle GetDartType(tonic::DartState* dart_state) { \
72 return GetTypeForWrapper(dart_state, dart_wrapper_info_); \
73 } \
74 \
75 private: \
76 static const tonic::DartWrapperInfo& dart_wrapper_info_

◆ IMPLEMENT_WRAPPERTYPEINFO

#define IMPLEMENT_WRAPPERTYPEINFO (   LibraryName,
  ClassName 
)
Value:
static const tonic::DartWrapperInfo \
kDartWrapperInfo_##LibraryName_##ClassName(#LibraryName, #ClassName); \
const tonic::DartWrapperInfo& ClassName::dart_wrapper_info_ = \
kDartWrapperInfo_##LibraryName_##ClassName;

Definition at line 78 of file dart_wrappable.h.