MCPcopy Create free account
hub / github.com/arcjet/gravity / generate

Method generate

cmd/gravity/src/codegen/bindings.rs:56–60  ·  view source on GitHub ↗

Generate the bindings. This generates the imports (interfaces, types, functions), the factory and instance type, and the exports (functions).

(&mut self)

Source from the content-addressed store, hash-verified

54 /// This generates the imports (interfaces, types, functions), the factory and instance
55 /// type, and the exports (functions).
56 pub fn generate(&mut self) {
57 let (imports, chains) = self.generate_imports();
58 self.generate_factory(&imports, chains);
59 self.generate_exports(&imports.instance_name);
60 }
61
62 /// Generates the imports for the bindings.
63 fn generate_imports(&mut self) -> (AnalyzedImports, BTreeMap<String, Tokens<Go>>) {

Callers 1

mainFunction · 0.80

Calls 3

generate_importsMethod · 0.80
generate_exportsMethod · 0.80
generate_factoryMethod · 0.45

Tested by

no test coverage detected