-
Notifications
You must be signed in to change notification settings - Fork 96
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support for 'default'. Refactors and simplifies validation a bit to be
more flexible.
- Loading branch information
1 parent
cd8720c
commit c7be101
Showing
22 changed files
with
157 additions
and
1,868 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,21 @@ | ||
// THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT. | ||
|
||
package test | ||
import "encoding/json" | ||
|
||
type 421ArrayMyObjectArrayElem map[string]interface{} | ||
type 421Array struct { | ||
// MyBooleanArray corresponds to the JSON schema field "myBooleanArray". | ||
MyBooleanArray []bool `json:"myBooleanArray,omitempty"` | ||
MyBooleanArray *[]bool `json:"myBooleanArray,omitempty"` | ||
|
||
// MyNullArray corresponds to the JSON schema field "myNullArray". | ||
MyNullArray []interface{} `json:"myNullArray,omitempty"` | ||
MyNullArray *[]interface{} `json:"myNullArray,omitempty"` | ||
|
||
// MyNumberArray corresponds to the JSON schema field "myNumberArray". | ||
MyNumberArray []float64 `json:"myNumberArray,omitempty"` | ||
MyNumberArray *[]float64 `json:"myNumberArray,omitempty"` | ||
|
||
// MyObjectArray corresponds to the JSON schema field "myObjectArray". | ||
MyObjectArray []421ArrayMyObjectArrayElem `json:"myObjectArray,omitempty"` | ||
MyObjectArray *[]421ArrayMyObjectArrayElem `json:"myObjectArray,omitempty"` | ||
|
||
// MyStringArray corresponds to the JSON schema field "myStringArray". | ||
MyStringArray []string `json:"myStringArray,omitempty"` | ||
} | ||
|
||
// UnmarshalJSON implements json.Unmarshaler. | ||
func (j *421Array) UnmarshalJSON(b []byte) error { | ||
var v struct { | ||
} | ||
if err := json.Unmarshal(b, &v); err != nil { return err } | ||
type plain 421Array | ||
var p plain | ||
if err := json.Unmarshal(b, &p); err != nil { return err } | ||
*j = 421Array(p) | ||
return nil | ||
} | ||
|
||
MyStringArray *[]string `json:"myStringArray,omitempty"` | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.