Esempio n. 1
0
 public override void DumpTree(System.Xml.XmlWriter xml)
 {
     xml.WriteStartElement("ArrayBrace");
     xml.WriteAttributeString("open", _open.ToString());
     xml.WriteAttributeString("span", Span.ToString());
     xml.WriteEndElement();
 }
Esempio n. 2
0
        public override void Graph(System.Xml.XmlWriter s, object o, DatatypeFormatterGraphResult result)
        {
            // Represent the ST as an ED and serialize the ED
            base.Graph(s, o, result);
            
            ST instance = o as ST;

            // Get rid of these attributes
            if (result.CompatibilityMode != DatatypeFormatterCompatibilityMode.ClinicalDocumentArchitecture)
            {
                // In R1 data types an ST is a restriction of an ED with these attributes fixed
                s.WriteAttributeString("mediaType", "text/plain");
                s.WriteAttributeString("representation", "TXT");
            }

            // Language
            if (instance.Language != null)
                s.WriteAttributeString("language", instance.Language);
            
            // Content
            s.WriteString(instance.Value);

            // Translation
            if (instance.Translation != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "Translation", "ST", s.ToString()));
            
        }
Esempio n. 3
0
 /// <summary>
 /// Method to save the CheckpointTile in a .xml file
 /// </summary>
 /// <param name="xmlw">XmlWriter.</param>
 public override void Save(System.Xml.XmlWriter xmlw)
 {
     xmlw.WriteStartElement("CheckpointTile");
     xmlw.WriteAttributeString("visited", _visited.ToString());
     xmlw.WriteAttributeString("bonuslife", _bonuslife.ToString());
     xmlw.WriteEndElement();
 }
Esempio n. 4
0
 public override void WriteXml(System.Xml.XmlWriter writer)
 {
     base.WriteXml(writer);
     writer.WriteAttributeString("X", X.Text);
     writer.WriteAttributeString("Y", Y.Text);
     writer.WriteAttributeString("R", R.Text);
 }
 protected override void WriteXmlInternal(System.Xml.XmlWriter writer)
 {
     writer.WriteStartElement("authentication");
     writer.WriteAttributeString("password", password);
     writer.WriteAttributeString("username", username);
     writer.WriteEndElement();
 }
Esempio n. 6
0
        public new void WriteXml(System.Xml.XmlWriter writer)
        {
            writer.WriteAttributeString(PlaceholderAttributes.AcceptsItems.ToString(), AcceptsItems);
            writer.WriteAttributeString(PlaceholderAttributes.PlaceholderBehaviour.ToString(), PlaceholderBehaviour);

            base.WriteXml(writer);
        }
Esempio n. 7
0
 public void WriteXml(System.Xml.XmlWriter writer)
 {
     if (Minimum != 0 && Maximum != 0) {
         writer.WriteAttributeString("Minimum", Minimum);
         writer.WriteAttributeString("Maximum", Maximum);
     }
 }
Esempio n. 8
0
        /// <summary>
        /// Graph <paramref name="o"/> onto <paramref name="s"/>
        /// </summary>
        public void Graph(System.Xml.XmlWriter s, object o, DatatypeR2FormatterGraphResult result)
        {
            ANYFormatter baseFormatter = new ANYFormatter();

            // Graph 
            baseFormatter.Graph(s, o, result);

            // Null ?
            IAny anyInstance = o as IAny;
            TEL tel = o as TEL;

            // Null flavor
            if (anyInstance.NullFlavor != null)
                return;

            // Format attributes
            if (tel.Value != null) // Value
                s.WriteAttributeString("value", tel.Value);
            if (tel.Use != null) // Use
                s.WriteAttributeString("use", Util.ToWireFormat(tel.Use));
            if (tel.Capabilities != null) // Capabilities
                s.WriteAttributeString("capabilities", Util.ToWireFormat(tel.Capabilities));
            
            // format elements
            if (tel.UseablePeriod != null)
            {
                s.WriteStartElement("useablePeriod", "urn:hl7-org:v3");
                var hostResult = this.Host.Graph(s, tel.UseablePeriod);
                result.AddResultDetail(hostResult.Details);
                s.WriteEndElement();
            }

        }
