|
20 | 20 | import org.openapitools.openapidiff.core.model.schema.ChangedOneOfSchema;
|
21 | 21 | import org.openapitools.openapidiff.core.model.schema.ChangedReadOnly;
|
22 | 22 | import org.openapitools.openapidiff.core.model.schema.ChangedRequired;
|
| 23 | +import org.openapitools.openapidiff.core.model.schema.ChangedUniqueItems; |
23 | 24 | import org.openapitools.openapidiff.core.model.schema.ChangedWriteOnly;
|
24 | 25 |
|
25 | 26 | public class ChangedSchema implements ComposedChanged {
|
@@ -50,6 +51,7 @@ public class ChangedSchema implements ComposedChanged {
|
50 | 51 | protected ChangedMaxProperties maxProperties;
|
51 | 52 | protected ChangedMinProperties minProperties;
|
52 | 53 | protected ChangedNullable nullable;
|
| 54 | + protected ChangedUniqueItems uniqueItems; |
53 | 55 | protected boolean discriminatorPropertyChanged;
|
54 | 56 | protected ChangedSchema items;
|
55 | 57 | protected ChangedOneOfSchema oneOfSchema;
|
@@ -138,6 +140,7 @@ public List<Changed> getChangedElements() {
|
138 | 140 | maxProperties,
|
139 | 141 | minProperties,
|
140 | 142 | nullable,
|
| 143 | + uniqueItems, |
141 | 144 | extensions))
|
142 | 145 | .collect(Collectors.toList());
|
143 | 146 | }
|
@@ -313,6 +316,10 @@ public ChangedNullable getNullable() {
|
313 | 316 | return this.nullable;
|
314 | 317 | }
|
315 | 318 |
|
| 319 | + public ChangedUniqueItems getUniqueItems() { |
| 320 | + return uniqueItems; |
| 321 | + } |
| 322 | + |
316 | 323 | public boolean isDiscriminatorPropertyChanged() {
|
317 | 324 | return this.discriminatorPropertyChanged;
|
318 | 325 | }
|
@@ -487,6 +494,12 @@ public ChangedSchema setNullable(final ChangedNullable nullable) {
|
487 | 494 | return this;
|
488 | 495 | }
|
489 | 496 |
|
| 497 | + public ChangedSchema setUniqueItems(ChangedUniqueItems uniqueItems) { |
| 498 | + clearChangedCache(); |
| 499 | + this.uniqueItems = uniqueItems; |
| 500 | + return this; |
| 501 | + } |
| 502 | + |
490 | 503 | public ChangedSchema setDiscriminatorPropertyChanged(final boolean discriminatorPropertyChanged) {
|
491 | 504 | clearChangedCache();
|
492 | 505 | this.discriminatorPropertyChanged = discriminatorPropertyChanged;
|
@@ -560,6 +573,7 @@ public boolean equals(Object o) {
|
560 | 573 | && Objects.equals(maxItems, that.maxItems)
|
561 | 574 | && Objects.equals(minItems, that.minItems)
|
562 | 575 | && Objects.equals(nullable, that.nullable)
|
| 576 | + && Objects.equals(uniqueItems, that.uniqueItems) |
563 | 577 | && Objects.equals(items, that.items)
|
564 | 578 | && Objects.equals(oneOfSchema, that.oneOfSchema)
|
565 | 579 | && Objects.equals(addProp, that.addProp)
|
@@ -596,6 +610,7 @@ public int hashCode() {
|
596 | 610 | maxItems,
|
597 | 611 | minItems,
|
598 | 612 | nullable,
|
| 613 | + uniqueItems, |
599 | 614 | discriminatorPropertyChanged,
|
600 | 615 | items,
|
601 | 616 | oneOfSchema,
|
@@ -657,6 +672,8 @@ public java.lang.String toString() {
|
657 | 672 | + this.getMinItems()
|
658 | 673 | + ", nullable="
|
659 | 674 | + this.getNullable()
|
| 675 | + + ", uniqueItems=" |
| 676 | + + this.getUniqueItems() |
660 | 677 | + ", discriminatorPropertyChanged="
|
661 | 678 | + this.isDiscriminatorPropertyChanged()
|
662 | 679 | + ", items="
|
|
0 commit comments