System.Data.Common.CommandTrees.DbCommandTree.DumpStructure(System.Data.Common.CommandTrees.Internal.ExpressionDumper)

Here are the examples of the csharp api class System.Data.Common.CommandTrees.DbCommandTree.DumpStructure(System.Data.Common.CommandTrees.Internal.ExpressionDumper) taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.

1 Example 7

1. Example

Project: referencesource
Source File: DbCommandTree.cs
View license
internal void Dump(ExpressionDumper dumper)
        {
            //
            // Dump information about this command tree to the specified ExpressionDumper
            //
            // First dump standard information - the DataSpace of the command tree and its parameters
            //
            Dictionary<string, object> attrs = new Dictionary<string, object>();
            attrs.Add("DataSpace", this.DataSpace);
            dumper.Begin(this.GetType().Name, attrs);

            //
            // The name and type of each Parameter in turn is added to the output
            //
            dumper.Begin("Parameters", null);
            foreach (KeyValuePair<string, TypeUsage> param in this.Parameters)
            {
                Dictionary<string, object> paramAttrs = new Dictionary<string, object>();
                paramAttrs.Add("Name", param.Key);
                dumper.Begin("Parameter", paramAttrs);
                dumper.Dump(param.Value, "ParameterType");
                dumper.End("Parameter");
            }
            dumper.End("Parameters");

            //
            // Delegate to the derived type's implementation that dumps the structure of the command tree
            //
            this.DumpStructure(dumper);

            //
            // Matching call to End to correspond with the call to Begin above
            //
            dumper.End(this.GetType().Name);
        }