Esempio n. 9
0
        /// <summary>
        /// Grap the object to a stream
        /// </summary>
        public override void Graph(System.Xml.XmlWriter s, object o, DatatypeFormatterGraphResult result)
        {

            ENXP instance = o as ENXP;

            // Start with part type and code attributes
            base.Graph(s, o, result);

            if (instance.NullFlavor != null)
                return;
            
            // Now format our data
            if (instance.Type != null && result.CompatibilityMode != DatatypeFormatterCompatibilityMode.ClinicalDocumentArchitecture)
                s.WriteAttributeString("partType", Util.ToWireFormat(instance.Type));
            if (instance.Qualifier != null && !instance.Qualifier.IsEmpty)
                s.WriteAttributeString("qualifier", Util.ToWireFormat(instance.Qualifier));
            if (instance.Code != null && result.CompatibilityMode != DatatypeFormatterCompatibilityMode.Canadian)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "Code", "ENXP", s.ToString()));
            else if(instance.Code != null)
                s.WriteAttributeString("code", instance.Code);
            if (instance.Value != null)
                s.WriteValue(instance.Value);
            if (instance.CodeSystem != null) // Warn if there is no way to represent this in R1
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "CodeSystem", "ENXP", s.ToString()));
            if(instance.CodeSystemVersion != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "CodeSystemVersion", "ENXP", s.ToString()));

        }
Esempio n. 10
0
        public override void Graph(System.Xml.XmlWriter s, object o, DatatypeFormatterGraphResult result)
        {
            // Want to control the output of value
            ANYFormatter baseFormatter = new ANYFormatter();

            baseFormatter.Graph(s, o, result);
            MO instance = o as MO;

            if (instance.NullFlavor != null) return; // Don't graph anymore

            if (instance.Expression != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "Expression", "PQ", s.ToString()));
            if (instance.OriginalText != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "OriginalText", "PQ", s.ToString()));
            if (instance.Uncertainty != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "Uncertainty", "PQ", s.ToString()));
            if (instance.UncertaintyType != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "UncertaintyType", "PQ", s.ToString()));
            if (instance.UncertainRange != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "UncertainRange", "PQ", s.ToString()));
            if (instance.Currency != null)
                s.WriteAttributeString("currency", instance.Currency);

            // Precision
            if (instance.Precision != null && instance.Precision != 0 && instance.Value.HasValue)
                s.WriteAttributeString("value", instance.Value.Value.ToString(String.Format("0.{0}", new String('0', instance.Precision), DatatypeFormatter.FormatterCulture.NumberFormat.NumberDecimalSeparator), DatatypeFormatter.FormatterCulture));
            else if (instance.Value.HasValue)
                s.WriteAttributeString("value", instance.Value.Value.ToString(DatatypeFormatter.FormatterCulture));

            
        }
Esempio n. 11
0
 public void Save(System.Xml.XmlWriter w)
 {
     w.WriteStartElement ("edge");
     w.WriteAttributeString ("to", To.Id.ToString());
     w.WriteAttributeString ("weight", Weight.ToString());
     w.WriteEndElement ();
 }
        /// <summary>
        /// Outputs content into XmlWriter
        /// </summary>
        /// <param name="xWriter">XmlWriter to render</param>
        protected override void RenderContent(System.Xml.XmlWriter xWriter)
        {
            xWriter.WriteStartElement("event");
            //id
            if (!string.IsNullOrEmpty(this.ID))
                xWriter.WriteAttributeString("id", this.ID);
            //custom attribs
            foreach (KeyValuePair<string, string> entry in this.CustomAttribs)
                xWriter.WriteAttributeString(entry.Key, entry.Value);
            //start date
            xWriter.WriteStartElement("start_date");
            if (this.StartDate.HasValue)
                xWriter.WriteCData(this.StartDate.Value.ToString(Tools.DateFormat));
            xWriter.WriteEndElement();
            //end_date
            xWriter.WriteStartElement("end_date");
            if (this.FinishDate.HasValue)
                xWriter.WriteCData(this.FinishDate.Value.ToString(Tools.DateFormat));
            xWriter.WriteEndElement();
            
            //details fields
            foreach (string fieldName in this.DataFields.Keys)
            {
                xWriter.WriteStartElement(fieldName);
                xWriter.WriteCData(this.DataFields[fieldName]);
                xWriter.WriteEndElement();
            }

            xWriter.WriteEndElement();
        }
