MCPcopy Create free account
hub / github.com/StereoKit/StereoKit / ParseModules

Method ParseModules

tools/StereoKitAPIGen/CSharp/BindCSharp.cs:192–210  ·  view source on GitHub ↗
(CppCompilation ast)

Source from the content-addressed store, hash-verified

190 ///////////////////////////////////////////
191
192 static List<CSModule> ParseModules(CppCompilation ast)
193 {
194 Dictionary<string, CSModule> modules = new Dictionary<string, CSModule>();
195
196 foreach (var f in ast.Functions)
197 {
198 string[] words = f.Name.Split('_');
199 CSModule mod = null;
200 if (!modules.TryGetValue(words[0], out mod))
201 {
202 mod = new CSModule(words[0]);
203 modules.Add(words[0], mod);
204 }
205
206 mod.AddFunction(f);
207 }
208
209 return new List<CSModule>(modules.Values);
210 }
211}

Callers

nothing calls this directly

Calls 2

AddFunctionMethod · 0.80
AddMethod · 0.45

Tested by

no test coverage detected