Progressive Dump
While a linq query is going on, I would like to dump the values, but part of the same Dump... if that makes sense. I use LINQPad to handle small menial tasks I don't feel like starting a new VS project for.
So while I am in a long linq query, I would like another method for DumpToExisting([id]) and Dump() should return a GUID or Integer id.
-
Alexander Krivács Schrøder commented
Or, to relate it to another feature already present in LINQPad, something like the Util.Progressbar (which can be updated as the query runs), but much more generic.
-
Alexander Krivács Schrøder commented
I really wanted this feature today as well. I have a WCF service that I'm connecting to and receiving data from, and instead of having to dump every received message (which are of different types) in a random order, it'd be nice to be able to gather them into their own section.
My idea:
var type1s = Util.CreateDumpSection().Dump("Type 1");
var type2s = Util.CreateDumpSection().Dump("Type 2");
var type3s = Util.CreateDumpSection().Dump("Type 3");which would make three "live" sections into which you could dump data, e.g.:
type1s.Add(someObject);
This would have the same effect as someObject.Dump(), but would be appended to the type1s section instead of the bottom of the result pane.
-
Anders Lyman commented
I would like this too - rather than:
foo.Dump();
// Add item to foo collection
foo.Dump();
// Add item to foo collection
foo.Dump();Which would dump three objects to the console, you could do:
var dumpId = foo.Dump();
// Add item to foo collection
foo.DumpToExisting(dumpId);
// Add item to foo collection
foo.DumpToExisting(dumpId);And that would simply replace the existing dump.
-
Can you clarity?