Esempio n. 13
0
        /// <summary>
        /// Graphs <paramref name="o"/> onto <paramref name="s"/> storing result
        /// in <paramref name="result"/>
        /// </summary>
        public void Graph(System.Xml.XmlWriter s, object o, DatatypeR2FormatterGraphResult result)
        {
            // Get a strongly typed instance of o
            PQ opq = o as PQ;

            // Output additional attributes
            // Since a PQ with null flavor derived can still have a unit 
            // we only want to check for null flavors not derived
            if (opq.NullFlavor == null || opq.NullFlavor.Equals(NullFlavor.Derived))
            {
                if (opq.Unit != null)
                    s.WriteAttributeString("unit", Util.ToWireFormat(opq.Unit));
                if (opq.CodingRationale != null)
                    s.WriteAttributeString("codingRationale", Util.ToWireFormat(opq.CodingRationale));
            }

            // Output the PDV and QTY formatter helper data
            PDVFormatter pdvFormatter = new PDVFormatter();
            pdvFormatter.Host = this.Host;
            pdvFormatter.Graph(s, o, result);

            // Output the translations (if they exist)
            if(opq.Translation != null && (opq.NullFlavor == null || opq.NullFlavor.Equals(NullFlavor.Derived)))
                foreach (var trans in opq.Translation)
                {
                    s.WriteStartElement("translation", "urn:hl7-org:v3");
                    
                    // Graph
                    var hostResult = this.Host.Graph(s, trans);
                    result.Code = hostResult.Code;
                    result.AddResultDetail(hostResult.Details);
                    
                    s.WriteEndElement();
                }
        }
Esempio n. 14
0
        /// <summary>
        /// Graph the object <paramref name="o"/> onto stream <paramref name="s"/>
        /// </summary>
        /// <param name="s">The XmlWriter to graph object to</param>
        /// <param name="o">The object to graph</param>
        public override void Graph(System.Xml.XmlWriter s, object o, DatatypeFormatterGraphResult result)
        {
            // Get an instance ref
            TEL instance_tel = (TEL)o;

            // Do a base format
            base.Graph(s, o, result);

            // Null flavor
            if (((ANY)o).NullFlavor != null)
                return;

            // Attributes
            if (instance_tel.Value != null)
                s.WriteAttributeString("value", instance_tel.Value);
            if (instance_tel.Use != null && instance_tel.Use.Items != null
                && instance_tel.Use.Items.Count > 0)
                s.WriteAttributeString("use", Util.ToWireFormat(instance_tel.Use));
            if (instance_tel.Capabilities != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(
                    ResultDetailType.Warning, "Capabilities", "TEL", s.ToString()));

            // Elements
            if (instance_tel.UseablePeriod != null)
            {
                s.WriteStartElement("useablePeriod", "urn:hl7-org:v3");
                GTSFormatter formatterHelper = new GTSFormatter();
                formatterHelper.Host = this.Host;
                formatterHelper.Graph(s, instance_tel.UseablePeriod, result);
                s.WriteEndElement(); // usable period
            }
             
        }
Esempio n. 15
0
 public void WriteXml(System.Xml.XmlWriter writer)
 {
     writer.WriteAttributeString("ServerAddress", this.ServerAddress.ToString());
     writer.WriteAttributeString("IsValidAddress", this.IsValidAddress.ToString());
     writer.WriteAttributeString("UserName", this.UserName);
     writer.WriteAttributeString("HasEnabledMultiplayer", this.HasEnabledMultiplayer.ToString());
 }
Esempio n. 16
0
 protected override void WriteXmlInternal(System.Xml.XmlWriter writer)
 {
     writer.WriteStartElement("action");
     writer.WriteAttributeString("type", actionType);
     writer.WriteAttributeString("param", actionParam);
     writer.WriteEndElement();
 }
        /// <summary>
        /// Ouputs content to response
        /// </summary>
        /// <param name="xWriter">XmlWriter object to render content to</param>
        protected override void RenderContent(System.Xml.XmlWriter xWriter)
        {
            xWriter.WriteStartElement("row");
            if (!string.IsNullOrEmpty(this.ID))
                xWriter.WriteAttributeString("id", this.ID);

            if (this.HasChildren)
                xWriter.WriteAttributeString("xmlkids", "1");
            
            //write custom attribs
            foreach (KeyValuePair<string, string> pair in this.CustomAttribs)
                xWriter.WriteAttributeString(pair.Key, pair.Value);

            int cellIndex = 0;
            foreach (KeyValuePair<string, string> pair in this.DataFields)
                if (!this.ExtraColumnNames.Contains(pair.Key))
                {
                    xWriter.WriteStartElement("cell");
                    if (cellIndex == 0 && !string.IsNullOrEmpty(this.Image))
                        xWriter.WriteAttributeString("image", this.Image);
                    xWriter.WriteCData(pair.Value);
                    xWriter.WriteEndElement();
                    cellIndex++;
                }

            foreach (dhtmlxTreeGridDataItem childItem in this.ChildRows)
                childItem.Render(xWriter);

            xWriter.WriteEndElement();
        }
