public static string DisplayValue(object obj, int depthLimit, int currentDepth) { var itemMetadata = TypeMetadataProviderBase.GetMetadataProvider(obj); if (itemMetadata.IsPrimitiveElement || depthLimit == currentDepth) { return(GetDisplayValue(obj)); } currentDepth++; var renderer = FragmentBase.GetFragment(itemMetadata); return(renderer.Render(depthLimit, currentDepth)); }
public static object DumpSort <T>(this T obj, int depth) { var metaData = TypeMetadataProviderBase.GetMetadataProvider(obj); var renderer = FragmentBase.GetFragment(metaData); Renderers.Add(() => renderer.Render(depth)); if (webBrowser == null) { webBrowser = new WebBrowser(); PanelManager.DisplayWpfElement(webBrowser, PanelName); PanelManager.GetOutputPanel(PanelName).QueryEnded += OnQueryEnded; } return(obj); }