OmarElabd / ObjectExporter

Object Exporter lets you export out an object while debugging in Visual Studio, the object can be serialized in either C#, JSON or XML.
GNU General Public License v3.0
264 stars 82 forks source link

Export Specific Properties of an Object #6

Open OmarElabd opened 9 years ago

OmarElabd commented 9 years ago

Let user chose which properties they wish to export through a nested checkbox list.

OmarElabd commented 9 years ago

Can be solved using checkbox treeview, members can be limited to a number such as 100 or it can be children can be dynamically displayed when expanded.

However for the serializers to ignore specific properties, there would need to be some sort of boolean property extension to indicate to ignore this member for serialization. Lets examine the potential ways we can do this.

  1. Extend the Expression class: Expression itself an interface, the concrete class is a COM object, not sure how I would inherit from this. more info: http://stackoverflow.com/questions/1863128/c-sharp-exposing-to-com-interface-inheritance
  2. Implement the Expression interface, use that object: Under investigation.
  3. Superclass the expression with an extended property: Would work without any issues, however recursively traversing the expression nodes and creating a superclass for each Expression instance would probably have some major performance implications. Keep in mind that this would need to be done for all the locals not just the ones a user is exporting.