Esempio n. 1
0
        private static ShowPlanElement ReadPlanElement(XPathNavigator elementNavigator)
        {
            ShowPlanOperator op = (ShowPlanOperator)Enum.Parse(typeof(ShowPlanOperator), elementNavigator.GetAttribute("operator", String.Empty));

            List <ShowPlanProperty> properties = new List <ShowPlanProperty>();

            foreach (XPathNavigator propertyNavigator in elementNavigator.Select("properties/property"))
            {
                string           propertyName  = propertyNavigator.GetAttribute("name", String.Empty);
                string           propertyValue = propertyNavigator.GetAttribute("value", String.Empty);
                ShowPlanProperty property      = new ShowPlanProperty(propertyName, propertyValue);
                properties.Add(property);
            }

            List <ShowPlanElement> children = new List <ShowPlanElement>();

            foreach (XPathNavigator childNode in elementNavigator.Select("input/*"))
            {
                ShowPlanElement childElement = ReadPlanElement(childNode);
                children.Add(childElement);
            }

            ShowPlanElement element = new ShowPlanElement(op, properties, children);

            return(element);
        }
Esempio n. 2
0
		internal ShowPlanElement(ShowPlanOperator op, IList<ShowPlanProperty> properties, IList<ShowPlanElement> children)
		{
			_operator = op;
			_properties = new ShowPlanPropertyCollection(properties);
			_children = new ShowPlanElementCollection(children);
			BuildPathElementRoot();
		}
Esempio n. 3
0
 internal ShowPlanElement(ShowPlanOperator op, IList <ShowPlanProperty> properties, IList <ShowPlanElement> children)
 {
     _operator   = op;
     _properties = new ShowPlanPropertyCollection(properties);
     _children   = new ShowPlanElementCollection(children);
     BuildPathElementRoot();
 }
Esempio n. 4
0
		internal ShowPlanElement(ShowPlanOperator op, IList<ShowPlanProperty> properties, params ShowPlanElement[] children)
			: this(op, properties, (IList<ShowPlanElement>)children)
		{
		}
Esempio n. 5
0
 internal ShowPlanElement(ShowPlanOperator op, IList <ShowPlanProperty> properties, params ShowPlanElement[] children)
     : this(op, properties, (IList <ShowPlanElement>)children)
 {
 }