diff --git a/DecompilerNuGetDemos.workbook b/DecompilerNuGetDemos.workbook index 0161d523a..49df888ea 100644 --- a/DecompilerNuGetDemos.workbook +++ b/DecompilerNuGetDemos.workbook @@ -61,4 +61,18 @@ If you need the Cecil ModuleDefinition ```csharp ITypeDefinition type = decompiler.TypeSystem.Compilation.FindType(nameOfUniResolver).GetDefinition(); var module = decompiler.TypeSystem.GetCecil(type).Module +``` + +Get the child namespaces + +```csharp +var icsdns = decompiler.TypeSystem.Compilation.RootNamespace.ChildNamespaces.First(); +foreach (var ns in icsdns.ChildNamespaces.First().ChildNamespaces) Console.WriteLine(ns.FullName); +``` + +Get types in a single namespace + +```csharp +// ICSharpCode.Decompiler.TypeSystem is the first namespace +var typesInNamespace = icsdns.ChildNamespaces.First().ChildNamespaces.First().Types; ``` \ No newline at end of file