void (@NotNull JsonSchemaObject other) { // we do not copy id, schema mergeProperties(this, other); myDefinitionsMap = copyMap(myDefinitionsMap, other.myDefinitionsMap); final Map<String, JsonSchemaObject> map = copyMap(myPatternProperties == null ? null : myPatternProperties.mySchemasMap, other.myPatternProperties == null ? null : other.myPatternProperties.mySchemasMap); myPatternProperties = map == null ? null : new PatternProperties(map); if (!StringUtil.isEmptyOrSpaces(other.myTitle)) { myTitle = other.myTitle; } if (!StringUtil.isEmptyOrSpaces(other.myDescription)) { myDescription = other.myDescription; } if (!StringUtil.isEmptyOrSpaces(other.myHtmlDescription)) { myHtmlDescription = other.myHtmlDescription; } if (!StringUtil.isEmptyOrSpaces(other.myDeprecationMessage)) { myDeprecationMessage = other.myDeprecationMessage; } myType = mergeTypes(myType, other.myType, other.myTypeVariants); if (other.myDefault != null) myDefault = other.myDefault; if (other.myExample != null) myExample = other.myExample; if (other.myRef != null) myRef = other.myRef; if (other.myFormat != null) myFormat = other.myFormat; myTypeVariants = mergeTypeVariantSets(myTypeVariants, other.myTypeVariants); if (other.myMultipleOf != null) myMultipleOf = other.myMultipleOf; if (other.myMaximum != null) myMaximum = other.myMaximum; if (other.myExclusiveMaximumNumber != null) myExclusiveMaximumNumber = other.myExclusiveMaximumNumber; myExclusiveMaximum |= other.myExclusiveMaximum; if (other.myMinimum != null) myMinimum = other.myMinimum; if (other.myExclusiveMinimumNumber != null) myExclusiveMinimumNumber = other.myExclusiveMinimumNumber; myExclusiveMinimum |= other.myExclusiveMinimum; if (other.myMaxLength != null) myMaxLength = other.myMaxLength; if (other.myMinLength != null) myMinLength = other.myMinLength; if (other.myPattern != null) myPattern = other.myPattern; if (other.myAdditionalPropertiesAllowed != null) { myAdditionalPropertiesAllowed = other.myAdditionalPropertiesAllowed; if (other.myAdditionalPropertiesAllowed == Boolean.FALSE) { addAdditionalPropsNotAllowedFor(other.myFileUrl, other.myPointer); } } if (other.myAdditionalPropertiesSchema != null) myAdditionalPropertiesSchema = other.myAdditionalPropertiesSchema; if (other.myPropertyNamesSchema != null) myPropertyNamesSchema = other.myPropertyNamesSchema; if (other.myAdditionalItemsAllowed != null) myAdditionalItemsAllowed = other.myAdditionalItemsAllowed; if (other.myAdditionalItemsSchema != null) myAdditionalItemsSchema = other.myAdditionalItemsSchema; if (other.myItemsSchema != null) myItemsSchema = other.myItemsSchema; if (other.myContainsSchema != null) myContainsSchema = other.myContainsSchema; myItemsSchemaList = copyList(myItemsSchemaList, other.myItemsSchemaList); if (other.myMaxItems != null) myMaxItems = other.myMaxItems; if (other.myMinItems != null) myMinItems = other.myMinItems; if (other.myUniqueItems != null) myUniqueItems = other.myUniqueItems; if (other.myMaxProperties != null) myMaxProperties = other.myMaxProperties; if (other.myMinProperties != null) myMinProperties = other.myMinProperties; if (myRequired != null && other.myRequired != null) { Set<String> set = new HashSet<>(myRequired.size() + other.myRequired.size()); set.addAll(myRequired); set.addAll(other.myRequired); myRequired = set; } else if (other.myRequired != null) { myRequired = other.myRequired; } myPropertyDependencies = copyMap(myPropertyDependencies, other.myPropertyDependencies); mySchemaDependencies = copyMap(mySchemaDependencies, other.mySchemaDependencies); myEnumMetadata = copyMap(myEnumMetadata, other.myEnumMetadata); if (other.myEnum != null) myEnum = other.myEnum; myAllOf = copyList(myAllOf, other.myAllOf); myAnyOf = copyList(myAnyOf, other.myAnyOf); myOneOf = copyList(myOneOf, other.myOneOf); if (other.myNot != null) myNot = other.myNot; if (other.myIfThenElse != null) { if (myIfThenElse == null) myIfThenElse = other.myIfThenElse; else myIfThenElse = ContainerUtil.concat(myIfThenElse, other.myIfThenElse); } myShouldValidateAgainstJSType |= other.myShouldValidateAgainstJSType; if (myLanguageInjection == null) myLanguageInjection = other.myLanguageInjection; myForceCaseInsensitive = myForceCaseInsensitive || other.myForceCaseInsensitive; myNestedCompletionRoot = NestedCompletionsNodeKt.merge(myNestedCompletionRoot, other.myNestedCompletionRoot); }