v8toolkit
0.0.1
Utility library for embedding V8 Javascript engine in a c++ program
|
Go to the source code of this file.
#define __attribute__ | ( | x | ) |
Definition at line 8 of file class_parser.h.
#define V8TOOLKIT_NONE_STRING "v8toolkit_generate_bindings_none" |
Use these to expose classes/class functions/class data members via javascript
Definition at line 17 of file class_parser.h.
Referenced by get_export_type(), ClassHandler::run(), and WrappedClass::should_be_wrapped().
#define V8TOOLKIT_ALL_STRING "v8toolkit_generate_bindings_all" |
Definition at line 18 of file class_parser.h.
Referenced by get_export_type(), and WrappedClass::should_be_wrapped().
#define V8TOOLKIT_READONLY_STRING "v8toolkit_generate_bindings_readonly" |
Definition at line 19 of file class_parser.h.
Referenced by DataMember::DataMember().
#define V8TOOLKIT_EXTEND_WRAPPER_STRING "v8toolkit_extend_wrapper" |
Definition at line 20 of file class_parser.h.
Referenced by WrappedClass::parse_all_methods().
#define V8TOOLKIT_WRAPPED_CLASS __attribute__((annotate(V8TOOLKIT_ALL_STRING))) |
Generate V8ClassWrapper code for the annotated class ex: class V8TOOLKIT_WRAPPED_CLASS MyClassName {...};
Definition at line 26 of file class_parser.h.
#define V8TOOLKIT_SKIP __attribute__((annotate(V8TOOLKIT_NONE_STRING))) |
Skip an entry in a class being wrapped and/or bidirectional ex: struct V8TOOLKIT_WRAPPED_CLASS MyClassName { V8TOOLKIT_SKIP void do_not_make_binding_for_me(); };
Definition at line 33 of file class_parser.h.
Referenced by Foo::templated_function().
#define V8TOOLKIT_READONLY __attribute__((annotate(V8TOOLKIT_READONLY_STRING))) |
This member cannot be assigned to. However, it is not "const", as its contents can be changed.
Definition at line 40 of file class_parser.h.
#define V8TOOLKIT_EXTEND_WRAPPER __attribute__((annotate(V8TOOLKIT_EXTEND_WRAPPER_STRING))) |
This function should be called while creating the mapping for this class before it is finalize()'d
Definition at line 46 of file class_parser.h.
#define V8TOOLKIT_NAME_ALIAS_STRING "v8toolkit_name_alias" |
For setting a name alias to be used for javascript to refer to the type as – basically sets a different constructor name when you don't have control over the class definition Usage: using MyTypeInt V8TOOLKIT_NAME_ALIAS = MyType<int>; using MyTypeChar V8TOOLKIT_NAME_ALIAS = MyType<char>; Otherwise both of those would get the same constructor name (MyType) and code generation would fail
Definition at line 57 of file class_parser.h.
Referenced by ClassHandler::run().
#define V8TOOLKIT_NAME_ALIAS __attribute__((annotate(V8TOOLKIT_NAME_ALIAS_STRING))) |
Definition at line 58 of file class_parser.h.
#define V8TOOLKIT_USE_NAME_PREFIX "v8toolkit_use_name_" |
Overrides the default name to be the name specified instead
Definition at line 64 of file class_parser.h.
Referenced by ClassFunction::ClassFunction().
#define V8TOOLKIT_USE_NAME | ( | name | ) | __attribute__((annotate(V8TOOLKIT_USE_NAME_PREFIX #name))) |
Definition at line 65 of file class_parser.h.
#define V8TOOLKIT_EXPOSE_STATIC_METHODS_AS_PREFIX "v8toolkit_expose_static_methods_as_" |
Use this to create a JavaScript constructor function with the specified name
Definition at line 73 of file class_parser.h.
Referenced by ClassHandler::run().
#define V8TOOLKIT_EXPOSE_STATIC_METHODS_AS | ( | name | ) | __attribute__((annotate(V8TOOLKIT_EXPOSE_STATIC_METHODS_AS_PREFIX #name))) |
Definition at line 74 of file class_parser.h.
#define V8TOOLKIT_IGNORE_BASE_TYPE_PREFIX "v8toolkit_ignore_base_type_" |
For classes with multiple inheritance, allows you to specify type(s) not to use. Templates should be specified with only the base template name, not with template parameters e.g. MyTemplatedType not MyTemplatedType<int, char*> - does not support MI to select one where type inherits from two different versions of same template
Definition at line 84 of file class_parser.h.
Referenced by WrappedClass::WrappedClass().
#define V8TOOLKIT_IGNORE_BASE_TYPE | ( | name | ) | __attribute__((annotate(V8TOOLKIT_IGNORE_BASE_TYPE_PREFIX #name))) |
Definition at line 85 of file class_parser.h.
#define V8TOOLKIT_USE_BASE_TYPE_PREFIX "v8toolkit_use_base_type_" |
For classes with multiple inheritance, allows you to specify which one to use Templates should be specified with only the base template name, not with template parameters e.g. MyTemplatedType not MyTemplatedType<int, char*> - does not support MI to select one where type inherits from two different specializations of same template
Definition at line 94 of file class_parser.h.
Referenced by WrappedClass::WrappedClass().
#define V8TOOLKIT_USE_BASE_TYPE | ( | name | ) | __attribute__((annotate(V8TOOLKIT_USE_BASE_TYPE_PREFIX #name))) |
Definition at line 95 of file class_parser.h.
#define V8TOOLKIT_DO_NOT_WRAP_CONSTRUCTORS_STRING "v8toolkit_do_not_wrap_constructors" |
This can be specified in a forward declaration of a type to eliminate all constructors from being wrapped
Definition at line 102 of file class_parser.h.
Referenced by WrappedClass::parse_all_methods(), and ClassHandler::run().
#define V8TOOLKIT_DO_NOT_WRAP_CONSTRUCTORS __attribute__((annotate(V8TOOLKIT_DO_NOT_WRAP_CONSTRUCTORS_STRING))) |
Definition at line 103 of file class_parser.h.
#define V8TOOLKIT_BIDIRECTIONAL_CLASS_STRING "v8toolkit_generate_bidirectional" |
Definition at line 106 of file class_parser.h.
Referenced by ClassHandler::run(), and WrappedClass::WrappedClass().
#define V8TOOLKIT_BIDIRECTIONAL_CONSTRUCTOR_STRING "v8toolkit_generate_bidirectional_constructor" |
Definition at line 107 of file class_parser.h.
Referenced by WrappedClass::WrappedClass().
#define V8TOOLKIT_BIDIRECTIONAL_INTERNAL_PARAMETER_STRING "V8toolkit_generate_bidirectional_internal_parameter" |
Definition at line 108 of file class_parser.h.
#define V8TOOLKIT_BIDIRECTIONAL_CLASS __attribute__((annotate(V8TOOLKIT_BIDIRECTIONAL_CLASS_STRING))) |
Generate JSWrapper class for the annotated class ex: class V8TOOLKIT_BIDIRECTIONAL_CLASS MyClassName {...};
Definition at line 113 of file class_parser.h.
#define V8TOOLKIT_BIDIRECTIONAL_CONSTRUCTOR __attribute__((annotate(V8TOOLKIT_BIDIRECTIONAL_CONSTRUCTOR_STRING))) |
Annotate the constructor bidirectional should use with this
Definition at line 118 of file class_parser.h.
#define V8TOOLKIT_BIDIRECTIONAL_INTERNAL_PARAMETER __attribute__((annotate(V8TOOLKIT_BIDIRECTIONAL_INTERNAL_PARAMETER_STRING))) |
Unused, but may come back. Marks a parameter as one that is always the same, not something that will change per instance
Definition at line 124 of file class_parser.h.
#define V8TOOLKIT_CUSTOM_EXTENSION_STRING "v8toolkit_custom_extension" |
Definition at line 127 of file class_parser.h.
Referenced by WrappedClass::parse_all_methods().