예제 #1
0
        internal JsonObject Serialize()
        {
            var jsonObject = new JsonObject
            {
                { "name", this.Id },
            };

            jsonObject.AddIsNotNullOrEmpty("value", this.Value);
            jsonObject.AddNonDefaultValue("overridable", this.Overridable, false);
            jsonObject.AddNonDefaultValue("ln", this.SourceLineNumbers?.Serialize());

            return(jsonObject);
        }
예제 #2
0
        internal JsonObject Serialize()
        {
            var jsonObject = new JsonObject
            {
                { "dialog", this.Dialog },
            };

            jsonObject.AddIsNotNullOrEmpty("control", this.Control);
            jsonObject.AddNonDefaultValue("x", this.X, 0);
            jsonObject.AddNonDefaultValue("y", this.Y, 0);
            jsonObject.AddNonDefaultValue("width", this.Width, 0);
            jsonObject.AddNonDefaultValue("height", this.Height, 0);
            jsonObject.AddNonDefaultValue("attribs", this.Attributes, 0);
            jsonObject.AddIsNotNullOrEmpty("text", this.Text);

            return(jsonObject);
        }
        internal JsonObject Serialize()
        {
            var jsonObject = new JsonObject
            {
                { "dialog", this.Dialog },
            };

            jsonObject.AddIsNotNullOrEmpty("control", this.Control);
            jsonObject.AddNonDefaultValue("x", this.X);
            jsonObject.AddNonDefaultValue("y", this.Y);
            jsonObject.AddNonDefaultValue("width", this.Width);
            jsonObject.AddNonDefaultValue("height", this.Height);
            jsonObject.AddNonDefaultValue("rightToLeft", this.RightToLeft);
            jsonObject.AddNonDefaultValue("rightAligned", this.RightAligned);
            jsonObject.AddNonDefaultValue("leftScroll", this.LeftScroll);
            jsonObject.AddIsNotNullOrEmpty("text", this.Text);

            return(jsonObject);
        }