From 21af5c2d002cfc419c2ecfd4e5bab9e812b2ef7a Mon Sep 17 00:00:00 2001 From: Cameron Taggart Date: Fri, 14 Nov 2014 10:38:44 -0800 Subject: [PATCH] #35 PdbReader getters --- SymbolStore/PdbReader.cs | 20 ++++++++++++++++---- SymbolStore/SymbolCache.cs | 2 +- 2 files changed, 17 insertions(+), 5 deletions(-) diff --git a/SymbolStore/PdbReader.cs b/SymbolStore/PdbReader.cs index 7f304b0..a0253c6 100644 --- a/SymbolStore/PdbReader.cs +++ b/SymbolStore/PdbReader.cs @@ -145,15 +145,27 @@ public byte[] GetSymAttribute(SymbolToken parent, string name) return this.symReader.GetSymAttribute(parent, name); } - public ISymbolVariable[] GetVariables(SymbolToken parent) + // explicit to see what F# does + public ISymbolDocument[] ISymbolReader.GetDocuments() { - return this.symReader.GetVariables(parent); + return this.symReader.GetDocuments(); } - public SymbolToken UserEntryPoint + // convenience getters + + public ISymbolDocument[] Documents { - get { return this.symReader.UserEntryPoint; } + get { return this.symReader.GetDocuments(); } } + public ISymbolVariable[] GlobalVariables + { + get { return this.symReader.GetGlobalVariables(); } + } + + public ISymbolNamespace[] Namespaces + { + get { return this.symReader.GetNamespaces(); } + } } } diff --git a/SymbolStore/SymbolCache.cs b/SymbolStore/SymbolCache.cs index f18115f..6bede07 100644 --- a/SymbolStore/SymbolCache.cs +++ b/SymbolStore/SymbolCache.cs @@ -15,7 +15,7 @@ public SymbolCache(string symbolCacheDir) SrcSrv.Init(sessionCookie, symbolCacheDir); } - public PdbReader ReadPdb(string filePath, Stream stream) + public PdbReader ReadPdb(Stream stream, string filePath) { return new PdbReader(stream, sessionCookie, filePath); }