public JsonSchema()

in src/Json.Schema/JsonSchema.cs [29:141]


        public JsonSchema(JsonSchema other)
        {
            if (other.Id != null)
            {
                Id = new UriOrFragment(other.Id);
            }

            if (other.SchemaVersion != null)
            {
                SchemaVersion = new Uri(other.SchemaVersion.OriginalString);
            }

            Title = other.Title;
            Description = other.Description;

            if (other.Type != null)
            {
                Type = new List<SchemaType>(other.Type);
            }

            if (other.Enum != null)
            {
                // A shallow copy is fine for now since Enum will be checked to ensure that it
                // contain only primitive types.
                // But it won't do if we want to pass the JSON Schema validation suite.
                Enum = new List<object>(other.Enum);
            }

            if (other.Items != null)
            {
                Items = new Items(other.Items);
            }

            if (other.Properties != null)
            {
                Properties = new Dictionary<string, JsonSchema>();
                foreach (string key in other.Properties.Keys)
                {
                    Properties.Add(key, new JsonSchema(other.Properties[key]));
                }
            }

            if (other.Required != null)
            {
                Required = new List<string>(other.Required);
            }

            if (other.Definitions != null)
            {
                Definitions = new Dictionary<string, JsonSchema>();
                foreach (string key in other.Definitions.Keys)
                {
                    Definitions.Add(key, new JsonSchema(other.Definitions[key]));
                }
            }

            if (other.AdditionalItems != null)
            {
                AdditionalItems = new AdditionalItems(other.AdditionalItems);
            }

            if (other.AdditionalProperties != null)
            {
                AdditionalProperties = new AdditionalProperties(other.AdditionalProperties);
            }

            if (other.Dependencies != null)
            {
                Dependencies = new Dictionary<string, Dependency>(other.Dependencies);
            }

            if (other.PatternProperties != null)
            {
                PatternProperties = new Dictionary<string, JsonSchema>(other.PatternProperties);
            }

            Default = other.Default;
            Pattern = other.Pattern;
            MaxLength = other.MaxLength;
            MinLength = other.MinLength;
            Format = other.Format;
            MultipleOf = other.MultipleOf;
            Maximum = other.Maximum;
            ExclusiveMaximum = other.ExclusiveMaximum;
            MinItems = other.MinItems;
            MaxItems = other.MaxItems;
            UniqueItems = other.UniqueItems;

            if (other.Reference != null)
            {
                Reference = new UriOrFragment(other.Reference);
            }

            if (other.AllOf != null)
            {
                AllOf = new List<JsonSchema>(other.AllOf);
            }

            if (other.AnyOf != null)
            {
                AnyOf = new List<JsonSchema>(other.AnyOf);
            }

            if (other.OneOf != null)
            {
                OneOf = new List<JsonSchema>(other.OneOf);
            }

            if (other.Not != null)
            {
                Not = new JsonSchema(other.Not);
            }
        }