Exemple #1
0
 public JsonTransformerReservedProperties(JsonTransformerReservedProperties existing)
 {
     foreach (var p in this.GetType().GetTypeInfo().DeclaredProperties)
     {
         p.SetValue(this, p.GetValue(existing));
     }
 }
Exemple #2
0
 public JsonTransformerContext(JToken rootData, Dictionary <string, JToken> additionalReservedProperties)
 {
     ReservedProperties = new JsonTransformerReservedProperties()
     {
         RootData = rootData,
         Data     = rootData,
         Index    = null,
         Props    = null,
         AdditionalReservedProperties = additionalReservedProperties ?? new Dictionary <string, JToken>()
     };
     ParentIsArray = false;
     Types         = new JsonTransformerTypes();
 }
Exemple #3
0
        public JsonTransformerContext(JsonTransformerContext existingContext)
        {
            foreach (var p in this.GetType().GetTypeInfo().DeclaredProperties)
            {
                p.SetValue(this, p.GetValue(existingContext));
            }

            if (Types != null)
            {
                Types = Types.Clone();
            }

            if (ReservedProperties != null)
            {
                ReservedProperties = new JsonTransformerReservedProperties(ReservedProperties);
            }
        }