ANTLR4ParseTreeVisualizer
ANTLR4ParseTreeVisualizer copied to clipboard
Allow expanding collection properties
Properties that return collections should expand to a full datagrid of those items, if they have multiple properties; or a single column if a collection of scalar values.
Each such collection should return its elements as a string[][], or perhaps a 2D array.
For WPF datagrid binding, a jagged array is probably better.
We still need to handle an infinite sequence. Perhaps a fixed limit of 100 items?
I'm not sure how to do this:
- How do we handle instances of multiple types? An
ArrayListorList<object>could contain multiple types. Even in aList<T>, there could be derived types. - The value at the property could be a never-ending sequence.
I think I will leave this for now.
Perhaps something like this:
- Create a dictionary / property bag for each element in the collection.
- Use StringValue to render the property values for each instance.
- Construct a custom type descriptor from the superset of all properties