class

Bindgen::Parser::Document

Inherits JSON::Serializable < Reference < Object

Document as returned by the clang tool.

Constants

FORMAT_VERSION = 12

Version of the format this bindgen understands. Has to match BG_FORMAT_VERSION of the clang tool.

Constructors

new(enums : Hash(String, Bindgen::Parser::Enum) = Enum::Collection.new, classes : Hash(String, Bindgen::Parser::Class) = Class::Collection.new, macros : Array(Bindgen::Parser::Macro) = Macro::Collection.new, functions : Array(Bindgen::Parser::Method) = Method::Collection.new, format_version : Int32 = FORMAT_VERSION)

For testing purposes.

Source
new(*, __pull_for_json_serializable pull : JSON::PullParser)
Source
parse(json : String) : self

Parses the output of the clang tool. Raises if it was written in another format version: Its fields may not match, so this is checked before parsing the rest.

Source

Class methods

check_format_version!(version) : Nil

Raises if version isn't the one this bindgen understands.

Source

Instance methods

classes
Source
enums
Source
format_version

Version of the format the document was written in.

Source
functions
Source
macros
Source