Inheritance: Dogen.TestModels.CSharpModel.Base
Exemple #1
0
        static internal Descendant2 Create(uint position)
        {
            var result = new Descendant2();

            Populate(result, position);
            return(result);
        }
        internal static void Dump(AssistantDumper assistant, Descendant2 value, bool withSeparator = false)
        {
            assistant.IncrementDepth();
            if (assistant.MaximumDepthExceeded())
                return;

            assistant.AddStartObject();
            assistant.AddType("Dogen.TestModels.CSharpModel.Descendant2", true/*withSeparator*/);
            if (value == null)
            {
                assistant.Add("data", "<null>");
                assistant.AddEndObject();
                return;
            }

            assistant.AddKey("data");
            assistant.AddPairSeparator();
            assistant.AddStartObject();
            assistant.AddKey("__parent_0__");
            assistant.AddPairSeparator();
            Dogen.TestModels.CSharpModel.BaseDumper.Dump(assistant, value, true/*withSeparator*/);
            assistant.Add("Prop0", value.Prop0);
            assistant.AddEndObject(); // data
            assistant.AddEndObject(); // main object
            assistant.HandleMemberSeparator(withSeparator);

            assistant.DecrementDepth();
        }
Exemple #3
0
        public static string Dump(Descendant2 value)
        {
            var assistant = new AssistantDumper();

            Dump(assistant, value);
            return(assistant.ToString());
        }
Exemple #4
0
        static internal void Dump(AssistantDumper assistant, Descendant2 value, bool withSeparator = false)
        {
            assistant.IncrementDepth();
            if (assistant.MaximumDepthExceeded())
            {
                return;
            }

            assistant.AddStartObject();
            assistant.AddType("Dogen.TestModels.CSharpModel.Descendant2", true /*withSeparator*/);
            if (value == null)
            {
                assistant.Add("data", "<null>");
                assistant.AddEndObject();
                return;
            }

            assistant.AddKey("data");
            assistant.AddPairSeparator();
            assistant.AddStartObject();
            assistant.AddKey("__parent_0__");
            assistant.AddPairSeparator();
            Dogen.TestModels.CSharpModel.BaseDumper.Dump(assistant, value, true /*withSeparator*/);
            assistant.Add("Prop0", value.Prop0);
            assistant.AddEndObject(); // data
            assistant.AddEndObject(); // main object
            assistant.HandleMemberSeparator(withSeparator);

            assistant.DecrementDepth();
        }
Exemple #5
0
 static internal void Populate(Descendant2 value, uint position)
 {
     Dogen.TestModels.CSharpModel.BaseSequenceGenerator.Populate(value, position);
     value.Prop0 = AssistantSequenceGenerator.CreateInt(position + 0);
 }
 public static string Dump(Descendant2 value)
 {
     var assistant = new AssistantDumper();
     Dump(assistant, value);
     return assistant.ToString();
 }