Esempio n. 18
0
        /// <summary>
        /// Graph object <paramref name="o"/> onto stream <paramref name="s"/>
        /// </summary>
        /// <param name="s">The XmlWriter to graph to</param>
        /// <param name="o">The object to graph</param>
        public override void Graph(System.Xml.XmlWriter s, object o, DatatypeFormatterGraphResult result)
        {
            // Get an instance ref
            ICodedValue instance_ics = (ICodedValue)o;

            // Do a base format
            base.Graph(s, o, result);

            // Format the coded simple
            if (instance_ics.CodeSystem != null) 
                s.WriteAttributeString("codeSystem", instance_ics.CodeSystem);
            if (instance_ics.CodeSystemName != null)
                s.WriteAttributeString("codeSystemName", instance_ics.CodeSystemName);
            if (instance_ics.CodeSystemVersion != null)
                s.WriteAttributeString("codeSystemVersion", instance_ics.CodeSystemVersion);
            if (instance_ics.DisplayName != null)
                s.WriteAttributeString("displayName", instance_ics.DisplayName);
            if (instance_ics.OriginalText != null) // Original Text
            {
                EDFormatter edFormatter = new EDFormatter();
                s.WriteStartElement("originalText", "urn:hl7-org:v3");
                edFormatter.Graph(s, instance_ics.OriginalText, result);
                s.WriteEndElement();
            }
            if (!String.IsNullOrEmpty(instance_ics.ValueSet))
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "ValueSet", "CV", s.ToString()));
            if (!String.IsNullOrEmpty(instance_ics.ValueSetVersion))
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "ValueSetVersion", "CV", s.ToString()));


        }
Esempio n. 19
0
        /// <summary>
        /// Chart 설정 또는 변량에 대해 XML 속성으로 생성합니다.
        /// </summary>
        /// <param name="writer">xml writer</param>
        public override void GenerateXmlAttributes(System.Xml.XmlWriter writer) {
            base.GenerateXmlAttributes(writer);

            if(NumDivLines.HasValue)
                writer.WriteAttributeString("numDivLines", NumDivLines.ToString());

            if(_divLineAttr != null)
                _divLineAttr.GenerateXmlAttributes(writer);

            if(_zeroPlaneAttr != null)
                _zeroPlaneAttr.GenerateXmlAttributes(writer);

            if(NumVDivLines.HasValue)
                writer.WriteAttributeString("numVDivLines", NumVDivLines.ToString());

            if(_vDivLine != null)
                _vDivLine.GenerateXmlAttributes(writer);

            if(_alternateHGridAttr != null)
                _alternateHGridAttr.GenerateXmlAttributes(writer);

            if(_alternateVGridAttr != null)
                _alternateVGridAttr.GenerateXmlAttributes(writer);

            if(DivLineEffect.HasValue)
                writer.WriteAttributeString("divLineEffect", DivLineEffect.ToString().ToUpper());
        }
Esempio n. 20
0
        /// <summary>
        /// Chart 설정 또는 변량에 대해 XML로 생성합니다.
        /// </summary>
        /// <param name="writer">xml writer</param>
        public override void GenerateXmlAttributes(System.Xml.XmlWriter writer) {
            base.GenerateXmlAttributes(writer);

            if(UseMessageLog.HasValue)
                writer.WriteAttributeString("UseMessageLog", UseMessageLog.Value.GetHashCode().ToString());
            if(WPercent.HasValue)
                writer.WriteAttributeString("WPercent", WPercent.Value.ToString());
            if(HPercent.HasValue)
                writer.WriteAttributeString("HPercent", HPercent.Value.ToString());

            if(ShowTitle.HasValue)
                writer.WriteAttributeString("ShowTitle", ShowTitle.Value.GetHashCode().ToString());
            if(Title.IsNotWhiteSpace())
                writer.WriteAttributeString("Title", Title);
            if(Color.HasValue)
                writer.WriteAttributeString("Color", Color.Value.ToHexString());

            if(MessageGoesToLog.HasValue)
                writer.WriteAttributeString("MessageGoesToLog", MessageGoesToLog.Value.GetHashCode().ToString());
            if(MessageGoesToJS.HasValue)
                writer.WriteAttributeString("MessageGoesToJS", MessageGoesToJS.Value.GetHashCode().ToString());
            if(MessageJSHandler.IsNotWhiteSpace())
                writer.WriteAttributeString("MessageJSHandler", MessageJSHandler);
            if(MessagePassAllToJS.HasValue)
                writer.WriteAttributeString("MessagePassAllToJS", MessagePassAllToJS.Value.GetHashCode().ToString());
        }
