public IEnumerable<TreeNodeData> Create(TreeNodeDataProviderContext context) {
			var fileNode = context.Owner.Data as DsDocumentNode;
			Debug.Assert(fileNode != null);
			if (fileNode == null)
				yield break;

			bool hasPENode = HasPENode(fileNode);
			var peImage = fileNode.Document.PEImage;
			Debug.Assert(!hasPENode || peImage != null);
			if (hasPENode && peImage != null)
				yield return new PENode(hexBufferService.Value, peImage, fileNode.Document.ModuleDef as ModuleDefMD);
		}
Beispiel #2
0
		internal void AddChildren(TreeNodeImpl impl) {
			foreach (var data in impl.Data.CreateChildren())
				AddSorted(impl, Create(data));
			foreach (var provider in treeViewService.GetProviders(impl.Data.Guid)) {
				var context = new TreeNodeDataProviderContext(impl);
				foreach (var data in provider.Create(context))
					AddSorted(impl, Create(data));
			}
		}