Esempio n. 21
0
        /// <summary>
        /// Graph <paramref name="o"/> onto <paramref name="s"/>
        /// </summary>
        /// <param name="s">The stream to graph to</param>
        /// <param name="o">The object to graph</param>
        public override void Graph(System.Xml.XmlWriter s, object o, DatatypeFormatterGraphResult result)
        {
		// We don't use base.graph() here because we want to control the value property
            ANYFormatter baseFormatter = new ANYFormatter();

            baseFormatter.Graph(s, o, result);
            REAL instance = o as REAL;

            if (instance.NullFlavor != null) return; // Don't graph anymore

            // Precision
            if (instance.Value.HasValue && instance.Precision != 0)
                s.WriteAttributeString("value", instance.Value.Value.ToString(String.Format("0.{0}", new String('0', instance.Precision), DatatypeFormatter.FormatterCulture.NumberFormat.NumberDecimalSeparator), DatatypeFormatter.FormatterCulture));
            else if (instance.Value.HasValue)
                s.WriteAttributeString("value", instance.Value.Value.ToString(DatatypeFormatter.FormatterCulture));

            // Unsupported properties
            if (instance.Expression != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "Expression", "REAL", s.ToString()));
            if (instance.OriginalText != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "OriginalText", "REAL", s.ToString()));
            if (instance.Uncertainty != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "Uncertainty", "REAL", s.ToString()));
            if (instance.UncertaintyType != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "UncertaintyType", "REAL", s.ToString()));
            if (instance.UncertainRange != null)
                result.AddResultDetail(new UnsupportedDatatypeR1PropertyResultDetail(ResultDetailType.Warning, "UncertainRange", "REAL", s.ToString()));

             
        }
Esempio n. 22
0
 public override void DumpTree(System.Xml.XmlWriter xml)
 {
     xml.WriteStartElement("Include");
     xml.WriteAttributeString("fileName", _fileName);
     xml.WriteAttributeString("span", Span.ToString());
     xml.WriteEndElement();
 }
Esempio n. 23
0
        /// <summary>
        /// Graph <paramref name="o"/> onto <paramref name="s"/>
        /// </summary>
        /// <param name="s">The stream to graph to</param>
        /// <param name="o">The object to graph</param>
        public override void Graph(System.Xml.XmlWriter s, object o, DatatypeFormatterGraphResult result)
        {
            // Graph this UVP to the stream
            base.Graph(s, o, result);
            
            // Add probability 
            if ((o as ANY).NullFlavor != null)
                return; // No need for this

            object probValue = o.GetType().GetProperty("Probability").GetValue(o, null),
                valueValue = o.GetType().GetProperty("Value").GetValue(o, null);

            // Output XSI:TYPE
            // TODO: Safety check this method in the future
            s.WriteAttributeString("xsi","type", DatatypeFormatter.NS_XSI, Util.CreateXSITypeName(o.GetType()));

            if (probValue != null)
                s.WriteAttributeString("probability", Util.ToWireFormat(probValue));
            
            // Graph the value
            ANY anyValue = valueValue as ANY;
            if (anyValue == null)
                return;

            var hostResult = this.Host.Graph(s, anyValue);
            result.Code = hostResult.Code;
            result.AddResultDetail(hostResult.Details);

        }
Esempio n. 24
0
        /// <summary>
        /// Graph object <paramref name="o"/> onto stream <paramref name="s"/>
        /// </summary>
        public override void Graph(System.Xml.XmlWriter s, object o, DatatypeFormatterGraphResult result)
        {
            Type sxprType = typeof(SXPR<>);
            Type sxprGenericType = sxprType.MakeGenericType(GenericArguments);

            // Format the base type
            base.Graph(s, o, result);

            // Was a nullflavor present
            if ((o as ANY).NullFlavor != null)
                return;

            // Current path
            string currentPath = s is XmlStateWriter ? (s as XmlStateWriter).CurrentPath : "NA";

            // Graph the operator
            PropertyInfo operatorProperty = sxprGenericType.GetProperty("Operator"),
                componentProperty = sxprGenericType.GetProperty("Terms");
            SetOperator? operatorValue = (SetOperator?)operatorProperty.GetValue(o, null);
            IEnumerable componentValue = (IEnumerable)componentProperty.GetValue(o, null);

            // Write the operator out
            if (operatorValue != null)
                s.WriteAttributeString("operator", Util.ToWireFormat(operatorValue));

            // Elements
            if (componentValue != null)
            {
                int count = 0;
                foreach (var component in componentValue)
                {
                    s.WriteStartElement("comp", "urn:hl7-org:v3");
                    object value = component;
                    var compType = component.GetType();

                    string xsiTypeName = Util.CreateXSITypeName(compType);

                    // Write the type
                    if (this.Host.Host == null)
                        s.WriteAttributeString("type", DatatypeFormatter.NS_XSI, xsiTypeName.ToString());
                    else
                        s.WriteAttributeString("xsi", "type", DatatypeFormatter.NS_XSI, xsiTypeName.ToString());

                    if (count == 0) // the first element should have no operator
                    {
                        var pi = compType.GetProperty("Operator");
                        if (pi.GetValue(component, null) != null)
                            result.AddResultDetail(new ResultDetail(ResultDetailType.Warning, "Operator won't be represented in the first object in the SXPR", s.ToString(), null));
                        pi.SetValue(component, null, null);
                    }

                    var hostGraphResult = Host.Graph(s, (IGraphable)value);
                    result.AddResultDetail(hostGraphResult.Details);

                    s.WriteEndElement(); // comp
                    count++; 
                }
            }
        }
Esempio n. 25
0
            public override void GenerateXmlAttributes(System.Xml.XmlWriter writer) {
                base.GenerateXmlAttributes(writer);

                if(Value.HasValue)
                    writer.WriteAttributeString("value", Value.ToString().Substring(0, 1));
                if(Scoreless.HasValue)
                    writer.WriteAttributeString("scoreless", Scoreless.GetHashCode().ToString());
            }
Esempio n. 26
0
 public override void DumpTree(System.Xml.XmlWriter xml)
 {
     xml.WriteStartElement("FunctionCall");
     xml.WriteAttributeString("name", _nameToken.Text);
     xml.WriteAttributeString("span", Span.ToString());
     _argsToken.DumpTree(xml);
     xml.WriteEndElement();
 }
Esempio n. 27
0
 public override void WriteXml(System.Xml.XmlWriter writer)
 {
     base.WriteXml(writer);
     var coordinates = Coordinates;
     writer.WriteAttributeString("Text", Text.Replace("\n", "").Replace("\r", @"\n"));
     writer.WriteAttributeString("X", coordinates.X.ToStringInvariant());
     writer.WriteAttributeString("Y", coordinates.Y.ToStringInvariant());
 }
Esempio n. 28
0
		internal override void WriteXml(System.Xml.XmlWriter writer)
		{
            writer.WriteStartElement("Type", NodeQuery.XmlNamespace);
			writer.WriteAttributeString("nodeType", _nodeType.Name);
			if (_exactMatch)
				writer.WriteAttributeString("exactMatch", "yes");
			writer.WriteEndElement();
		}
Esempio n. 29
0
        /// <summary>
        /// 속성들을 Xml Attribute로 생성합니다.
        /// </summary>
        /// <param name="writer">Attribute를 쓸 Writer</param>
        public override void GenerateXmlAttributes(System.Xml.XmlWriter writer) {
            base.GenerateXmlAttributes(writer);

            if(Label.IsNotWhiteSpace())
                writer.WriteAttributeString("Label", Label);
            if(Color.HasValue)
                writer.WriteAttributeString("Color", Color.Value.ToHexString());
        }
Esempio n. 30
0
 public override void DumpTree(System.Xml.XmlWriter xml)
 {
     xml.WriteStartElement("ExternVar");
     if (_dataTypeToken != null) xml.WriteAttributeString("dataType", _dataTypeToken.Text);
     xml.WriteAttributeString("span", Span.ToString());
     foreach (var name in _nameTokens) name.DumpTree(xml);
     xml.WriteEndElement();
 }