mirror of
https://github.com/go-gitea/gitea.git
synced 2026-11-20 07:07:31 +00:00
Vendor Update (#14496)
* update code.gitea.io/sdk/gitea v0.13.1 -> v0.13.2 * update github.com/go-swagger/go-swagger v0.25.0 -> v0.26.0 * update github.com/google/uuid v1.1.2 -> v1.2.0 * update github.com/klauspost/compress v1.11.3 -> v1.11.7 * update github.com/lib/pq 083382b7e6fc -> v1.9.0 * update github.com/markbates/goth v1.65.0 -> v1.66.1 * update github.com/mattn/go-sqlite3 v1.14.4 -> v1.14.6 * update github.com/mgechev/revive 246eac737dc7 -> v1.0.3 * update github.com/minio/minio-go/v7 v7.0.6 -> v7.0.7 * update github.com/niklasfasching/go-org v1.3.2 -> v1.4.0 * update github.com/olivere/elastic/v7 v7.0.21 -> v7.0.22 * update github.com/pquerna/otp v1.2.0 -> v1.3.0 * update github.com/xanzy/go-gitlab v0.39.0 -> v0.42.0 * update github.com/yuin/goldmark v1.2.1 -> v1.3.1
This commit is contained in:
403 files changed
+29734
-14354
No files matched your search
+1
-1
@@ -43,7 +43,7 @@ func (c *DiffCommand) Execute(_ []string) error {
|
||||
output io.WriteCloser
|
||||
err error
|
||||
)
|
||||
if c.Destination != "" {
|
||||
if c.Destination != "stdout" {
|
||||
output, err = os.OpenFile(c.Destination, os.O_CREATE|os.O_TRUNC|os.O_WRONLY, 0600)
|
||||
if err != nil {
|
||||
return fmt.Errorf("%s: %w", c.Destination, err)
|
||||
|
||||
+266
@@ -0,0 +1,266 @@
|
||||
package diff
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"strings"
|
||||
|
||||
"github.com/go-openapi/spec"
|
||||
)
|
||||
|
||||
// CompareEnums returns added, deleted enum values
|
||||
func CompareEnums(left, right []interface{}) []TypeDiff {
|
||||
diffs := []TypeDiff{}
|
||||
|
||||
leftStrs := []string{}
|
||||
rightStrs := []string{}
|
||||
for _, eachLeft := range left {
|
||||
leftStrs = append(leftStrs, fmt.Sprintf("%v", eachLeft))
|
||||
}
|
||||
for _, eachRight := range right {
|
||||
rightStrs = append(rightStrs, fmt.Sprintf("%v", eachRight))
|
||||
}
|
||||
added, deleted, _ := fromStringArray(leftStrs).DiffsTo(rightStrs)
|
||||
if len(added) > 0 {
|
||||
typeChange := strings.Join(added, ",")
|
||||
diffs = append(diffs, TypeDiff{Change: AddedEnumValue, Description: typeChange})
|
||||
}
|
||||
if len(deleted) > 0 {
|
||||
typeChange := strings.Join(deleted, ",")
|
||||
diffs = append(diffs, TypeDiff{Change: DeletedEnumValue, Description: typeChange})
|
||||
}
|
||||
|
||||
return diffs
|
||||
}
|
||||
|
||||
// CompareProperties recursive property comparison
|
||||
func CompareProperties(location DifferenceLocation, schema1 *spec.Schema, schema2 *spec.Schema, getRefFn1 SchemaFromRefFn, getRefFn2 SchemaFromRefFn, cmp CompareSchemaFn) []SpecDifference {
|
||||
propDiffs := []SpecDifference{}
|
||||
|
||||
if schema1.Properties == nil && schema2.Properties == nil {
|
||||
return propDiffs
|
||||
}
|
||||
|
||||
schema1Props := propertiesFor(schema1, getRefFn1)
|
||||
schema2Props := propertiesFor(schema2, getRefFn2)
|
||||
// find deleted and changed properties
|
||||
|
||||
for eachProp1Name, eachProp1 := range schema1Props {
|
||||
eachProp1 := eachProp1
|
||||
childLoc := addChildDiffNode(location, eachProp1Name, eachProp1.Schema)
|
||||
|
||||
if eachProp2, ok := schema2Props[eachProp1Name]; ok {
|
||||
diffs := CheckToFromRequired(eachProp1.Required, eachProp2.Required)
|
||||
if len(diffs) > 0 {
|
||||
for _, diff := range diffs {
|
||||
propDiffs = append(propDiffs, SpecDifference{DifferenceLocation: childLoc, Code: diff.Change})
|
||||
}
|
||||
}
|
||||
cmp(childLoc, eachProp1.Schema, eachProp2.Schema)
|
||||
} else {
|
||||
propDiffs = append(propDiffs, SpecDifference{DifferenceLocation: childLoc, Code: DeletedProperty})
|
||||
}
|
||||
}
|
||||
|
||||
// find added properties
|
||||
for eachProp2Name, eachProp2 := range schema2.Properties {
|
||||
eachProp2 := eachProp2
|
||||
if _, ok := schema1.Properties[eachProp2Name]; !ok {
|
||||
childLoc := addChildDiffNode(location, eachProp2Name, &eachProp2)
|
||||
propDiffs = append(propDiffs, SpecDifference{DifferenceLocation: childLoc, Code: AddedProperty})
|
||||
}
|
||||
}
|
||||
return propDiffs
|
||||
|
||||
}
|
||||
|
||||
// CompareFloatValues compares a float data item
|
||||
func CompareFloatValues(fieldName string, val1 *float64, val2 *float64, ifGreaterCode SpecChangeCode, ifLessCode SpecChangeCode) []TypeDiff {
|
||||
diffs := []TypeDiff{}
|
||||
if val1 != nil && val2 != nil {
|
||||
if *val2 > *val1 {
|
||||
diffs = append(diffs, TypeDiff{Change: ifGreaterCode, Description: fmt.Sprintf("%s %f->%f", fieldName, *val1, *val2)})
|
||||
} else if *val2 < *val1 {
|
||||
diffs = append(diffs, TypeDiff{Change: ifLessCode, Description: fmt.Sprintf("%s %f->%f", fieldName, *val1, *val2)})
|
||||
}
|
||||
} else {
|
||||
if val1 != val2 {
|
||||
if val1 != nil {
|
||||
diffs = append(diffs, TypeDiff{Change: DeletedConstraint, Description: fmt.Sprintf("%s(%f)", fieldName, *val1)})
|
||||
} else {
|
||||
diffs = append(diffs, TypeDiff{Change: AddedConstraint, Description: fmt.Sprintf("%s(%f)", fieldName, *val2)})
|
||||
}
|
||||
}
|
||||
}
|
||||
return diffs
|
||||
}
|
||||
|
||||
// CompareIntValues compares to int data items
|
||||
func CompareIntValues(fieldName string, val1 *int64, val2 *int64, ifGreaterCode SpecChangeCode, ifLessCode SpecChangeCode) []TypeDiff {
|
||||
diffs := []TypeDiff{}
|
||||
if val1 != nil && val2 != nil {
|
||||
if *val2 > *val1 {
|
||||
diffs = append(diffs, TypeDiff{Change: ifGreaterCode, Description: fmt.Sprintf("%s %d->%d", fieldName, *val1, *val2)})
|
||||
} else if *val2 < *val1 {
|
||||
diffs = append(diffs, TypeDiff{Change: ifLessCode, Description: fmt.Sprintf("%s %d->%d", fieldName, *val1, *val2)})
|
||||
}
|
||||
} else {
|
||||
if val1 != val2 {
|
||||
if val1 != nil {
|
||||
diffs = append(diffs, TypeDiff{Change: DeletedConstraint, Description: fmt.Sprintf("%s(%d)", fieldName, *val1)})
|
||||
} else {
|
||||
diffs = append(diffs, TypeDiff{Change: AddedConstraint, Description: fmt.Sprintf("%s(%d)", fieldName, *val2)})
|
||||
}
|
||||
}
|
||||
}
|
||||
return diffs
|
||||
}
|
||||
|
||||
// CheckToFromPrimitiveType check for diff to or from a primitive
|
||||
func CheckToFromPrimitiveType(diffs []TypeDiff, type1, type2 interface{}) []TypeDiff {
|
||||
|
||||
type1IsPrimitive := isPrimitive(type1)
|
||||
type2IsPrimitive := isPrimitive(type2)
|
||||
|
||||
// Primitive to Obj or Obj to Primitive
|
||||
if type1IsPrimitive != type2IsPrimitive {
|
||||
typeStr1, isarray1 := getSchemaType(type1)
|
||||
typeStr2, isarray2 := getSchemaType(type2)
|
||||
return addTypeDiff(diffs, TypeDiff{Change: ChangedType, FromType: formatTypeString(typeStr1, isarray1), ToType: formatTypeString(typeStr2, isarray2)})
|
||||
}
|
||||
|
||||
return diffs
|
||||
}
|
||||
|
||||
// CheckRefChange has the property ref changed
|
||||
func CheckRefChange(diffs []TypeDiff, type1, type2 interface{}) (diffReturn []TypeDiff) {
|
||||
|
||||
diffReturn = diffs
|
||||
if isRefType(type1) && isRefType(type2) {
|
||||
// both refs but to different objects (TODO detect renamed object)
|
||||
ref1 := definitionFromRef(getRef(type1))
|
||||
ref2 := definitionFromRef(getRef(type2))
|
||||
if ref1 != ref2 {
|
||||
diffReturn = addTypeDiff(diffReturn, TypeDiff{Change: RefTargetChanged, FromType: getSchemaTypeStr(type1), ToType: getSchemaTypeStr(type2)})
|
||||
}
|
||||
} else if isRefType(type1) != isRefType(type2) {
|
||||
diffReturn = addTypeDiff(diffReturn, TypeDiff{Change: ChangedType, FromType: getSchemaTypeStr(type1), ToType: getSchemaTypeStr(type2)})
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// checkNumericTypeChanges checks for changes to or from a numeric type
|
||||
func checkNumericTypeChanges(diffs []TypeDiff, type1, type2 *spec.SchemaProps) []TypeDiff {
|
||||
// Number
|
||||
_, type1IsNumeric := numberWideness[type1.Type[0]]
|
||||
_, type2IsNumeric := numberWideness[type2.Type[0]]
|
||||
|
||||
if type1IsNumeric && type2IsNumeric {
|
||||
foundDiff := false
|
||||
if type1.ExclusiveMaximum && !type2.ExclusiveMaximum {
|
||||
diffs = addTypeDiff(diffs, TypeDiff{Change: WidenedType, Description: fmt.Sprintf("Exclusive Maximum Removed:%v->%v", type1.ExclusiveMaximum, type2.ExclusiveMaximum)})
|
||||
foundDiff = true
|
||||
}
|
||||
if !type1.ExclusiveMaximum && type2.ExclusiveMaximum {
|
||||
diffs = addTypeDiff(diffs, TypeDiff{Change: NarrowedType, Description: fmt.Sprintf("Exclusive Maximum Added:%v->%v", type1.ExclusiveMaximum, type2.ExclusiveMaximum)})
|
||||
foundDiff = true
|
||||
}
|
||||
if type1.ExclusiveMinimum && !type2.ExclusiveMinimum {
|
||||
diffs = addTypeDiff(diffs, TypeDiff{Change: WidenedType, Description: fmt.Sprintf("Exclusive Minimum Removed:%v->%v", type1.ExclusiveMaximum, type2.ExclusiveMaximum)})
|
||||
foundDiff = true
|
||||
}
|
||||
if !type1.ExclusiveMinimum && type2.ExclusiveMinimum {
|
||||
diffs = addTypeDiff(diffs, TypeDiff{Change: NarrowedType, Description: fmt.Sprintf("Exclusive Minimum Added:%v->%v", type1.ExclusiveMinimum, type2.ExclusiveMinimum)})
|
||||
foundDiff = true
|
||||
}
|
||||
if !foundDiff {
|
||||
maxDiffs := CompareFloatValues("Maximum", type1.Maximum, type2.Maximum, WidenedType, NarrowedType)
|
||||
diffs = append(diffs, maxDiffs...)
|
||||
minDiffs := CompareFloatValues("Minimum", type1.Minimum, type2.Minimum, NarrowedType, WidenedType)
|
||||
diffs = append(diffs, minDiffs...)
|
||||
}
|
||||
}
|
||||
return diffs
|
||||
}
|
||||
|
||||
// CheckStringTypeChanges checks for changes to or from a string type
|
||||
func CheckStringTypeChanges(diffs []TypeDiff, type1, type2 *spec.SchemaProps) []TypeDiff {
|
||||
// string changes
|
||||
if type1.Type[0] == StringType &&
|
||||
type2.Type[0] == StringType {
|
||||
minLengthDiffs := CompareIntValues("MinLength", type1.MinLength, type2.MinLength, NarrowedType, WidenedType)
|
||||
diffs = append(diffs, minLengthDiffs...)
|
||||
maxLengthDiffs := CompareIntValues("MaxLength", type1.MinLength, type2.MinLength, WidenedType, NarrowedType)
|
||||
diffs = append(diffs, maxLengthDiffs...)
|
||||
if type1.Pattern != type2.Pattern {
|
||||
diffs = addTypeDiff(diffs, TypeDiff{Change: ChangedType, Description: fmt.Sprintf("Pattern Changed:%s->%s", type1.Pattern, type2.Pattern)})
|
||||
}
|
||||
if type1.Type[0] == StringType {
|
||||
if len(type1.Enum) > 0 {
|
||||
enumDiffs := CompareEnums(type1.Enum, type2.Enum)
|
||||
diffs = append(diffs, enumDiffs...)
|
||||
}
|
||||
}
|
||||
}
|
||||
return diffs
|
||||
}
|
||||
|
||||
// CheckToFromRequired checks for changes to or from a required property
|
||||
func CheckToFromRequired(required1, required2 bool) (diffs []TypeDiff) {
|
||||
if required1 != required2 {
|
||||
code := ChangedOptionalToRequired
|
||||
if required1 {
|
||||
code = ChangedRequiredToOptional
|
||||
}
|
||||
diffs = addTypeDiff(diffs, TypeDiff{Change: code})
|
||||
}
|
||||
return diffs
|
||||
}
|
||||
|
||||
const objType = "object"
|
||||
|
||||
func getTypeHierarchyChange(type1, type2 string) TypeDiff {
|
||||
fromType := type1
|
||||
if fromType == "" {
|
||||
fromType = objType
|
||||
}
|
||||
toType := type2
|
||||
if toType == "" {
|
||||
toType = objType
|
||||
}
|
||||
diffDescription := fmt.Sprintf("%s -> %s", fromType, toType)
|
||||
if isStringType(type1) && !isStringType(type2) {
|
||||
return TypeDiff{Change: NarrowedType, Description: diffDescription}
|
||||
}
|
||||
if !isStringType(type1) && isStringType(type2) {
|
||||
return TypeDiff{Change: WidenedType, Description: diffDescription}
|
||||
}
|
||||
type1Wideness, type1IsNumeric := numberWideness[type1]
|
||||
type2Wideness, type2IsNumeric := numberWideness[type2]
|
||||
if type1IsNumeric && type2IsNumeric {
|
||||
if type1Wideness == type2Wideness {
|
||||
return TypeDiff{Change: ChangedToCompatibleType, Description: diffDescription}
|
||||
}
|
||||
if type1Wideness > type2Wideness {
|
||||
return TypeDiff{Change: NarrowedType, Description: diffDescription}
|
||||
}
|
||||
if type1Wideness < type2Wideness {
|
||||
return TypeDiff{Change: WidenedType, Description: diffDescription}
|
||||
}
|
||||
}
|
||||
return TypeDiff{Change: ChangedType, Description: diffDescription}
|
||||
}
|
||||
|
||||
func isRefType(item interface{}) bool {
|
||||
switch s := item.(type) {
|
||||
case spec.Refable:
|
||||
return s.Ref.String() != ""
|
||||
case *spec.Schema:
|
||||
return s.Ref.String() != ""
|
||||
case *spec.SchemaProps:
|
||||
return s.Ref.String() != ""
|
||||
case *spec.SimpleSchema:
|
||||
return false
|
||||
default:
|
||||
return false
|
||||
}
|
||||
}
|
||||
Generated
Vendored
+31
-23
@@ -32,29 +32,33 @@ func init() {
|
||||
ChangedTag: NonBreaking,
|
||||
AddedTag: NonBreaking,
|
||||
DeletedTag: NonBreaking,
|
||||
DeletedConstraint: Breaking,
|
||||
AddedConstraint: NonBreaking,
|
||||
},
|
||||
ForRequest: map[SpecChangeCode]Compatibility{
|
||||
AddedRequiredProperty: Breaking,
|
||||
DeletedProperty: Breaking,
|
||||
AddedProperty: Breaking,
|
||||
AddedOptionalParam: NonBreaking,
|
||||
AddedRequiredParam: Breaking,
|
||||
DeletedOptionalParam: NonBreaking,
|
||||
DeletedRequiredParam: NonBreaking,
|
||||
WidenedType: NonBreaking,
|
||||
NarrowedType: Breaking,
|
||||
ChangedType: Breaking,
|
||||
ChangedToCompatibleType: NonBreaking,
|
||||
ChangedOptionalToRequiredParam: Breaking,
|
||||
ChangedRequiredToOptionalParam: NonBreaking,
|
||||
AddedEnumValue: NonBreaking,
|
||||
DeletedEnumValue: Breaking,
|
||||
ChangedDescripton: NonBreaking,
|
||||
AddedDescripton: NonBreaking,
|
||||
DeletedDescripton: NonBreaking,
|
||||
ChangedTag: NonBreaking,
|
||||
AddedTag: NonBreaking,
|
||||
DeletedTag: NonBreaking,
|
||||
AddedRequiredProperty: Breaking,
|
||||
DeletedProperty: Breaking,
|
||||
AddedProperty: Breaking,
|
||||
AddedOptionalParam: NonBreaking,
|
||||
AddedRequiredParam: Breaking,
|
||||
DeletedOptionalParam: NonBreaking,
|
||||
DeletedRequiredParam: NonBreaking,
|
||||
WidenedType: NonBreaking,
|
||||
NarrowedType: Breaking,
|
||||
ChangedType: Breaking,
|
||||
ChangedToCompatibleType: NonBreaking,
|
||||
ChangedOptionalToRequired: Breaking,
|
||||
ChangedRequiredToOptional: NonBreaking,
|
||||
AddedEnumValue: NonBreaking,
|
||||
DeletedEnumValue: Breaking,
|
||||
ChangedDescripton: NonBreaking,
|
||||
AddedDescripton: NonBreaking,
|
||||
DeletedDescripton: NonBreaking,
|
||||
ChangedTag: NonBreaking,
|
||||
AddedTag: NonBreaking,
|
||||
DeletedTag: NonBreaking,
|
||||
DeletedConstraint: NonBreaking,
|
||||
AddedConstraint: Breaking,
|
||||
},
|
||||
ForChange: map[SpecChangeCode]Compatibility{
|
||||
NoChangeDetected: NonBreaking,
|
||||
@@ -63,8 +67,8 @@ func init() {
|
||||
DeletedDeprecatedEndpoint: NonBreaking,
|
||||
AddedConsumesFormat: NonBreaking,
|
||||
DeletedConsumesFormat: Breaking,
|
||||
AddedProducesFormat: Breaking,
|
||||
DeletedProducesFormat: NonBreaking,
|
||||
AddedProducesFormat: NonBreaking,
|
||||
DeletedProducesFormat: Breaking,
|
||||
AddedSchemes: NonBreaking,
|
||||
DeletedSchemes: Breaking,
|
||||
ChangedHostURL: Breaking,
|
||||
@@ -75,6 +79,10 @@ func init() {
|
||||
ChangedTag: NonBreaking,
|
||||
AddedTag: NonBreaking,
|
||||
DeletedTag: NonBreaking,
|
||||
RefTargetChanged: Breaking,
|
||||
RefTargetRenamed: NonBreaking,
|
||||
AddedDefinition: NonBreaking,
|
||||
DeletedDefinition: NonBreaking,
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
+104
-83
@@ -43,8 +43,6 @@ const (
|
||||
AddedRequiredParam
|
||||
// DeletedRequiredParam - A required parameter has been deleted in the new spec
|
||||
DeletedRequiredParam
|
||||
// ChangedRequiredToOptional - A required parameter has been made optional in the new spec
|
||||
ChangedRequiredToOptional
|
||||
// AddedEndpoint - An endpoint has been added in the new spec
|
||||
AddedEndpoint
|
||||
// WidenedType - An type has been changed to a more permissive type eg int->string
|
||||
@@ -61,10 +59,10 @@ const (
|
||||
DeletedEnumValue
|
||||
// AddedOptionalParam - A new optional parameter has been added to the new spec
|
||||
AddedOptionalParam
|
||||
// ChangedOptionalToRequiredParam - An optional parameter is now required in the new spec
|
||||
ChangedOptionalToRequiredParam
|
||||
// ChangedRequiredToOptionalParam - An required parameter is now optional in the new spec
|
||||
ChangedRequiredToOptionalParam
|
||||
// ChangedOptionalToRequired - An optional parameter is now required in the new spec
|
||||
ChangedOptionalToRequired
|
||||
// ChangedRequiredToOptional - An required parameter is now optional in the new spec
|
||||
ChangedRequiredToOptional
|
||||
// AddedResponse An endpoint has new response code in the new spec
|
||||
AddedResponse
|
||||
// AddedConsumesFormat - a new consumes format (json/xml/yaml etc) has been added in the new spec
|
||||
@@ -89,88 +87,112 @@ const (
|
||||
ChangedResponseHeader
|
||||
// DeletedResponseHeader Added a header Item
|
||||
DeletedResponseHeader
|
||||
// RefTargetChanged Changed a ref to point to a different object
|
||||
RefTargetChanged
|
||||
// RefTargetRenamed Renamed a ref to point to the same object
|
||||
RefTargetRenamed
|
||||
// DeletedConstraint Deleted a schema constraint
|
||||
DeletedConstraint
|
||||
// AddedConstraint Added a schema constraint
|
||||
AddedConstraint
|
||||
// DeletedDefinition removed one of the definitions
|
||||
DeletedDefinition
|
||||
// AddedDefinition removed one of the definitions
|
||||
AddedDefinition
|
||||
)
|
||||
|
||||
var toLongStringSpecChangeCode = map[SpecChangeCode]string{
|
||||
NoChangeDetected: "No Change detected",
|
||||
AddedEndpoint: "Added endpoint",
|
||||
DeletedEndpoint: "Deleted endpoint",
|
||||
DeletedDeprecatedEndpoint: "Deleted a deprecated endpoint",
|
||||
AddedRequiredProperty: "Added required property",
|
||||
DeletedProperty: "Deleted property",
|
||||
ChangedDescripton: "Changed a description",
|
||||
AddedDescripton: "Added a description",
|
||||
DeletedDescripton: "Deleted a description",
|
||||
ChangedTag: "Changed a tag",
|
||||
AddedTag: "Added a tag",
|
||||
DeletedTag: "Deleted a tag",
|
||||
AddedProperty: "Added property",
|
||||
AddedOptionalParam: "Added optional param",
|
||||
AddedRequiredParam: "Added required param",
|
||||
DeletedOptionalParam: "Deleted optional param",
|
||||
DeletedRequiredParam: "Deleted required param",
|
||||
DeletedResponse: "Deleted response",
|
||||
AddedResponse: "Added response",
|
||||
WidenedType: "Widened type",
|
||||
NarrowedType: "Narrowed type",
|
||||
ChangedType: "Changed type",
|
||||
ChangedToCompatibleType: "Changed type to equivalent type",
|
||||
ChangedOptionalToRequiredParam: "Changed optional param to required",
|
||||
ChangedRequiredToOptionalParam: "Changed required param to optional",
|
||||
AddedEnumValue: "Added possible enumeration(s)",
|
||||
DeletedEnumValue: "Deleted possible enumeration(s)",
|
||||
AddedConsumesFormat: "Added a consumes format",
|
||||
DeletedConsumesFormat: "Deleted a consumes format",
|
||||
AddedProducesFormat: "Added produces format",
|
||||
DeletedProducesFormat: "Deleted produces format",
|
||||
AddedSchemes: "Added schemes",
|
||||
DeletedSchemes: "Deleted schemes",
|
||||
ChangedHostURL: "Changed host URL",
|
||||
ChangedBasePath: "Changed base path",
|
||||
AddedResponseHeader: "Added response header",
|
||||
ChangedResponseHeader: "Changed response header",
|
||||
DeletedResponseHeader: "Deleted response header",
|
||||
NoChangeDetected: "No Change detected",
|
||||
AddedEndpoint: "Added endpoint",
|
||||
DeletedEndpoint: "Deleted endpoint",
|
||||
DeletedDeprecatedEndpoint: "Deleted a deprecated endpoint",
|
||||
AddedRequiredProperty: "Added required property",
|
||||
DeletedProperty: "Deleted property",
|
||||
ChangedDescripton: "Changed a description",
|
||||
AddedDescripton: "Added a description",
|
||||
DeletedDescripton: "Deleted a description",
|
||||
ChangedTag: "Changed a tag",
|
||||
AddedTag: "Added a tag",
|
||||
DeletedTag: "Deleted a tag",
|
||||
AddedProperty: "Added property",
|
||||
AddedOptionalParam: "Added optional param",
|
||||
AddedRequiredParam: "Added required param",
|
||||
DeletedOptionalParam: "Deleted optional param",
|
||||
DeletedRequiredParam: "Deleted required param",
|
||||
DeletedResponse: "Deleted response",
|
||||
AddedResponse: "Added response",
|
||||
WidenedType: "Widened type",
|
||||
NarrowedType: "Narrowed type",
|
||||
ChangedType: "Changed type",
|
||||
ChangedToCompatibleType: "Changed type to equivalent type",
|
||||
ChangedOptionalToRequired: "Changed optional param to required",
|
||||
ChangedRequiredToOptional: "Changed required param to optional",
|
||||
AddedEnumValue: "Added possible enumeration(s)",
|
||||
DeletedEnumValue: "Deleted possible enumeration(s)",
|
||||
AddedConsumesFormat: "Added a consumes format",
|
||||
DeletedConsumesFormat: "Deleted a consumes format",
|
||||
AddedProducesFormat: "Added produces format",
|
||||
DeletedProducesFormat: "Deleted produces format",
|
||||
AddedSchemes: "Added schemes",
|
||||
DeletedSchemes: "Deleted schemes",
|
||||
ChangedHostURL: "Changed host URL",
|
||||
ChangedBasePath: "Changed base path",
|
||||
AddedResponseHeader: "Added response header",
|
||||
ChangedResponseHeader: "Changed response header",
|
||||
DeletedResponseHeader: "Deleted response header",
|
||||
RefTargetChanged: "Changed ref to different object",
|
||||
RefTargetRenamed: "Changed ref to renamed object",
|
||||
DeletedConstraint: "Deleted a schema constraint",
|
||||
AddedConstraint: "Added a schema constraint",
|
||||
DeletedDefinition: "Deleted a schema definition",
|
||||
AddedDefinition: "Added a schema definition",
|
||||
}
|
||||
|
||||
var toStringSpecChangeCode = map[SpecChangeCode]string{
|
||||
AddedEndpoint: "AddedEndpoint",
|
||||
NoChangeDetected: "NoChangeDetected",
|
||||
DeletedEndpoint: "DeletedEndpoint",
|
||||
DeletedDeprecatedEndpoint: "DeletedDeprecatedEndpoint",
|
||||
AddedRequiredProperty: "AddedRequiredProperty",
|
||||
DeletedProperty: "DeletedProperty",
|
||||
AddedProperty: "AddedProperty",
|
||||
ChangedDescripton: "ChangedDescription",
|
||||
AddedDescripton: "AddedDescription",
|
||||
DeletedDescripton: "DeletedDescription",
|
||||
ChangedTag: "ChangedTag",
|
||||
AddedTag: "AddedTag",
|
||||
DeletedTag: "DeletedTag",
|
||||
AddedOptionalParam: "AddedOptionalParam",
|
||||
AddedRequiredParam: "AddedRequiredParam",
|
||||
DeletedOptionalParam: "DeletedRequiredParam",
|
||||
DeletedRequiredParam: "Deleted required param",
|
||||
DeletedResponse: "DeletedResponse",
|
||||
AddedResponse: "AddedResponse",
|
||||
WidenedType: "WidenedType",
|
||||
NarrowedType: "NarrowedType",
|
||||
ChangedType: "ChangedType",
|
||||
ChangedToCompatibleType: "ChangedToCompatibleType",
|
||||
ChangedOptionalToRequiredParam: "ChangedOptionalToRequiredParam",
|
||||
ChangedRequiredToOptionalParam: "ChangedRequiredToOptionalParam",
|
||||
AddedEnumValue: "AddedEnumValue",
|
||||
DeletedEnumValue: "DeletedEnumValue",
|
||||
AddedConsumesFormat: "AddedConsumesFormat",
|
||||
DeletedConsumesFormat: "DeletedConsumesFormat",
|
||||
AddedProducesFormat: "AddedProducesFormat",
|
||||
DeletedProducesFormat: "DeletedProducesFormat",
|
||||
AddedSchemes: "AddedSchemes",
|
||||
DeletedSchemes: "DeletedSchemes",
|
||||
ChangedHostURL: "ChangedHostURL",
|
||||
ChangedBasePath: "ChangedBasePath",
|
||||
AddedResponseHeader: "AddedResponseHeader",
|
||||
ChangedResponseHeader: "ChangedResponseHeader",
|
||||
DeletedResponseHeader: "DeletedResponseHeader",
|
||||
AddedEndpoint: "AddedEndpoint",
|
||||
NoChangeDetected: "NoChangeDetected",
|
||||
DeletedEndpoint: "DeletedEndpoint",
|
||||
DeletedDeprecatedEndpoint: "DeletedDeprecatedEndpoint",
|
||||
AddedRequiredProperty: "AddedRequiredProperty",
|
||||
DeletedProperty: "DeletedProperty",
|
||||
AddedProperty: "AddedProperty",
|
||||
ChangedDescripton: "ChangedDescription",
|
||||
AddedDescripton: "AddedDescription",
|
||||
DeletedDescripton: "DeletedDescription",
|
||||
ChangedTag: "ChangedTag",
|
||||
AddedTag: "AddedTag",
|
||||
DeletedTag: "DeletedTag",
|
||||
AddedOptionalParam: "AddedOptionalParam",
|
||||
AddedRequiredParam: "AddedRequiredParam",
|
||||
DeletedOptionalParam: "DeletedRequiredParam",
|
||||
DeletedRequiredParam: "Deleted required param",
|
||||
DeletedResponse: "DeletedResponse",
|
||||
AddedResponse: "AddedResponse",
|
||||
WidenedType: "WidenedType",
|
||||
NarrowedType: "NarrowedType",
|
||||
ChangedType: "ChangedType",
|
||||
ChangedToCompatibleType: "ChangedToCompatibleType",
|
||||
ChangedOptionalToRequired: "ChangedOptionalToRequiredParam",
|
||||
ChangedRequiredToOptional: "ChangedRequiredToOptionalParam",
|
||||
AddedEnumValue: "AddedEnumValue",
|
||||
DeletedEnumValue: "DeletedEnumValue",
|
||||
AddedConsumesFormat: "AddedConsumesFormat",
|
||||
DeletedConsumesFormat: "DeletedConsumesFormat",
|
||||
AddedProducesFormat: "AddedProducesFormat",
|
||||
DeletedProducesFormat: "DeletedProducesFormat",
|
||||
AddedSchemes: "AddedSchemes",
|
||||
DeletedSchemes: "DeletedSchemes",
|
||||
ChangedHostURL: "ChangedHostURL",
|
||||
ChangedBasePath: "ChangedBasePath",
|
||||
AddedResponseHeader: "AddedResponseHeader",
|
||||
ChangedResponseHeader: "ChangedResponseHeader",
|
||||
DeletedResponseHeader: "DeletedResponseHeader",
|
||||
RefTargetChanged: "RefTargetChanged",
|
||||
RefTargetRenamed: "RefTargetRenamed",
|
||||
DeletedConstraint: "DeletedConstraint",
|
||||
AddedConstraint: "AddedConstraint",
|
||||
DeletedDefinition: "DeletedDefinition",
|
||||
AddedDefinition: "AddedDefinition",
|
||||
}
|
||||
|
||||
var toIDSpecChangeCode = map[string]SpecChangeCode{}
|
||||
@@ -273,5 +295,4 @@ func init() {
|
||||
for key, val := range toStringCompatibility {
|
||||
toIDCompatibility[val] = key
|
||||
}
|
||||
|
||||
}
|
||||
+46
-11
@@ -1,5 +1,11 @@
|
||||
package diff
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
"github.com/go-openapi/spec"
|
||||
)
|
||||
|
||||
// Node is the position od a diff in a spec
|
||||
type Node struct {
|
||||
Field string `json:"name,omitempty"`
|
||||
@@ -12,14 +18,12 @@ type Node struct {
|
||||
func (n *Node) String() string {
|
||||
name := n.Field
|
||||
if n.IsArray {
|
||||
name = "array[" + n.TypeName + "]"
|
||||
name = fmt.Sprintf("%s<array[%s]>", name, n.TypeName)
|
||||
} else if len(n.TypeName) > 0 {
|
||||
name = fmt.Sprintf("%s<%s>", name, n.TypeName)
|
||||
}
|
||||
|
||||
if n.ChildNode != nil {
|
||||
return name + "." + n.ChildNode.String()
|
||||
}
|
||||
if len(n.TypeName) > 0 {
|
||||
return name + " : " + n.TypeName
|
||||
return fmt.Sprintf("%s.%s", name, n.ChildNode.String())
|
||||
}
|
||||
return name
|
||||
}
|
||||
@@ -36,12 +40,43 @@ func (n *Node) AddLeafNode(toAdd *Node) *Node {
|
||||
return n
|
||||
}
|
||||
|
||||
//Copy deep copy of this node and children
|
||||
// Copy deep copy of this node and children
|
||||
func (n Node) Copy() *Node {
|
||||
newNode := n
|
||||
|
||||
if newNode.ChildNode != nil {
|
||||
n.ChildNode = newNode.ChildNode.Copy()
|
||||
newChild := n.ChildNode
|
||||
if newChild != nil {
|
||||
newChild = newChild.Copy()
|
||||
}
|
||||
newNode := Node{
|
||||
Field: n.Field,
|
||||
TypeName: n.TypeName,
|
||||
IsArray: n.IsArray,
|
||||
ChildNode: newChild,
|
||||
}
|
||||
|
||||
return &newNode
|
||||
}
|
||||
|
||||
func getSchemaDiffNode(name string, schema interface{}) *Node {
|
||||
node := Node{
|
||||
Field: name,
|
||||
}
|
||||
if schema != nil {
|
||||
switch s := schema.(type) {
|
||||
case spec.Refable:
|
||||
node.TypeName, node.IsArray = getSchemaType(s)
|
||||
case *spec.Schema:
|
||||
node.TypeName, node.IsArray = getSchemaType(s.SchemaProps)
|
||||
case spec.SimpleSchema:
|
||||
node.TypeName, node.IsArray = getSchemaType(s)
|
||||
case *spec.SimpleSchema:
|
||||
node.TypeName, node.IsArray = getSchemaType(s)
|
||||
case *spec.SchemaProps:
|
||||
node.TypeName, node.IsArray = getSchemaType(s)
|
||||
case spec.SchemaProps:
|
||||
node.TypeName, node.IsArray = getSchemaType(&s)
|
||||
default:
|
||||
node.TypeName = fmt.Sprintf("Unknown type %v", schema)
|
||||
}
|
||||
}
|
||||
return &node
|
||||
}
|
||||
+3
-56
@@ -5,8 +5,6 @@ import (
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"io"
|
||||
"net/url"
|
||||
"strings"
|
||||
|
||||
"github.com/go-openapi/spec"
|
||||
)
|
||||
@@ -14,6 +12,9 @@ import (
|
||||
// ArrayType const for array
|
||||
var ArrayType = "array"
|
||||
|
||||
// ObjectType const for object
|
||||
var ObjectType = "object"
|
||||
|
||||
// Compare returns the result of analysing breaking and non breaking changes
|
||||
// between to Swagger specs
|
||||
func Compare(spec1, spec2 *spec.Swagger) (diffs SpecDifferences, err error) {
|
||||
@@ -72,60 +73,6 @@ func getNameOnlyDiffNode(forLocation string) *Node {
|
||||
return &node
|
||||
}
|
||||
|
||||
func getSimpleSchemaDiffNode(name string, schema *spec.SimpleSchema) *Node {
|
||||
node := Node{
|
||||
Field: name,
|
||||
}
|
||||
if schema != nil {
|
||||
node.TypeName, node.IsArray = getSimpleSchemaType(schema)
|
||||
}
|
||||
return &node
|
||||
}
|
||||
|
||||
func getSchemaDiffNode(name string, schema *spec.Schema) *Node {
|
||||
node := Node{
|
||||
Field: name,
|
||||
}
|
||||
if schema != nil {
|
||||
node.TypeName, node.IsArray = getSchemaType(&schema.SchemaProps)
|
||||
}
|
||||
return &node
|
||||
}
|
||||
|
||||
func definitonFromURL(url *url.URL) string {
|
||||
if url == nil {
|
||||
return ""
|
||||
}
|
||||
fragmentParts := strings.Split(url.Fragment, "/")
|
||||
numParts := len(fragmentParts)
|
||||
if numParts == 0 {
|
||||
return ""
|
||||
}
|
||||
return fragmentParts[numParts-1]
|
||||
}
|
||||
|
||||
func getSimpleSchemaType(schema *spec.SimpleSchema) (typeName string, isArray bool) {
|
||||
typeName = schema.Type
|
||||
if typeName == ArrayType {
|
||||
typeName, _ = getSimpleSchemaType(&schema.Items.SimpleSchema)
|
||||
return typeName, true
|
||||
}
|
||||
return typeName, false
|
||||
}
|
||||
|
||||
func getSchemaType(schema *spec.SchemaProps) (typeName string, isArray bool) {
|
||||
refStr := definitonFromURL(schema.Ref.GetURL())
|
||||
if len(refStr) > 0 {
|
||||
return refStr, false
|
||||
}
|
||||
typeName = schema.Type[0]
|
||||
if typeName == ArrayType {
|
||||
typeName, _ = getSchemaType(&schema.Items.Schema.SchemaProps)
|
||||
return typeName, true
|
||||
}
|
||||
return typeName, false
|
||||
}
|
||||
|
||||
func primitiveTypeString(typeName, typeFormat string) string {
|
||||
if typeFormat != "" {
|
||||
return fmt.Sprintf("%s.%s", typeName, typeFormat)
|
||||
|
||||
+126
@@ -0,0 +1,126 @@
|
||||
package diff
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"strings"
|
||||
|
||||
"github.com/go-openapi/spec"
|
||||
)
|
||||
|
||||
func getTypeFromSchema(schema *spec.Schema) (typeName string, isArray bool) {
|
||||
refStr := definitionFromRef(schema.Ref)
|
||||
if len(refStr) > 0 {
|
||||
return refStr, false
|
||||
}
|
||||
typeName = schema.Type[0]
|
||||
if typeName == ArrayType {
|
||||
typeName, _ = getSchemaType(&schema.Items.Schema.SchemaProps)
|
||||
return typeName, true
|
||||
}
|
||||
return typeName, false
|
||||
|
||||
}
|
||||
|
||||
func getTypeFromSimpleSchema(schema *spec.SimpleSchema) (typeName string, isArray bool) {
|
||||
typeName = schema.Type
|
||||
format := schema.Format
|
||||
if len(format) > 0 {
|
||||
typeName = fmt.Sprintf("%s.%s", typeName, format)
|
||||
}
|
||||
if typeName == ArrayType {
|
||||
typeName, _ = getSchemaType(&schema.Items.SimpleSchema)
|
||||
return typeName, true
|
||||
}
|
||||
return typeName, false
|
||||
|
||||
}
|
||||
|
||||
func getTypeFromSchemaProps(schema *spec.SchemaProps) (typeName string, isArray bool) {
|
||||
refStr := definitionFromRef(schema.Ref)
|
||||
if len(refStr) > 0 {
|
||||
return refStr, false
|
||||
}
|
||||
if len(schema.Type) > 0 {
|
||||
typeName = schema.Type[0]
|
||||
format := schema.Format
|
||||
if len(format) > 0 {
|
||||
typeName = fmt.Sprintf("%s.%s", typeName, format)
|
||||
}
|
||||
if typeName == ArrayType {
|
||||
typeName, _ = getSchemaType(&schema.Items.Schema.SchemaProps)
|
||||
return typeName, true
|
||||
}
|
||||
}
|
||||
return typeName, false
|
||||
|
||||
}
|
||||
|
||||
func getSchemaTypeStr(item interface{}) string {
|
||||
typeStr, isArray := getSchemaType(item)
|
||||
return formatTypeString(typeStr, isArray)
|
||||
}
|
||||
|
||||
func getSchemaType(item interface{}) (typeName string, isArray bool) {
|
||||
|
||||
switch s := item.(type) {
|
||||
case *spec.Schema:
|
||||
typeName, isArray = getTypeFromSchema(s)
|
||||
case *spec.SchemaProps:
|
||||
typeName, isArray = getTypeFromSchemaProps(s)
|
||||
case spec.SchemaProps:
|
||||
typeName, isArray = getTypeFromSchemaProps(&s)
|
||||
case spec.SimpleSchema:
|
||||
typeName, isArray = getTypeFromSimpleSchema(&s)
|
||||
case *spec.SimpleSchema:
|
||||
typeName, isArray = getTypeFromSimpleSchema(s)
|
||||
default:
|
||||
typeName = "unknown"
|
||||
}
|
||||
|
||||
return
|
||||
|
||||
}
|
||||
|
||||
func formatTypeString(typ string, isarray bool) string {
|
||||
if isarray {
|
||||
return fmt.Sprintf("<array[%s]>", typ)
|
||||
}
|
||||
return fmt.Sprintf("<%s>", typ)
|
||||
}
|
||||
|
||||
func definitionFromRef(ref spec.Ref) string {
|
||||
url := ref.GetURL()
|
||||
if url == nil {
|
||||
return ""
|
||||
}
|
||||
fragmentParts := strings.Split(url.Fragment, "/")
|
||||
numParts := len(fragmentParts)
|
||||
|
||||
return fragmentParts[numParts-1]
|
||||
}
|
||||
|
||||
func isArray(item interface{}) bool {
|
||||
switch s := item.(type) {
|
||||
case *spec.Schema:
|
||||
return isArrayType(s.Type)
|
||||
case *spec.SchemaProps:
|
||||
return isArrayType(s.Type)
|
||||
case *spec.SimpleSchema:
|
||||
return isArrayType(spec.StringOrArray{s.Type})
|
||||
default:
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
func isPrimitive(item interface{}) bool {
|
||||
switch s := item.(type) {
|
||||
case *spec.Schema:
|
||||
return isPrimitiveType(s.Type)
|
||||
case *spec.SchemaProps:
|
||||
return isPrimitiveType(s.Type)
|
||||
case spec.StringOrArray:
|
||||
return isPrimitiveType(s)
|
||||
default:
|
||||
return false
|
||||
}
|
||||
}
|
||||
Generated
Vendored
+189
-311
@@ -7,6 +7,7 @@ import (
|
||||
"github.com/go-openapi/spec"
|
||||
)
|
||||
|
||||
// StringType For identifying string types
|
||||
const StringType = "string"
|
||||
|
||||
// URLMethodResponse encapsulates these three elements to act as a map key
|
||||
@@ -26,18 +27,19 @@ type URLMethods map[URLMethod]*PathItemOp
|
||||
|
||||
// SpecAnalyser contains all the differences for a Spec
|
||||
type SpecAnalyser struct {
|
||||
Diffs SpecDifferences
|
||||
urlMethods1 URLMethods
|
||||
urlMethods2 URLMethods
|
||||
Definitions1 spec.Definitions
|
||||
Definitions2 spec.Definitions
|
||||
AlreadyComparedDefinitions map[string]bool
|
||||
Diffs SpecDifferences
|
||||
urlMethods1 URLMethods
|
||||
urlMethods2 URLMethods
|
||||
Definitions1 spec.Definitions
|
||||
Definitions2 spec.Definitions
|
||||
ReferencedDefinitions map[string]bool
|
||||
}
|
||||
|
||||
// NewSpecAnalyser returns an empty SpecDiffs
|
||||
func NewSpecAnalyser() *SpecAnalyser {
|
||||
return &SpecAnalyser{
|
||||
Diffs: SpecDifferences{},
|
||||
Diffs: SpecDifferences{},
|
||||
ReferencedDefinitions: map[string]bool{},
|
||||
}
|
||||
}
|
||||
|
||||
@@ -50,9 +52,10 @@ func (sd *SpecAnalyser) Analyse(spec1, spec2 *spec.Swagger) error {
|
||||
|
||||
sd.analyseSpecMetadata(spec1, spec2)
|
||||
sd.analyseEndpoints()
|
||||
sd.analyseParams()
|
||||
sd.analyseRequestParams()
|
||||
sd.analyseEndpointData()
|
||||
sd.analyseResponseParams()
|
||||
sd.AnalyseDefinitions()
|
||||
|
||||
return nil
|
||||
}
|
||||
@@ -94,7 +97,7 @@ func (sd *SpecAnalyser) analyseSpecMetadata(spec1, spec2 *spec.Swagger) {
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: schemesLocation, Code: DeletedSchemes, Compatibility: Breaking, DiffInfo: eachDeleted})
|
||||
}
|
||||
|
||||
// // host should be able to change without any issues?
|
||||
// host should be able to change without any issues?
|
||||
sd.analyseMetaDataProperty(spec1.Info.Description, spec2.Info.Description, ChangedDescripton, NonBreaking)
|
||||
|
||||
// // host should be able to change without any issues?
|
||||
@@ -116,6 +119,32 @@ func (sd *SpecAnalyser) analyseEndpoints() {
|
||||
sd.findAddedEndpoints()
|
||||
}
|
||||
|
||||
// AnalyseDefinitions check for changes to defintion objects not referenced in any endpoint
|
||||
func (sd *SpecAnalyser) AnalyseDefinitions() {
|
||||
alreadyReferenced := map[string]bool{}
|
||||
for k := range sd.ReferencedDefinitions {
|
||||
alreadyReferenced[k] = true
|
||||
}
|
||||
location := DifferenceLocation{Node: &Node{Field: "Spec Definitions"}}
|
||||
for name1, sch := range sd.Definitions1 {
|
||||
schema1 := sch
|
||||
if _, ok := alreadyReferenced[name1]; !ok {
|
||||
childLocation := location.AddNode(&Node{Field: name1})
|
||||
if schema2, ok := sd.Definitions2[name1]; ok {
|
||||
sd.compareSchema(childLocation, &schema1, &schema2)
|
||||
} else {
|
||||
sd.addDiffs(childLocation, []TypeDiff{{Change: DeletedDefinition}})
|
||||
}
|
||||
}
|
||||
}
|
||||
for name2 := range sd.Definitions2 {
|
||||
if _, ok := sd.Definitions1[name2]; !ok {
|
||||
childLocation := location.AddNode(&Node{Field: name2})
|
||||
sd.addDiffs(childLocation, []TypeDiff{{Change: AddedDefinition}})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) analyseEndpointData() {
|
||||
|
||||
for URLMethod, op2 := range sd.urlMethods2 {
|
||||
@@ -124,20 +153,19 @@ func (sd *SpecAnalyser) analyseEndpointData() {
|
||||
location := DifferenceLocation{URL: URLMethod.Path, Method: URLMethod.Method}
|
||||
|
||||
for _, eachAddedTag := range addedTags {
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: location, Code: AddedTag, DiffInfo: eachAddedTag})
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: location, Code: AddedTag, DiffInfo: fmt.Sprintf(`"%s"`, eachAddedTag)})
|
||||
}
|
||||
for _, eachDeletedTag := range deletedTags {
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: location, Code: DeletedTag, DiffInfo: eachDeletedTag})
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: location, Code: DeletedTag, DiffInfo: fmt.Sprintf(`"%s"`, eachDeletedTag)})
|
||||
}
|
||||
|
||||
sd.compareDescripton(location, op1.Operation.Description, op2.Operation.Description)
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) analyseParams() {
|
||||
func (sd *SpecAnalyser) analyseRequestParams() {
|
||||
locations := []string{"query", "path", "body", "header"}
|
||||
|
||||
for _, paramLocation := range locations {
|
||||
@@ -153,7 +181,7 @@ func (sd *SpecAnalyser) analyseParams() {
|
||||
// detect deleted params
|
||||
for paramName1, param1 := range params1 {
|
||||
if _, ok := params2[paramName1]; !ok {
|
||||
childLocation := location.AddNode(getSchemaDiffNode(paramName1, param1.Schema))
|
||||
childLocation := location.AddNode(getSchemaDiffNode(paramName1, ¶m1.SimpleSchema))
|
||||
code := DeletedOptionalParam
|
||||
if param1.Required {
|
||||
code = DeletedRequiredParam
|
||||
@@ -163,12 +191,12 @@ func (sd *SpecAnalyser) analyseParams() {
|
||||
}
|
||||
// detect added changed params
|
||||
for paramName2, param2 := range params2 {
|
||||
//changed?
|
||||
// changed?
|
||||
if param1, ok := params1[paramName2]; ok {
|
||||
sd.compareParams(URLMethod, paramLocation, paramName2, param1, param2)
|
||||
} else {
|
||||
// Added
|
||||
childLocation := location.AddNode(getSchemaDiffNode(paramName2, param2.Schema))
|
||||
childLocation := location.AddNode(getSchemaDiffNode(paramName2, ¶m2.SimpleSchema))
|
||||
code := AddedOptionalParam
|
||||
if param2.Required {
|
||||
code = AddedRequiredParam
|
||||
@@ -183,8 +211,10 @@ func (sd *SpecAnalyser) analyseParams() {
|
||||
|
||||
func (sd *SpecAnalyser) analyseResponseParams() {
|
||||
// Loop through url+methods in spec 2 - check deleted and changed
|
||||
for URLMethod2, op2 := range sd.urlMethods2 {
|
||||
if op1, ok := sd.urlMethods1[URLMethod2]; ok {
|
||||
for eachURLMethodFrom2, op2 := range sd.urlMethods2 {
|
||||
|
||||
// present in both specs? Use key from spec 2 to lookup in spec 1
|
||||
if op1, ok := sd.urlMethods1[eachURLMethodFrom2]; ok {
|
||||
// compare responses for url and method
|
||||
op1Responses := op1.Operation.Responses.StatusCodeResponses
|
||||
op2Responses := op2.Operation.Responses.StatusCodeResponses
|
||||
@@ -192,7 +222,7 @@ func (sd *SpecAnalyser) analyseResponseParams() {
|
||||
// deleted responses
|
||||
for code1 := range op1Responses {
|
||||
if _, ok := op2Responses[code1]; !ok {
|
||||
location := DifferenceLocation{URL: URLMethod2.Path, Method: URLMethod2.Method, Response: code1}
|
||||
location := DifferenceLocation{URL: eachURLMethodFrom2.Path, Method: eachURLMethodFrom2.Method, Response: code1, Node: getSchemaDiffNode("Body", op1Responses[code1].Schema)}
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: location, Code: DeletedResponse})
|
||||
}
|
||||
}
|
||||
@@ -202,39 +232,48 @@ func (sd *SpecAnalyser) analyseResponseParams() {
|
||||
if op1Response, ok := op1Responses[code2]; ok {
|
||||
op1Headers := op1Response.ResponseProps.Headers
|
||||
headerRootNode := getNameOnlyDiffNode("Headers")
|
||||
location := DifferenceLocation{URL: URLMethod2.Path, Method: URLMethod2.Method, Response: code2, Node: headerRootNode}
|
||||
|
||||
// Iterate Spec2 Headers looking for added and updated
|
||||
location := DifferenceLocation{URL: eachURLMethodFrom2.Path, Method: eachURLMethodFrom2.Method, Response: code2, Node: headerRootNode}
|
||||
for op2HeaderName, op2Header := range op2Response.ResponseProps.Headers {
|
||||
if op1Header, ok := op1Headers[op2HeaderName]; ok {
|
||||
sd.compareSimpleSchema(location.AddNode(getNameOnlyDiffNode(op2HeaderName)),
|
||||
&op1Header.SimpleSchema,
|
||||
&op2Header.SimpleSchema, false, false)
|
||||
diffs := sd.CompareProps(forHeader(op1Header), forHeader(op2Header))
|
||||
sd.addDiffs(location, diffs)
|
||||
} else {
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{
|
||||
DifferenceLocation: location.AddNode(getNameOnlyDiffNode(op2HeaderName)),
|
||||
DifferenceLocation: location.AddNode(getSchemaDiffNode(op2HeaderName, &op2Header.SimpleSchema)),
|
||||
Code: AddedResponseHeader})
|
||||
}
|
||||
}
|
||||
for op1HeaderName := range op1Response.ResponseProps.Headers {
|
||||
if _, ok := op2Response.ResponseProps.Headers[op1HeaderName]; !ok {
|
||||
op1Header := op1Response.ResponseProps.Headers[op1HeaderName]
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{
|
||||
DifferenceLocation: location.AddNode(getNameOnlyDiffNode(op1HeaderName)),
|
||||
DifferenceLocation: location.AddNode(getSchemaDiffNode(op1HeaderName, &op1Header.SimpleSchema)),
|
||||
Code: DeletedResponseHeader})
|
||||
}
|
||||
}
|
||||
responseLocation := DifferenceLocation{URL: URLMethod2.Path, Method: URLMethod2.Method, Response: code2}
|
||||
schem := op1Response.Schema
|
||||
node := getNameOnlyDiffNode("NoContent")
|
||||
if schem != nil {
|
||||
node = getSchemaDiffNode("Body", &schem.SchemaProps)
|
||||
}
|
||||
responseLocation := DifferenceLocation{URL: eachURLMethodFrom2.Path,
|
||||
Method: eachURLMethodFrom2.Method,
|
||||
Response: code2,
|
||||
Node: node}
|
||||
sd.compareDescripton(responseLocation, op1Response.Description, op2Response.Description)
|
||||
|
||||
if op1Response.Schema != nil {
|
||||
sd.compareSchema(
|
||||
DifferenceLocation{URL: URLMethod2.Path, Method: URLMethod2.Method, Response: code2},
|
||||
DifferenceLocation{URL: eachURLMethodFrom2.Path, Method: eachURLMethodFrom2.Method, Response: code2, Node: getSchemaDiffNode("Body", op1Response.Schema)},
|
||||
op1Response.Schema,
|
||||
op2Response.Schema, true, true)
|
||||
op2Response.Schema)
|
||||
}
|
||||
} else {
|
||||
// op2Response
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{
|
||||
DifferenceLocation: DifferenceLocation{URL: URLMethod2.Path, Method: URLMethod2.Method, Response: code2},
|
||||
DifferenceLocation: DifferenceLocation{URL: eachURLMethodFrom2.Path, Method: eachURLMethodFrom2.Method, Response: code2, Node: getSchemaDiffNode("Body", op2Response.Schema)},
|
||||
Code: AddedResponse})
|
||||
}
|
||||
}
|
||||
@@ -249,126 +288,51 @@ func addTypeDiff(diffs []TypeDiff, diff TypeDiff) []TypeDiff {
|
||||
return diffs
|
||||
}
|
||||
|
||||
// CheckToFromPrimitiveType check for diff to or from a primitive
|
||||
func (sd *SpecAnalyser) CheckToFromPrimitiveType(diffs []TypeDiff, type1, type2 spec.SchemaProps) []TypeDiff {
|
||||
|
||||
type1IsPrimitive := len(type1.Type) > 0
|
||||
type2IsPrimitive := len(type2.Type) > 0
|
||||
|
||||
// Primitive to Obj or Obj to Primitive
|
||||
if type1IsPrimitive && !type2IsPrimitive {
|
||||
return addTypeDiff(diffs, TypeDiff{Change: ChangedType, FromType: type1.Type[0], ToType: "obj"})
|
||||
}
|
||||
|
||||
if !type1IsPrimitive && type2IsPrimitive {
|
||||
return addTypeDiff(diffs, TypeDiff{Change: ChangedType, FromType: type2.Type[0], ToType: "obj"})
|
||||
}
|
||||
|
||||
return diffs
|
||||
}
|
||||
|
||||
// CheckToFromArrayType check for changes to or from an Array type
|
||||
func (sd *SpecAnalyser) CheckToFromArrayType(diffs []TypeDiff, type1, type2 spec.SchemaProps) []TypeDiff {
|
||||
// Single to Array or Array to Single
|
||||
type1Array := type1.Type[0] == ArrayType
|
||||
type2Array := type2.Type[0] == ArrayType
|
||||
|
||||
if type1Array && !type2Array {
|
||||
return addTypeDiff(diffs, TypeDiff{Change: ChangedType, FromType: "obj", ToType: type2.Type[0]})
|
||||
}
|
||||
|
||||
if !type1Array && type2Array {
|
||||
return addTypeDiff(diffs, TypeDiff{Change: ChangedType, FromType: type1.Type[0], ToType: ArrayType})
|
||||
}
|
||||
|
||||
if type1Array && type2Array {
|
||||
// array
|
||||
// TODO: Items??
|
||||
diffs = addTypeDiff(diffs, compareIntValues("MaxItems", type1.MaxItems, type2.MaxItems, WidenedType, NarrowedType))
|
||||
diffs = addTypeDiff(diffs, compareIntValues("MinItems", type1.MinItems, type2.MinItems, NarrowedType, WidenedType))
|
||||
|
||||
}
|
||||
return diffs
|
||||
}
|
||||
|
||||
// CheckStringTypeChanges checks for changes to or from a string type
|
||||
func (sd *SpecAnalyser) CheckStringTypeChanges(diffs []TypeDiff, type1, type2 spec.SchemaProps) []TypeDiff {
|
||||
// string changes
|
||||
if type1.Type[0] == StringType &&
|
||||
type2.Type[0] == StringType {
|
||||
diffs = addTypeDiff(diffs, compareIntValues("MinLength", type1.MinLength, type2.MinLength, NarrowedType, WidenedType))
|
||||
diffs = addTypeDiff(diffs, compareIntValues("MaxLength", type1.MinLength, type2.MinLength, WidenedType, NarrowedType))
|
||||
if type1.Pattern != type2.Pattern {
|
||||
diffs = addTypeDiff(diffs, TypeDiff{Change: ChangedType, Description: fmt.Sprintf("Pattern Changed:%s->%s", type1.Pattern, type2.Pattern)})
|
||||
}
|
||||
if type1.Type[0] == StringType {
|
||||
if len(type1.Enum) > 0 {
|
||||
enumDiffs := sd.compareEnums(type1.Enum, type2.Enum)
|
||||
diffs = append(diffs, enumDiffs...)
|
||||
}
|
||||
}
|
||||
}
|
||||
return diffs
|
||||
}
|
||||
|
||||
// CheckNumericTypeChanges checks for changes to or from a numeric type
|
||||
func (sd *SpecAnalyser) CheckNumericTypeChanges(diffs []TypeDiff, type1, type2 spec.SchemaProps) []TypeDiff {
|
||||
// Number
|
||||
_, type1IsNumeric := numberWideness[type1.Type[0]]
|
||||
_, type2IsNumeric := numberWideness[type2.Type[0]]
|
||||
|
||||
if type1IsNumeric && type2IsNumeric {
|
||||
diffs = addTypeDiff(diffs, compareFloatValues("Maximum", type1.Maximum, type2.Maximum, WidenedType, NarrowedType))
|
||||
diffs = addTypeDiff(diffs, compareFloatValues("Minimum", type1.Minimum, type2.Minimum, NarrowedType, WidenedType))
|
||||
if type1.ExclusiveMaximum && !type2.ExclusiveMaximum {
|
||||
diffs = addTypeDiff(diffs, TypeDiff{Change: WidenedType, Description: fmt.Sprintf("Exclusive Maximum Removed:%v->%v", type1.ExclusiveMaximum, type2.ExclusiveMaximum)})
|
||||
}
|
||||
if !type1.ExclusiveMaximum && type2.ExclusiveMaximum {
|
||||
diffs = addTypeDiff(diffs, TypeDiff{Change: NarrowedType, Description: fmt.Sprintf("Exclusive Maximum Added:%v->%v", type1.ExclusiveMaximum, type2.ExclusiveMaximum)})
|
||||
}
|
||||
if type1.ExclusiveMinimum && !type2.ExclusiveMinimum {
|
||||
diffs = addTypeDiff(diffs, TypeDiff{Change: WidenedType, Description: fmt.Sprintf("Exclusive Minimum Removed:%v->%v", type1.ExclusiveMaximum, type2.ExclusiveMaximum)})
|
||||
}
|
||||
if !type1.ExclusiveMinimum && type2.ExclusiveMinimum {
|
||||
diffs = addTypeDiff(diffs, TypeDiff{Change: NarrowedType, Description: fmt.Sprintf("Exclusive Minimum Added:%v->%v", type1.ExclusiveMinimum, type2.ExclusiveMinimum)})
|
||||
}
|
||||
}
|
||||
return diffs
|
||||
}
|
||||
|
||||
// CompareTypes computes type specific property diffs
|
||||
func (sd *SpecAnalyser) CompareTypes(type1, type2 spec.SchemaProps) []TypeDiff {
|
||||
// CompareProps computes type specific property diffs
|
||||
func (sd *SpecAnalyser) CompareProps(type1, type2 *spec.SchemaProps) []TypeDiff {
|
||||
|
||||
diffs := []TypeDiff{}
|
||||
|
||||
diffs = sd.CheckToFromPrimitiveType(diffs, type1, type2)
|
||||
diffs = CheckToFromPrimitiveType(diffs, type1, type2)
|
||||
|
||||
if len(diffs) > 0 {
|
||||
return diffs
|
||||
}
|
||||
|
||||
diffs = sd.CheckToFromArrayType(diffs, type1, type2)
|
||||
if isArray(type1) {
|
||||
maxItemDiffs := CompareIntValues("MaxItems", type1.MaxItems, type2.MaxItems, WidenedType, NarrowedType)
|
||||
diffs = append(diffs, maxItemDiffs...)
|
||||
minItemsDiff := CompareIntValues("MinItems", type1.MinItems, type2.MinItems, NarrowedType, WidenedType)
|
||||
diffs = append(diffs, minItemsDiff...)
|
||||
}
|
||||
|
||||
if len(diffs) > 0 {
|
||||
return diffs
|
||||
}
|
||||
|
||||
// check type hierarchy change eg string -> integer = NarrowedChange
|
||||
//Type
|
||||
//Format
|
||||
diffs = CheckRefChange(diffs, type1, type2)
|
||||
if len(diffs) > 0 {
|
||||
return diffs
|
||||
}
|
||||
|
||||
if !(isPrimitiveType(type1.Type) && isPrimitiveType(type2.Type)) {
|
||||
return diffs
|
||||
}
|
||||
|
||||
// check primitive type hierarchy change eg string -> integer = NarrowedChange
|
||||
if type1.Type[0] != type2.Type[0] ||
|
||||
type1.Format != type2.Format {
|
||||
diff := getTypeHierarchyChange(primitiveTypeString(type1.Type[0], type1.Format), primitiveTypeString(type2.Type[0], type2.Format))
|
||||
diffs = addTypeDiff(diffs, diff)
|
||||
}
|
||||
|
||||
diffs = sd.CheckStringTypeChanges(diffs, type1, type2)
|
||||
diffs = CheckStringTypeChanges(diffs, type1, type2)
|
||||
|
||||
if len(diffs) > 0 {
|
||||
return diffs
|
||||
}
|
||||
|
||||
diffs = sd.CheckNumericTypeChanges(diffs, type1, type2)
|
||||
diffs = checkNumericTypeChanges(diffs, type1, type2)
|
||||
|
||||
if len(diffs) > 0 {
|
||||
return diffs
|
||||
@@ -385,49 +349,37 @@ func (sd *SpecAnalyser) compareParams(urlMethod URLMethod, location string, name
|
||||
sd.compareDescripton(paramLocation, param1.Description, param2.Description)
|
||||
|
||||
if param1.Schema != nil && param2.Schema != nil {
|
||||
childLocation = childLocation.AddNode(getSchemaDiffNode(name, param2.Schema))
|
||||
sd.compareSchema(childLocation, param1.Schema, param2.Schema, param1.Required, param2.Required)
|
||||
}
|
||||
diffs := sd.CompareTypes(forParam(param1), forParam(param2))
|
||||
|
||||
childLocation = childLocation.AddNode(getSchemaDiffNode(name, param2.Schema))
|
||||
for _, eachDiff := range diffs {
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{
|
||||
DifferenceLocation: childLocation,
|
||||
Code: eachDiff.Change,
|
||||
DiffInfo: eachDiff.Description})
|
||||
}
|
||||
if param1.Required != param2.Required {
|
||||
code := ChangedRequiredToOptionalParam
|
||||
if param2.Required {
|
||||
code = ChangedOptionalToRequiredParam
|
||||
if len(name) > 0 {
|
||||
childLocation = childLocation.AddNode(getSchemaDiffNode(name, param2.Schema))
|
||||
}
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: childLocation, Code: code})
|
||||
|
||||
sd.compareSchema(childLocation, param1.Schema, param2.Schema)
|
||||
}
|
||||
diffs := sd.CompareProps(forParam(param1), forParam(param2))
|
||||
|
||||
childLocation = childLocation.AddNode(getSchemaDiffNode(name, ¶m2.SimpleSchema))
|
||||
if len(diffs) > 0 {
|
||||
sd.addDiffs(childLocation, diffs)
|
||||
}
|
||||
|
||||
diffs = CheckToFromRequired(param1.Required, param2.Required)
|
||||
if len(diffs) > 0 {
|
||||
sd.addDiffs(childLocation, diffs)
|
||||
}
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) compareSimpleSchema(location DifferenceLocation, schema1, schema2 *spec.SimpleSchema, required1, required2 bool) {
|
||||
if schema1 == nil || schema2 == nil {
|
||||
return
|
||||
}
|
||||
|
||||
if schema1.Type == ArrayType {
|
||||
refSchema1 := schema1.Items.SimpleSchema
|
||||
refSchema2 := schema2.Items.SimpleSchema
|
||||
|
||||
childLocation := location.AddNode(getSimpleSchemaDiffNode("", schema1))
|
||||
sd.compareSimpleSchema(childLocation, &refSchema1, &refSchema2, required1, required2)
|
||||
return
|
||||
}
|
||||
if required1 != required2 {
|
||||
code := AddedRequiredProperty
|
||||
if required1 {
|
||||
code = ChangedRequiredToOptional
|
||||
|
||||
func (sd *SpecAnalyser) addTypeDiff(location DifferenceLocation, diff *TypeDiff) {
|
||||
diffCopy := diff
|
||||
desc := diffCopy.Description
|
||||
if len(desc) == 0 {
|
||||
if diffCopy.FromType != diffCopy.ToType {
|
||||
desc = fmt.Sprintf("%s -> %s", diffCopy.FromType, diffCopy.ToType)
|
||||
}
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: location, Code: code})
|
||||
}
|
||||
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{
|
||||
DifferenceLocation: location,
|
||||
Code: diffCopy.Change,
|
||||
DiffInfo: desc})
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) compareDescripton(location DifferenceLocation, desc1, desc2 string) {
|
||||
@@ -440,145 +392,96 @@ func (sd *SpecAnalyser) compareDescripton(location DifferenceLocation, desc1, de
|
||||
}
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: location, Code: code})
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) compareSchema(location DifferenceLocation, schema1, schema2 *spec.Schema, required1, required2 bool) {
|
||||
func isPrimitiveType(item spec.StringOrArray) bool {
|
||||
return len(item) > 0 && item[0] != ArrayType && item[0] != ObjectType
|
||||
}
|
||||
|
||||
if schema1 == nil || schema2 == nil {
|
||||
func isArrayType(item spec.StringOrArray) bool {
|
||||
return len(item) > 0 && item[0] == ArrayType
|
||||
}
|
||||
func (sd *SpecAnalyser) getRefSchemaFromSpec1(ref spec.Ref) (*spec.Schema, string) {
|
||||
return sd.schemaFromRef(ref, &sd.Definitions1)
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) getRefSchemaFromSpec2(ref spec.Ref) (*spec.Schema, string) {
|
||||
return sd.schemaFromRef(ref, &sd.Definitions2)
|
||||
}
|
||||
|
||||
// CompareSchemaFn Fn spec for comparing schemas
|
||||
type CompareSchemaFn func(location DifferenceLocation, schema1, schema2 *spec.Schema)
|
||||
|
||||
func (sd *SpecAnalyser) compareSchema(location DifferenceLocation, schema1, schema2 *spec.Schema) {
|
||||
|
||||
refDiffs := []TypeDiff{}
|
||||
refDiffs = CheckRefChange(refDiffs, schema1, schema2)
|
||||
if len(refDiffs) > 0 {
|
||||
for _, d := range refDiffs {
|
||||
diff := d
|
||||
sd.addTypeDiff(location, &diff)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
if isRefType(schema1) {
|
||||
schema1, _ = sd.schemaFromRef(getRef(schema1), &sd.Definitions1)
|
||||
}
|
||||
if isRefType(schema2) {
|
||||
schema2, _ = sd.schemaFromRef(getRef(schema2), &sd.Definitions2)
|
||||
}
|
||||
|
||||
sd.compareDescripton(location, schema1.Description, schema2.Description)
|
||||
|
||||
if len(schema1.Type) == 0 {
|
||||
refSchema1, definition1 := sd.schemaFromRef(schema1, &sd.Definitions1)
|
||||
refSchema2, definition2 := sd.schemaFromRef(schema2, &sd.Definitions2)
|
||||
|
||||
if len(definition1) > 0 {
|
||||
info := fmt.Sprintf("[%s -> %s]", definition1, definition2)
|
||||
|
||||
if definition1 != definition2 {
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: location,
|
||||
Code: ChangedType,
|
||||
DiffInfo: info,
|
||||
})
|
||||
}
|
||||
sd.compareSchema(location, refSchema1, refSchema2, required1, required2)
|
||||
return
|
||||
}
|
||||
} else {
|
||||
if schema1.Type[0] == ArrayType {
|
||||
refSchema1, definition1 := sd.schemaFromRef(schema1.Items.Schema, &sd.Definitions1)
|
||||
refSchema2, _ := sd.schemaFromRef(schema2.Items.Schema, &sd.Definitions2)
|
||||
|
||||
if len(definition1) > 0 {
|
||||
childLocation := location.AddNode(getSchemaDiffNode("", schema1))
|
||||
sd.compareSchema(childLocation, refSchema1, refSchema2, required1, required2)
|
||||
return
|
||||
}
|
||||
|
||||
}
|
||||
diffs := sd.CompareTypes(schema1.SchemaProps, schema2.SchemaProps)
|
||||
|
||||
for _, eachTypeDiff := range diffs {
|
||||
if eachTypeDiff.Change != NoChangeDetected {
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: location, Code: eachTypeDiff.Change, DiffInfo: eachTypeDiff.Description})
|
||||
}
|
||||
}
|
||||
typeDiffs := sd.CompareProps(&schema1.SchemaProps, &schema2.SchemaProps)
|
||||
if len(typeDiffs) > 0 {
|
||||
sd.addDiffs(location, typeDiffs)
|
||||
return
|
||||
}
|
||||
|
||||
if required1 != required2 {
|
||||
code := AddedRequiredProperty
|
||||
if required1 {
|
||||
code = ChangedRequiredToOptional
|
||||
|
||||
}
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: location, Code: code})
|
||||
}
|
||||
requiredProps2 := sliceToStrMap(schema2.Required)
|
||||
requiredProps1 := sliceToStrMap(schema1.Required)
|
||||
schema1Props := sd.propertiesFor(schema1, &sd.Definitions1)
|
||||
schema2Props := sd.propertiesFor(schema2, &sd.Definitions2)
|
||||
// find deleted and changed properties
|
||||
for eachProp1Name, eachProp1 := range schema1Props {
|
||||
eachProp1 := eachProp1
|
||||
_, required1 := requiredProps1[eachProp1Name]
|
||||
_, required2 := requiredProps2[eachProp1Name]
|
||||
childLoc := sd.addChildDiffNode(location, eachProp1Name, &eachProp1)
|
||||
|
||||
if eachProp2, ok := schema2Props[eachProp1Name]; ok {
|
||||
sd.compareSchema(childLoc, &eachProp1, &eachProp2, required1, required2)
|
||||
sd.compareDescripton(childLoc, eachProp1.Description, eachProp2.Description)
|
||||
} else {
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: childLoc, Code: DeletedProperty})
|
||||
}
|
||||
if isArray(schema1) {
|
||||
sd.compareSchema(location, schema1.Items.Schema, schema2.Items.Schema)
|
||||
}
|
||||
|
||||
// find added properties
|
||||
for eachProp2Name, eachProp2 := range schema2.Properties {
|
||||
eachProp2 := eachProp2
|
||||
if _, ok := schema1.Properties[eachProp2Name]; !ok {
|
||||
childLoc := sd.addChildDiffNode(location, eachProp2Name, &eachProp2)
|
||||
_, required2 := requiredProps2[eachProp2Name]
|
||||
code := AddedProperty
|
||||
if required2 {
|
||||
code = AddedRequiredProperty
|
||||
}
|
||||
sd.Diffs = sd.Diffs.addDiff(SpecDifference{DifferenceLocation: childLoc, Code: code})
|
||||
diffs := CompareProperties(location, schema1, schema2, sd.getRefSchemaFromSpec1, sd.getRefSchemaFromSpec2, sd.compareSchema)
|
||||
for _, diff := range diffs {
|
||||
sd.Diffs = sd.Diffs.addDiff(diff)
|
||||
}
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) addDiffs(location DifferenceLocation, diffs []TypeDiff) {
|
||||
for _, e := range diffs {
|
||||
eachTypeDiff := e
|
||||
if eachTypeDiff.Change != NoChangeDetected {
|
||||
sd.addTypeDiff(location, &eachTypeDiff)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) addChildDiffNode(location DifferenceLocation, propName string, propSchema *spec.Schema) DifferenceLocation {
|
||||
newLoc := location
|
||||
if newLoc.Node != nil {
|
||||
newLoc.Node = newLoc.Node.Copy()
|
||||
}
|
||||
|
||||
childNode := sd.fromSchemaProps(propName, &propSchema.SchemaProps)
|
||||
if newLoc.Node != nil {
|
||||
newLoc.Node.AddLeafNode(&childNode)
|
||||
func addChildDiffNode(location DifferenceLocation, propName string, propSchema *spec.Schema) DifferenceLocation {
|
||||
newNode := location.Node
|
||||
childNode := fromSchemaProps(propName, &propSchema.SchemaProps)
|
||||
if newNode != nil {
|
||||
newNode = newNode.Copy()
|
||||
newNode.AddLeafNode(&childNode)
|
||||
} else {
|
||||
newLoc.Node = &childNode
|
||||
newNode = &childNode
|
||||
}
|
||||
return DifferenceLocation{
|
||||
URL: location.URL,
|
||||
Method: location.Method,
|
||||
Response: location.Response,
|
||||
Node: newNode,
|
||||
}
|
||||
return newLoc
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) fromSchemaProps(fieldName string, props *spec.SchemaProps) Node {
|
||||
func fromSchemaProps(fieldName string, props *spec.SchemaProps) Node {
|
||||
node := Node{}
|
||||
node.IsArray = props.Type[0] == ArrayType
|
||||
if !node.IsArray {
|
||||
node.TypeName = props.Type[0]
|
||||
}
|
||||
node.TypeName, node.IsArray = getSchemaType(props)
|
||||
node.Field = fieldName
|
||||
return node
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) compareEnums(left, right []interface{}) []TypeDiff {
|
||||
diffs := []TypeDiff{}
|
||||
|
||||
leftStrs := []string{}
|
||||
rightStrs := []string{}
|
||||
for _, eachLeft := range left {
|
||||
leftStrs = append(leftStrs, fmt.Sprintf("%v", eachLeft))
|
||||
}
|
||||
for _, eachRight := range right {
|
||||
rightStrs = append(rightStrs, fmt.Sprintf("%v", eachRight))
|
||||
}
|
||||
added, deleted, _ := fromStringArray(leftStrs).DiffsTo(rightStrs)
|
||||
if len(added) > 0 {
|
||||
typeChange := strings.Join(added, ",")
|
||||
diffs = append(diffs, TypeDiff{Change: AddedEnumValue, Description: typeChange})
|
||||
}
|
||||
if len(deleted) > 0 {
|
||||
typeChange := strings.Join(deleted, ",")
|
||||
diffs = append(diffs, TypeDiff{Change: DeletedEnumValue, Description: typeChange})
|
||||
}
|
||||
|
||||
return diffs
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) findAddedEndpoints() {
|
||||
for URLMethod := range sd.urlMethods2 {
|
||||
if _, ok := sd.urlMethods1[URLMethod]; !ok {
|
||||
@@ -607,48 +510,23 @@ func (sd *SpecAnalyser) analyseMetaDataProperty(item1, item2 string, codeIfDiff
|
||||
}
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) schemaFromRef(schema *spec.Schema, defns *spec.Definitions) (actualSchema *spec.Schema, definitionName string) {
|
||||
ref := schema.Ref
|
||||
url := ref.GetURL()
|
||||
if url == nil {
|
||||
return schema, ""
|
||||
}
|
||||
fragmentParts := strings.Split(url.Fragment, "/")
|
||||
numParts := len(fragmentParts)
|
||||
if numParts == 0 {
|
||||
return schema, ""
|
||||
}
|
||||
|
||||
definitionName = fragmentParts[numParts-1]
|
||||
func (sd *SpecAnalyser) schemaFromRef(ref spec.Ref, defns *spec.Definitions) (actualSchema *spec.Schema, definitionName string) {
|
||||
definitionName = definitionFromRef(ref)
|
||||
foundSchema, ok := (*defns)[definitionName]
|
||||
if !ok {
|
||||
return nil, definitionName
|
||||
}
|
||||
sd.ReferencedDefinitions[definitionName] = true
|
||||
actualSchema = &foundSchema
|
||||
return
|
||||
|
||||
}
|
||||
|
||||
func (sd *SpecAnalyser) propertiesFor(schema *spec.Schema, defns *spec.Definitions) map[string]spec.Schema {
|
||||
schemaFromRef, _ := sd.schemaFromRef(schema, defns)
|
||||
schema = schemaFromRef
|
||||
props := map[string]spec.Schema{}
|
||||
|
||||
if schema.Properties != nil {
|
||||
for name, prop := range schema.Properties {
|
||||
prop := prop
|
||||
eachProp, _ := sd.schemaFromRef(&prop, defns)
|
||||
props[name] = *eachProp
|
||||
}
|
||||
}
|
||||
for _, eachAllOf := range schema.AllOf {
|
||||
eachAllOf := eachAllOf
|
||||
eachAllOfActual, _ := sd.schemaFromRef(&eachAllOf, defns)
|
||||
for name, prop := range eachAllOfActual.Properties {
|
||||
prop := prop
|
||||
eachProp, _ := sd.schemaFromRef(&prop, defns)
|
||||
props[name] = *eachProp
|
||||
}
|
||||
}
|
||||
return props
|
||||
// PropertyDefn combines a property with its required-ness
|
||||
type PropertyDefn struct {
|
||||
Schema *spec.Schema
|
||||
Required bool
|
||||
}
|
||||
|
||||
// PropertyMap a unified map including all AllOf fields
|
||||
type PropertyMap map[string]PropertyDefn
|
||||
Generated
Vendored
+21
-20
@@ -6,6 +6,7 @@ import (
|
||||
"fmt"
|
||||
"io"
|
||||
"sort"
|
||||
"strings"
|
||||
)
|
||||
|
||||
// SpecDifference encapsulates the details of an individual diff in part of a spec
|
||||
@@ -89,37 +90,37 @@ func (sd SpecDifference) String() string {
|
||||
prefix := ""
|
||||
direction := ""
|
||||
|
||||
if isResponse {
|
||||
direction = " Response"
|
||||
if hasMethod {
|
||||
if hasURL {
|
||||
if hasMethod {
|
||||
prefix = fmt.Sprintf("%s:%s -> %d", sd.DifferenceLocation.URL, sd.DifferenceLocation.Method, sd.DifferenceLocation.Response)
|
||||
} else {
|
||||
prefix = fmt.Sprintf("%s ", sd.DifferenceLocation.URL)
|
||||
}
|
||||
prefix = fmt.Sprintf("%s:%s", sd.DifferenceLocation.URL, sd.DifferenceLocation.Method)
|
||||
}
|
||||
if isResponse {
|
||||
prefix += fmt.Sprintf(" -> %d", sd.DifferenceLocation.Response)
|
||||
direction = "Response"
|
||||
} else {
|
||||
direction = "Request"
|
||||
}
|
||||
} else {
|
||||
if hasURL {
|
||||
if hasMethod {
|
||||
direction = " Request"
|
||||
prefix = fmt.Sprintf("%s:%s", sd.DifferenceLocation.URL, sd.DifferenceLocation.Method)
|
||||
} else {
|
||||
prefix = fmt.Sprintf("%s ", sd.DifferenceLocation.URL)
|
||||
}
|
||||
} else {
|
||||
prefix = " Metadata"
|
||||
}
|
||||
prefix = sd.DifferenceLocation.URL
|
||||
}
|
||||
|
||||
paramOrPropertyLocation := ""
|
||||
if sd.DifferenceLocation.Node != nil {
|
||||
paramOrPropertyLocation = " - " + sd.DifferenceLocation.Node.String() + " "
|
||||
paramOrPropertyLocation = sd.DifferenceLocation.Node.String()
|
||||
}
|
||||
optionalInfo := ""
|
||||
if sd.DiffInfo != "" {
|
||||
optionalInfo = fmt.Sprintf(" <%s>", sd.DiffInfo)
|
||||
optionalInfo = sd.DiffInfo
|
||||
}
|
||||
return fmt.Sprintf("%s%s%s- %s%s", prefix, direction, paramOrPropertyLocation, sd.Code.Description(), optionalInfo)
|
||||
|
||||
items := []string{}
|
||||
for _, item := range []string{prefix, direction, paramOrPropertyLocation, sd.Code.Description(), optionalInfo} {
|
||||
if item != "" {
|
||||
items = append(items, item)
|
||||
}
|
||||
}
|
||||
return strings.Join(items, " - ")
|
||||
// return fmt.Sprintf("%s%s%s - %s%s", prefix, direction, paramOrPropertyLocation, sd.Code.Description(), optionalInfo)
|
||||
}
|
||||
|
||||
func (sd SpecDifferences) addDiff(diff SpecDifference) SpecDifferences {
|
||||
|
||||
Generated
Vendored
+57
-64
@@ -1,8 +1,6 @@
|
||||
package diff
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
"github.com/go-openapi/spec"
|
||||
)
|
||||
|
||||
@@ -32,8 +30,28 @@ func forItems(items *spec.Items) *spec.Schema {
|
||||
return &schema
|
||||
}
|
||||
|
||||
func forParam(param spec.Parameter) spec.SchemaProps {
|
||||
return spec.SchemaProps{
|
||||
func forHeader(header spec.Header) *spec.SchemaProps {
|
||||
return &spec.SchemaProps{
|
||||
Type: []string{header.Type},
|
||||
Format: header.Format,
|
||||
Items: &spec.SchemaOrArray{Schema: forItems(header.Items)},
|
||||
Maximum: header.Maximum,
|
||||
ExclusiveMaximum: header.ExclusiveMaximum,
|
||||
Minimum: header.Minimum,
|
||||
ExclusiveMinimum: header.ExclusiveMinimum,
|
||||
MaxLength: header.MaxLength,
|
||||
MinLength: header.MinLength,
|
||||
Pattern: header.Pattern,
|
||||
MaxItems: header.MaxItems,
|
||||
MinItems: header.MinItems,
|
||||
UniqueItems: header.UniqueItems,
|
||||
MultipleOf: header.MultipleOf,
|
||||
Enum: header.Enum,
|
||||
}
|
||||
}
|
||||
|
||||
func forParam(param spec.Parameter) *spec.SchemaProps {
|
||||
return &spec.SchemaProps{
|
||||
Type: []string{param.Type},
|
||||
Format: param.Format,
|
||||
Items: &spec.SchemaOrArray{Schema: forItems(param.Items)},
|
||||
@@ -95,76 +113,51 @@ func getURLMethodsFor(spec *spec.Swagger) URLMethods {
|
||||
return returnURLMethods
|
||||
}
|
||||
|
||||
func sliceToStrMap(elements []string) map[string]bool {
|
||||
elementMap := make(map[string]bool)
|
||||
for _, s := range elements {
|
||||
elementMap[s] = true
|
||||
}
|
||||
return elementMap
|
||||
}
|
||||
|
||||
func isStringType(typeName string) bool {
|
||||
return typeName == "string" || typeName == "password"
|
||||
}
|
||||
|
||||
const objType = "obj"
|
||||
// SchemaFromRefFn define this to get a schema for a ref
|
||||
type SchemaFromRefFn func(spec.Ref) (*spec.Schema, string)
|
||||
|
||||
func getTypeHierarchyChange(type1, type2 string) TypeDiff {
|
||||
if type1 == type2 {
|
||||
return TypeDiff{Change: NoChangeDetected, Description: ""}
|
||||
func propertiesFor(schema *spec.Schema, getRefFn SchemaFromRefFn) PropertyMap {
|
||||
if isRefType(schema) {
|
||||
schema, _ = getRefFn(schema.Ref)
|
||||
}
|
||||
fromType := type1
|
||||
if fromType == "" {
|
||||
fromType = objType
|
||||
props := PropertyMap{}
|
||||
|
||||
requiredProps := schema.Required
|
||||
requiredMap := map[string]bool{}
|
||||
for _, prop := range requiredProps {
|
||||
requiredMap[prop] = true
|
||||
}
|
||||
toType := type2
|
||||
if toType == "" {
|
||||
toType = objType
|
||||
}
|
||||
diffDescription := fmt.Sprintf("%s -> %s", fromType, toType)
|
||||
if isStringType(type1) && !isStringType(type2) {
|
||||
return TypeDiff{Change: NarrowedType, Description: diffDescription}
|
||||
}
|
||||
if !isStringType(type1) && isStringType(type2) {
|
||||
return TypeDiff{Change: WidenedType, Description: diffDescription}
|
||||
}
|
||||
type1Wideness, type1IsNumeric := numberWideness[type1]
|
||||
type2Wideness, type2IsNumeric := numberWideness[type2]
|
||||
if type1IsNumeric && type2IsNumeric {
|
||||
if type1Wideness == type2Wideness {
|
||||
return TypeDiff{Change: ChangedToCompatibleType, Description: diffDescription}
|
||||
}
|
||||
if type1Wideness > type2Wideness {
|
||||
return TypeDiff{Change: NarrowedType, Description: diffDescription}
|
||||
}
|
||||
if type1Wideness < type2Wideness {
|
||||
return TypeDiff{Change: WidenedType, Description: diffDescription}
|
||||
|
||||
if schema.Properties != nil {
|
||||
for name, prop := range schema.Properties {
|
||||
prop := prop
|
||||
required := requiredMap[name]
|
||||
props[name] = PropertyDefn{Schema: &prop, Required: required}
|
||||
}
|
||||
}
|
||||
return TypeDiff{Change: ChangedType, Description: diffDescription}
|
||||
for _, e := range schema.AllOf {
|
||||
eachAllOf := e
|
||||
allOfMap := propertiesFor(&eachAllOf, getRefFn)
|
||||
for name, prop := range allOfMap {
|
||||
props[name] = prop
|
||||
}
|
||||
}
|
||||
return props
|
||||
}
|
||||
|
||||
func compareFloatValues(fieldName string, val1 *float64, val2 *float64, ifGreaterCode SpecChangeCode, ifLessCode SpecChangeCode) TypeDiff {
|
||||
if val1 != nil && val2 != nil {
|
||||
if *val2 > *val1 {
|
||||
return TypeDiff{Change: ifGreaterCode, Description: fmt.Sprintf("%s %f->%f", fieldName, *val1, *val2)}
|
||||
}
|
||||
if *val2 < *val1 {
|
||||
return TypeDiff{Change: ifLessCode, Description: fmt.Sprintf("%s %f->%f", fieldName, *val1, *val2)}
|
||||
}
|
||||
func getRef(item interface{}) spec.Ref {
|
||||
switch s := item.(type) {
|
||||
case *spec.Refable:
|
||||
return s.Ref
|
||||
case *spec.Schema:
|
||||
return s.Ref
|
||||
case *spec.SchemaProps:
|
||||
return s.Ref
|
||||
default:
|
||||
return spec.Ref{}
|
||||
}
|
||||
return TypeDiff{Change: NoChangeDetected, Description: ""}
|
||||
}
|
||||
|
||||
func compareIntValues(fieldName string, val1 *int64, val2 *int64, ifGreaterCode SpecChangeCode, ifLessCode SpecChangeCode) TypeDiff {
|
||||
if val1 != nil && val2 != nil {
|
||||
if *val2 > *val1 {
|
||||
return TypeDiff{Change: ifGreaterCode, Description: fmt.Sprintf("%s %d->%d", fieldName, *val1, *val2)}
|
||||
}
|
||||
if *val2 < *val1 {
|
||||
return TypeDiff{Change: ifLessCode, Description: fmt.Sprintf("%s %d->%d", fieldName, *val1, *val2)}
|
||||
}
|
||||
|
||||
}
|
||||
return TypeDiff{Change: NoChangeDetected, Description: ""}
|
||||
}
|
||||
+7
-3
@@ -47,11 +47,12 @@ func writeToFile(swspec *spec.Swagger, pretty bool, format string, output string
|
||||
var err error
|
||||
asJSON := format == "json"
|
||||
|
||||
if pretty && asJSON {
|
||||
switch {
|
||||
case pretty && asJSON:
|
||||
b, err = json.MarshalIndent(swspec, "", " ")
|
||||
} else if asJSON {
|
||||
case asJSON:
|
||||
b, err = json.Marshal(swspec)
|
||||
} else {
|
||||
default:
|
||||
// marshals as YAML
|
||||
b, err = json.Marshal(swspec)
|
||||
if err == nil {
|
||||
@@ -62,12 +63,15 @@ func writeToFile(swspec *spec.Swagger, pretty bool, format string, output string
|
||||
b, err = yaml.Marshal(d)
|
||||
}
|
||||
}
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
if output == "" {
|
||||
fmt.Println(string(b))
|
||||
return nil
|
||||
}
|
||||
|
||||
return ioutil.WriteFile(output, b, 0644) // #nosec
|
||||
}
|
||||
+1
@@ -24,4 +24,5 @@ type Generate struct {
|
||||
Server *generate.Server `command:"server"`
|
||||
Spec *generate.SpecFile `command:"spec"`
|
||||
Client *generate.Client `command:"client"`
|
||||
Markdown *generate.Markdown `command:"markdown"`
|
||||
}
|
||||
Generated
Vendored
+33
@@ -0,0 +1,33 @@
|
||||
package generate
|
||||
|
||||
import (
|
||||
"github.com/go-swagger/go-swagger/generator"
|
||||
"github.com/jessevdk/go-flags"
|
||||
)
|
||||
|
||||
// Markdown generates a markdown representation of the spec
|
||||
type Markdown struct {
|
||||
WithShared
|
||||
WithModels
|
||||
WithOperations
|
||||
|
||||
Output flags.Filename `long:"output" short:"" description:"the file to write the generated markdown." default:"markdown.md"`
|
||||
}
|
||||
|
||||
func (m Markdown) apply(opts *generator.GenOpts) {
|
||||
m.Shared.apply(opts)
|
||||
m.Models.apply(opts)
|
||||
m.Operations.apply(opts)
|
||||
}
|
||||
|
||||
func (m *Markdown) generate(opts *generator.GenOpts) error {
|
||||
return generator.GenerateMarkdown(string(m.Output), m.Models.Models, m.Operations.Operations, opts)
|
||||
}
|
||||
|
||||
func (m Markdown) log(rp string) {
|
||||
}
|
||||
|
||||
// Execute runs this command
|
||||
func (m *Markdown) Execute(args []string) error {
|
||||
return createSwagger(m)
|
||||
}
|
||||
+1
-1
@@ -52,7 +52,7 @@ type Server struct {
|
||||
Name string `long:"name" short:"A" description:"the name of the application, defaults to a mangled value of info.title"`
|
||||
// TODO(fredbi): CmdName string `long:"cmd-name" short:"A" description:"the name of the server command, when main is generated (defaults to {name}-server)"`
|
||||
|
||||
//deprecated flags
|
||||
// deprecated flags
|
||||
WithContext bool `long:"with-context" description:"handlers get a context as first arg (deprecated)"`
|
||||
}
|
||||
|
||||
|
||||
+3
@@ -80,10 +80,13 @@ type sharedCommand interface {
|
||||
type schemeOptions struct {
|
||||
Principal string `short:"P" long:"principal" description:"the model to use for the security principal"`
|
||||
DefaultScheme string `long:"default-scheme" description:"the default scheme for this API" default:"http"`
|
||||
|
||||
PrincipalIface bool `long:"principal-is-interface" description:"the security principal provided is an interface, not a struct"`
|
||||
}
|
||||
|
||||
func (so schemeOptions) apply(opts *generator.GenOpts) {
|
||||
opts.Principal = so.Principal
|
||||
opts.PrincipalCustomIface = so.PrincipalIface
|
||||
opts.DefaultScheme = so.DefaultScheme
|
||||
}
|
||||
|
||||
|
||||
+9
-1
@@ -16,7 +16,8 @@ import (
|
||||
|
||||
const (
|
||||
// Output messages
|
||||
nothingToDo = "nothing to do. Need some swagger files to merge.\nUSAGE: swagger mixin [-c <expected#Collisions>] <primary-swagger-file> <mixin-swagger-file...>"
|
||||
nothingToDo = "nothing to do. Need some swagger files to merge.\nUSAGE: swagger mixin [-c <expected#Collisions>] <primary-swagger-file> <mixin-swagger-file...>"
|
||||
ignoreConflictsAndCollisionsSpecified = "both the flags ignore conflicts and collisions were specified. These have conflicting meaning so please only specify one"
|
||||
)
|
||||
|
||||
// MixinSpec holds command line flag definitions specific to the mixin
|
||||
@@ -28,6 +29,7 @@ type MixinSpec struct {
|
||||
Output flags.Filename `long:"output" short:"o" description:"the file to write to"`
|
||||
KeepSpecOrder bool `long:"keep-spec-order" description:"Keep schema properties order identical to spec file"`
|
||||
Format string `long:"format" description:"the format for the spec document" default:"json" choice:"yaml" choice:"json"`
|
||||
IgnoreConflicts bool `long:"ignore-conflicts" description:"Ignore conflict"`
|
||||
}
|
||||
|
||||
// Execute runs the mixin command which merges Swagger 2.0 specs into
|
||||
@@ -52,6 +54,9 @@ func (c *MixinSpec) Execute(args []string) error {
|
||||
if len(args) < 2 {
|
||||
return errors.New(nothingToDo)
|
||||
}
|
||||
if c.IgnoreConflicts && c.ExpectedCollisionCount != 0 {
|
||||
return errors.New(ignoreConflictsAndCollisionsSpecified)
|
||||
}
|
||||
|
||||
log.Printf("args[0] = %v\n", args[0])
|
||||
log.Printf("args[1:] = %v\n", args[1:])
|
||||
@@ -65,6 +70,9 @@ func (c *MixinSpec) Execute(args []string) error {
|
||||
return err
|
||||
}
|
||||
|
||||
if c.IgnoreConflicts {
|
||||
return nil
|
||||
}
|
||||
if len(collisions) != int(c.ExpectedCollisionCount) {
|
||||
if len(collisions) != 0 {
|
||||
// use bash $? to get actual # collisions
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ type ServeCmd struct {
|
||||
NoUI bool `long:"no-ui" description:"when present, only the swagger spec will be served"`
|
||||
Flatten bool `long:"flatten" description:"when present, flatten the swagger spec before serving it"`
|
||||
Port int `long:"port" short:"p" description:"the port to serve this site" env:"PORT"`
|
||||
Host string `long:"host" description:"the interface to serve this site, defaults to 0.0.0.0" env:"HOST"`
|
||||
Host string `long:"host" description:"the interface to serve this site, defaults to 0.0.0.0" default:"0.0.0.0" env:"HOST"`
|
||||
}
|
||||
|
||||
// Execute the serve command
|
||||
|
||||
+12
-1
@@ -1,6 +1,9 @@
|
||||
package commands
|
||||
|
||||
import "fmt"
|
||||
import (
|
||||
"fmt"
|
||||
"runtime/debug"
|
||||
)
|
||||
|
||||
var (
|
||||
// Version for the swagger command
|
||||
@@ -16,9 +19,17 @@ type PrintVersion struct {
|
||||
// Execute this command
|
||||
func (p *PrintVersion) Execute(args []string) error {
|
||||
if Version == "" {
|
||||
if info, available := debug.ReadBuildInfo(); available && info.Main.Version != "(devel)" {
|
||||
// built from source, with module (e.g. go get)
|
||||
fmt.Println("version:", info.Main.Version)
|
||||
fmt.Println("commit:", fmt.Sprintf("(unknown, mod sum: %q)", info.Main.Sum))
|
||||
return nil
|
||||
}
|
||||
// built from source, local repo
|
||||
fmt.Println("dev")
|
||||
return nil
|
||||
}
|
||||
// released version
|
||||
fmt.Println("version:", Version)
|
||||
fmt.Println("commit:", Commit)
|
||||
|
||||
|
||||
+5
-2
@@ -41,7 +41,7 @@ func main() {
|
||||
// Recovering from internal panics
|
||||
// Stack may be printed in Debug mode
|
||||
// Need import "runtime/debug".
|
||||
//defer func() {
|
||||
// defer func() {
|
||||
// r := recover()
|
||||
// if r != nil {
|
||||
// log.Printf("Fatal error:", r)
|
||||
@@ -50,7 +50,7 @@ func main() {
|
||||
// }
|
||||
// os.Exit(1)
|
||||
// }
|
||||
//}()
|
||||
// }()
|
||||
|
||||
parser := flags.NewParser(&opts, flags.Default)
|
||||
parser.ShortDescription = "helps you keep your API well described"
|
||||
@@ -123,6 +123,9 @@ It aims to represent the contract of your API with a language agnostic descripti
|
||||
case "operation":
|
||||
cmd.ShortDescription = "generate one or more server operations from the swagger spec"
|
||||
cmd.LongDescription = cmd.ShortDescription
|
||||
case "markdown":
|
||||
cmd.ShortDescription = "generate a markdown representation from the swagger spec"
|
||||
cmd.LongDescription = cmd.ShortDescription
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
# codescan
|
||||
|
||||
Version of the go source parser with support for go modules, from go1.11 onwards.
|
||||
+3
-3
@@ -595,7 +595,7 @@ func (a *typeIndex) detectNodes(file *ast.File) (node, error) {
|
||||
if seenStruct == "" || seenStruct == matches[1] {
|
||||
seenStruct = matches[1]
|
||||
} else {
|
||||
return 0, fmt.Errorf("classifier: already annotated as %s, can't also be %q", seenStruct, matches[1])
|
||||
return 0, fmt.Errorf("classifier: already annotated as %s, can't also be %q - %s", seenStruct, matches[1], cline.Text)
|
||||
}
|
||||
case "meta":
|
||||
n |= metaNode
|
||||
@@ -604,14 +604,14 @@ func (a *typeIndex) detectNodes(file *ast.File) (node, error) {
|
||||
if seenStruct == "" || seenStruct == matches[1] {
|
||||
seenStruct = matches[1]
|
||||
} else {
|
||||
return 0, fmt.Errorf("classifier: already annotated as %s, can't also be %q", seenStruct, matches[1])
|
||||
return 0, fmt.Errorf("classifier: already annotated as %s, can't also be %q - %s", seenStruct, matches[1], cline.Text)
|
||||
}
|
||||
case "response":
|
||||
n |= responseNode
|
||||
if seenStruct == "" || seenStruct == matches[1] {
|
||||
seenStruct = matches[1]
|
||||
} else {
|
||||
return 0, fmt.Errorf("classifier: already annotated as %s, can't also be %q", seenStruct, matches[1])
|
||||
return 0, fmt.Errorf("classifier: already annotated as %s, can't also be %q - %s", seenStruct, matches[1], cline.Text)
|
||||
}
|
||||
case "strfmt", "name", "discriminated", "file", "enum", "default", "alias", "type":
|
||||
// TODO: perhaps collect these and pass along to avoid lookups later on
|
||||
|
||||
+5
@@ -0,0 +1,5 @@
|
||||
/*Package codescan provides a scanner for go files that produces a swagger spec document.
|
||||
|
||||
This package is intendnd for go1.11 onwards, and does support go modules.
|
||||
*/
|
||||
package codescan
|
||||
+2
-1
@@ -204,7 +204,8 @@ func parseContactInfo(line string) (*spec.ContactInfo, error) {
|
||||
ContactInfoProps: spec.ContactInfoProps{
|
||||
URL: url,
|
||||
Name: name,
|
||||
Email: email,},
|
||||
Email: email,
|
||||
},
|
||||
}, nil
|
||||
}
|
||||
|
||||
|
||||
-3
@@ -260,9 +260,6 @@ func (p *parameterBuilder) buildFromField(fld *types.Var, tpe types.Type, typabl
|
||||
typable.Typed("string", sfnm)
|
||||
return nil
|
||||
}
|
||||
//if err := r.makeRef(decl, typable); err != nil {
|
||||
// return err
|
||||
//}
|
||||
sb := &schemaBuilder{ctx: p.ctx, decl: decl}
|
||||
sb.inferNames()
|
||||
if err := sb.buildFromType(decl.Type, typable); err != nil {
|
||||
|
||||
+14
-13
@@ -626,7 +626,8 @@ COMMENTS:
|
||||
}
|
||||
|
||||
var matched bool
|
||||
for _, tagger := range st.taggers {
|
||||
for _, tg := range st.taggers {
|
||||
tagger := tg
|
||||
if tagger.Matches(line) {
|
||||
st.seenTag = true
|
||||
st.currentTagger = &tagger
|
||||
@@ -1311,13 +1312,13 @@ func (ss *setOpResponses) Matches(line string) bool {
|
||||
return ss.rx.MatchString(line)
|
||||
}
|
||||
|
||||
//ResponseTag used when specifying a response to point to a defined swagger:response
|
||||
// ResponseTag used when specifying a response to point to a defined swagger:response
|
||||
const ResponseTag = "response"
|
||||
|
||||
//BodyTag used when specifying a response to point to a model/schema
|
||||
// BodyTag used when specifying a response to point to a model/schema
|
||||
const BodyTag = "body"
|
||||
|
||||
//DescriptionTag used when specifying a response that gives a description of the response
|
||||
// DescriptionTag used when specifying a response that gives a description of the response
|
||||
const DescriptionTag = "description"
|
||||
|
||||
func parseTags(line string) (modelOrResponse string, arrays int, isDefinitionRef bool, description string, err error) {
|
||||
@@ -1331,8 +1332,8 @@ func parseTags(line string) (modelOrResponse string, arrays int, isDefinitionRef
|
||||
tag = tagValList[0]
|
||||
value = tagValList[1]
|
||||
} else {
|
||||
//TODO: Print a warning, and in the long term, do not support not tagged values
|
||||
//Add a default tag if none is supplied
|
||||
// TODO: Print a warning, and in the long term, do not support not tagged values
|
||||
// Add a default tag if none is supplied
|
||||
if i == 0 {
|
||||
tag = ResponseTag
|
||||
} else {
|
||||
@@ -1353,15 +1354,15 @@ func parseTags(line string) (modelOrResponse string, arrays int, isDefinitionRef
|
||||
}
|
||||
}
|
||||
if foundModelOrResponse {
|
||||
//Read the model or response tag
|
||||
// Read the model or response tag
|
||||
parsedModelOrResponse = true
|
||||
//Check for nested arrays
|
||||
// Check for nested arrays
|
||||
arrays = 0
|
||||
for strings.HasPrefix(value, "[]") {
|
||||
arrays++
|
||||
value = value[2:]
|
||||
}
|
||||
//What's left over is the model name
|
||||
// What's left over is the model name
|
||||
modelOrResponse = value
|
||||
} else {
|
||||
foundDescription := false
|
||||
@@ -1369,7 +1370,7 @@ func parseTags(line string) (modelOrResponse string, arrays int, isDefinitionRef
|
||||
foundDescription = true
|
||||
}
|
||||
if foundDescription {
|
||||
//Descriptions are special, they make they read the rest of the line
|
||||
// Descriptions are special, they make they read the rest of the line
|
||||
descriptionWords := []string{value}
|
||||
if i < len(tags)-1 {
|
||||
descriptionWords = append(descriptionWords, tags[i+1:]...)
|
||||
@@ -1382,13 +1383,13 @@ func parseTags(line string) (modelOrResponse string, arrays int, isDefinitionRef
|
||||
} else {
|
||||
err = fmt.Errorf("invalid tag: %s", tag)
|
||||
}
|
||||
//return error
|
||||
// return error
|
||||
return
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//TODO: Maybe do, if !parsedModelOrResponse {return some error}
|
||||
// TODO: Maybe do, if !parsedModelOrResponse {return some error}
|
||||
return
|
||||
}
|
||||
|
||||
@@ -1431,7 +1432,7 @@ func (ss *setOpResponses) Parse(lines []string) error {
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
//A possible exception for having a definition
|
||||
// A possible exception for having a definition
|
||||
if _, ok := ss.responses[refTarget]; !ok {
|
||||
if _, ok := ss.definitions[refTarget]; ok {
|
||||
isDefinitionRef = true
|
||||
|
||||
+6
@@ -402,6 +402,12 @@ func (r *responseBuilder) buildFromStruct(decl *entityDecl, tpe *types.Struct, r
|
||||
return nil, err
|
||||
}
|
||||
return append(taggers, otherTaggers...), nil
|
||||
case *ast.SelectorExpr:
|
||||
otherTaggers, err := parseArrayTypes(iftpe.Sel, items.Items, level+1)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return otherTaggers, nil
|
||||
case *ast.StarExpr:
|
||||
otherTaggers, err := parseArrayTypes(iftpe.X, items, level)
|
||||
if err != nil {
|
||||
|
||||
+5
-6
@@ -238,7 +238,7 @@ func (s *schemaBuilder) buildFromType(tpe types.Type, tgt swaggerTypable) error
|
||||
case *types.Array:
|
||||
return s.buildFromType(titpe.Elem(), tgt.Items())
|
||||
case *types.Map:
|
||||
//debugLog("map: %v -> [%v]%v", fld.Name(), ftpe.Key().String(), ftpe.Elem().String())
|
||||
// debugLog("map: %v -> [%v]%v", fld.Name(), ftpe.Key().String(), ftpe.Elem().String())
|
||||
// check if key is a string type, if not print a message
|
||||
// and skip the map property. Only maps with string keys can go into additional properties
|
||||
sch := tgt.Schema()
|
||||
@@ -387,7 +387,6 @@ func (s *schemaBuilder) buildFromType(tpe types.Type, tgt swaggerTypable) error
|
||||
return nil
|
||||
}
|
||||
default:
|
||||
//log.Printf("WARNING: can't determine refined type %s (%T)", titpe.String(), titpe)
|
||||
panic(fmt.Sprintf("WARNING: can't determine refined type %s (%T)", titpe.String(), titpe))
|
||||
}
|
||||
|
||||
@@ -429,7 +428,7 @@ func (s *schemaBuilder) buildFromInterface(decl *entityDecl, it *types.Interface
|
||||
continue
|
||||
}
|
||||
|
||||
//decl.
|
||||
// decl.
|
||||
debugLog("maybe interface field %s: %s(%T)", o.Name(), o.Type().String(), o.Type())
|
||||
afld = an
|
||||
break
|
||||
@@ -514,7 +513,7 @@ func (s *schemaBuilder) buildFromInterface(decl *entityDecl, it *types.Interface
|
||||
|
||||
var afld *ast.Field
|
||||
ans, _ := astutil.PathEnclosingInterval(decl.File, fld.Pos(), fld.Pos())
|
||||
//debugLog("got %d nodes (exact: %t)", len(ans), isExact)
|
||||
// debugLog("got %d nodes (exact: %t)", len(ans), isExact)
|
||||
for _, an := range ans {
|
||||
at, valid := an.(*ast.Field)
|
||||
if !valid {
|
||||
@@ -600,7 +599,7 @@ func (s *schemaBuilder) buildFromStruct(decl *entityDecl, st *types.Struct, sche
|
||||
debugLog("maybe allof field(%t) %s: %s (%T) [%q](anon: %t, embedded: %t)", fld.IsField(), fld.Name(), fld.Type().String(), fld.Type(), tg, fld.Anonymous(), fld.Embedded())
|
||||
var afld *ast.Field
|
||||
ans, _ := astutil.PathEnclosingInterval(decl.File, fld.Pos(), fld.Pos())
|
||||
//debugLog("got %d nodes (exact: %t)", len(ans), isExact)
|
||||
// debugLog("got %d nodes (exact: %t)", len(ans), isExact)
|
||||
for _, an := range ans {
|
||||
at, valid := an.(*ast.Field)
|
||||
if !valid {
|
||||
@@ -696,7 +695,7 @@ func (s *schemaBuilder) buildFromStruct(decl *entityDecl, st *types.Struct, sche
|
||||
|
||||
var afld *ast.Field
|
||||
ans, _ := astutil.PathEnclosingInterval(decl.File, fld.Pos(), fld.Pos())
|
||||
//debugLog("got %d nodes (exact: %t)", len(ans), isExact)
|
||||
// debugLog("got %d nodes (exact: %t)", len(ans), isExact)
|
||||
for _, an := range ans {
|
||||
at, valid := an.(*ast.Field)
|
||||
if !valid {
|
||||
|
||||
+1
@@ -0,0 +1 @@
|
||||
generated/
|
||||
+224
-82
@@ -2,22 +2,23 @@
|
||||
// sources:
|
||||
// templates/client/client.gotmpl (5.125kB)
|
||||
// templates/client/facade.gotmpl (3.83kB)
|
||||
// templates/client/parameter.gotmpl (12.261kB)
|
||||
// templates/client/response.gotmpl (6.363kB)
|
||||
// templates/client/parameter.gotmpl (15.048kB)
|
||||
// templates/client/response.gotmpl (10.424kB)
|
||||
// templates/contrib/stratoscale/client/client.gotmpl (3.591kB)
|
||||
// templates/contrib/stratoscale/client/facade.gotmpl (2.078kB)
|
||||
// templates/contrib/stratoscale/server/configureapi.gotmpl (6.644kB)
|
||||
// templates/contrib/stratoscale/server/configureapi.gotmpl (7.309kB)
|
||||
// templates/contrib/stratoscale/server/server.gotmpl (236B)
|
||||
// templates/docstring.gotmpl (270B)
|
||||
// templates/docstring.gotmpl (566B)
|
||||
// templates/header.gotmpl (432B)
|
||||
// templates/markdown/docs.gotmpl (14.106kB)
|
||||
// templates/model.gotmpl (700B)
|
||||
// templates/schema.gotmpl (5.504kB)
|
||||
// templates/schema.gotmpl (6.259kB)
|
||||
// templates/schemabody.gotmpl (14.007kB)
|
||||
// templates/schemaembedded.gotmpl (551B)
|
||||
// templates/schemapolymorphic.gotmpl (2.061kB)
|
||||
// templates/schemaembedded.gotmpl (1.006kB)
|
||||
// templates/schemapolymorphic.gotmpl (2.125kB)
|
||||
// templates/schematype.gotmpl (965B)
|
||||
// templates/schemavalidator.gotmpl (31.954kB)
|
||||
// templates/serializers/additionalpropertiesserializer.gotmpl (2.824kB)
|
||||
// templates/schemavalidator.gotmpl (51.727kB)
|
||||
// templates/serializers/additionalpropertiesserializer.gotmpl (2.862kB)
|
||||
// templates/serializers/aliasedserializer.gotmpl (480B)
|
||||
// templates/serializers/allofserializer.gotmpl (7.467kB)
|
||||
// templates/serializers/basetypeserializer.gotmpl (2.894kB)
|
||||
@@ -25,20 +26,25 @@
|
||||
// templates/serializers/schemaserializer.gotmpl (679B)
|
||||
// templates/serializers/subtypeserializer.gotmpl (6.461kB)
|
||||
// templates/serializers/tupleserializer.gotmpl (2.34kB)
|
||||
// templates/server/builder.gotmpl (18.967kB)
|
||||
// templates/server/configureapi.gotmpl (6.786kB)
|
||||
// templates/server/builder.gotmpl (18.855kB)
|
||||
// templates/server/configureapi.gotmpl (7.308kB)
|
||||
// templates/server/doc.gotmpl (1.52kB)
|
||||
// templates/server/main.gotmpl (5.965kB)
|
||||
// templates/server/operation.gotmpl (3.868kB)
|
||||
// templates/server/parameter.gotmpl (28.728kB)
|
||||
// templates/server/responses.gotmpl (12.037kB)
|
||||
// templates/server/server.gotmpl (23.049kB)
|
||||
// templates/server/main.gotmpl (6.138kB)
|
||||
// templates/server/operation.gotmpl (3.752kB)
|
||||
// templates/server/parameter.gotmpl (29.44kB)
|
||||
// templates/server/responses.gotmpl (12.038kB)
|
||||
// templates/server/server.gotmpl (23.073kB)
|
||||
// templates/server/urlbuilder.gotmpl (7.641kB)
|
||||
// templates/structfield.gotmpl (1.91kB)
|
||||
// templates/simpleschema/defaultsinit.gotmpl (1.412kB)
|
||||
// templates/simpleschema/defaultsvar.gotmpl (1.353kB)
|
||||
// templates/structfield.gotmpl (1.291kB)
|
||||
// templates/swagger_json_embed.gotmpl (759B)
|
||||
// templates/validation/customformat.gotmpl (473B)
|
||||
// templates/validation/primitive.gotmpl (2.225kB)
|
||||
// templates/validation/structfield.gotmpl (909B)
|
||||
// templates/validation/customformat.gotmpl (194B)
|
||||
// templates/validation/maximum.gotmpl (1.751kB)
|
||||
// templates/validation/minimum.gotmpl (1.746kB)
|
||||
// templates/validation/multipleOf.gotmpl (1.816kB)
|
||||
// templates/validation/primitive.gotmpl (1.16kB)
|
||||
// templates/validation/structfield.gotmpl (1.063kB)
|
||||
|
||||
package generator
|
||||
|
||||
@@ -147,7 +153,7 @@ func templatesClientFacadeGotmpl() (*asset, error) {
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesClientParameterGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x5a\x5f\x73\xdb\xb8\x11\x7f\xe7\xa7\xd8\xaa\xe9\x55\xf4\x38\xd4\x3d\xfb\x46\x9d\xc9\xd9\xb9\xc6\x9d\x69\x2e\x4d\x3c\xd7\x87\x4c\xa6\x03\x93\x2b\x09\x77\x24\x40\x03\xa0\x14\x95\xc3\xef\xde\xc1\x1f\x92\x20\x45\x4a\x54\x12\xc7\x77\xd3\x3c\x59\x04\x81\xc5\xee\x6f\x7f\xfb\x07\xa0\x17\x0b\xb8\xe6\x09\xc2\x1a\x19\x0a\xa2\x30\x81\xfb\x3d\xac\xf9\x73\xb9\x23\xeb\x35\x8a\x1f\xe0\xe6\x67\x78\xfd\xf3\x1d\xbc\xbc\xb9\xbd\x8b\x82\x20\x28\x4b\xa0\x2b\x88\xae\x79\xbe\x17\x74\xbd\x51\xf0\xbc\xaa\x16\x0b\x28\x4b\x88\x79\x96\x21\x53\xbd\x77\x65\x09\xc8\x12\xa8\xaa\x20\x08\x72\x12\xff\x46\xd6\xa8\x27\x47\x6f\xdc\x6f\xfd\x62\xb1\x80\xbb\x0d\x95\xb0\xa2\x29\xc2\x8e\xc8\xae\x32\x6a\x83\xe0\xb4\x01\xc5\x79\x1a\xe9\xf9\x2f\x13\xaa\x28\x5b\x83\x6a\xd6\x65\x66\xc7\x5c\xf0\x2d\xc2\xaa\x50\x46\xd4\x06\x19\xec\x79\x01\x02\x9f\x8b\x82\x75\x24\xd5\x5b\x18\xb5\x09\x4b\x82\x80\x66\x39\x17\x0a\xe6\x01\xc0\x2c\xe6\x4c\xe1\x47\x35\xd3\xbf\x19\xaa\xc5\x46\xa9\xdc\x3c\x28\x9a\xe1\x2c\xd0\xbf\xd6\x54\x6d\x8a\xfb\x28\xe6\xd9\x62\xcd\x9f\xf3\x1c\x19\xc9\xe9\x02\x85\xe0\x42\xce\xc6\x27\x88\x82\x59\x19\x00\xb1\x38\x31\x69\x11\xa7\x14\x99\x3a\x22\x4d\x2a\xb1\xca\x8e\x4e\xd8\x91\xf5\x91\xd7\x5b\x92\xd2\x84\x28\x6b\x92\x76\xad\xc1\x40\x42\x74\x83\x2b\x52\xa4\xea\xd6\x3d\x57\x55\xef\xbd\xf7\x22\x34\x0e\x7c\x8d\xbb\xb2\x84\x9c\xc8\x98\xa4\xf4\xbf\x08\xd1\x6b\x92\x69\xef\xbe\x21\x82\x64\x12\x62\x81\x44\xa1\x04\x02\x0c\x77\x70\x6c\x26\xbf\xff\x15\x63\xa5\x45\xee\xa8\xda\x18\x9f\x25\x56\x19\xd8\x92\xb4\x40\x09\x94\x51\x45\xcd\xda\x24\x0a\x56\x05\x8b\x4f\x6c\x3e\x0f\xe1\xe2\xd8\x8e\xa5\xb3\x6d\xa5\x59\x69\x46\xaa\x6a\x4b\x84\x61\x42\x59\x82\x20\x6c\x8d\xde\x2b\x37\xf5\x15\x91\x0e\xa4\x66\x8c\x71\x05\xd1\xad\xfc\x89\xa6\x68\x66\xdb\x17\x5b\x22\x98\xde\x2f\xba\xbd\xa9\xaa\x7a\xc9\xb2\xde\xf1\x56\xbe\x11\x34\xa3\x8a\x6e\x51\xcf\x8e\xfe\xce\xef\xf6\x39\x56\xd5\xdc\x06\x8e\x91\x90\x0b\xca\xd4\x0a\x66\x7f\xf9\xf3\x76\xd6\xb8\xa6\xd5\xc4\x13\x01\x55\x15\xb6\x11\x67\xd4\xb7\xbf\xbd\x1f\x46\x6a\x00\xd0\x99\x28\x50\x15\x82\xc1\x77\x87\x38\xd5\x30\x95\x67\xa1\x71\x20\xe4\xca\x19\x4c\x58\x02\x73\x07\xd4\x0b\x21\xc8\x3e\x6c\x1e\xff\x49\xf2\xfa\x41\x8b\xa3\x32\xd6\x66\x31\xa2\xb8\x08\x61\xce\x85\x9e\xf3\xba\x48\x53\x72\x9f\x22\x40\x08\x55\xf5\x9d\x6f\x9f\x87\x33\x34\x40\x5f\x0e\x82\x10\x00\x98\xe1\x98\x64\x68\x95\xbc\xa3\x19\xf2\x42\x39\x62\x5c\x41\x2c\x6a\x9c\xdd\x1b\x2d\xa8\x0a\xaa\x09\x5c\xff\x37\x55\x1b\xb7\xe8\xb1\x68\x7f\x69\x60\xd4\x73\xc8\x3d\x4d\xa9\xda\x83\xe2\x20\x51\x01\x01\xe5\x76\xe6\x0c\x08\x08\x7c\x28\x50\xaa\x29\x41\xe2\x69\x3d\xaf\x65\xe8\xbf\xd1\x4d\x21\x88\xa2\x9c\x7d\x0b\xa2\xa7\x0c\x22\x6d\xf6\x1f\x2c\x84\xd4\xa7\x04\xce\xb5\x2d\xbc\x4f\x10\x38\xae\xe4\xc3\x8a\x8b\xf3\x23\xc7\xa9\x3d\x8f\xd5\xc7\x5a\x50\xe4\xc6\x9e\x36\x6e\x5a\xf7\x58\x1a\xfe\x1f\x86\xce\xd7\xaa\x3f\x5d\xa8\x27\xc5\x8f\xa3\xc8\x15\xc4\xea\xe3\x79\x71\xf2\xea\xee\xee\xcd\xb5\xe9\x0e\x9f\x22\x54\x0a\xa9\x78\x06\x9e\x0e\x9f\x14\x34\xed\xfa\xb9\x6d\x74\xe1\x42\xf7\xd9\x91\x1d\xfb\x16\x37\xdf\xe2\x66\x00\x87\x96\x34\x57\x60\x59\xd3\x06\xce\x51\xc2\xe8\xb4\x4c\x28\x93\x40\xd2\xd4\xd0\x3a\xd7\xe3\xa8\x50\x48\xcb\x6c\xcd\x76\x6e\xde\xbc\x78\x73\xab\x77\xcb\x39\x65\x2a\xd0\xd4\xd6\x83\x65\x09\x9b\x22\x23\xcc\x17\x0d\x3c\x47\xdb\x1d\x81\xda\xe7\x34\x26\x69\x6a\xce\xab\x12\x81\x08\x84\x9d\xa0\x4a\x21\xd3\x62\x09\x18\x6a\xbf\x75\x11\x72\xb1\x08\xd4\x3e\xc7\xa3\xd1\x2a\x95\x28\x62\x05\x65\x30\xec\xc0\x11\x6b\xcb\x52\xbb\xf5\x06\xb5\x13\x72\xa3\x59\x4d\xa8\xfb\x94\xc7\xbf\x35\x87\xf4\xde\x0c\x1f\xeb\x8b\x85\x7d\xea\xb4\x1f\xda\xda\xcf\x64\x82\x9b\x74\xcb\x14\x8a\x15\x89\xb1\x1d\x7a\xa7\x04\x92\x6c\x84\x2c\x17\x3e\x09\x46\x03\xd6\x05\xa0\xa3\x4a\x2a\xf5\x2f\x77\x8c\x36\xd0\x24\x6f\x91\x24\xd7\x29\x97\x28\xda\x50\xf2\x2e\x27\x8e\x36\x33\xdd\x4e\x38\x68\x12\x77\xbf\xd6\x07\xe0\x27\x45\x3f\x9b\xb9\xc4\xae\xd3\x5e\x17\xd9\xde\x46\x24\x49\xa4\xa1\x5b\xd3\x83\xf3\x71\xf6\x19\x06\x4b\x9b\x6e\x75\xde\x89\xde\x62\x8c\x74\x8b\xa2\x9e\x70\x2c\x20\xc2\x93\xca\x7c\xce\x39\xa0\xaf\x4a\xf4\x0e\xd5\x94\xbd\xc2\x36\xa7\x0d\x48\x71\x28\x9e\x90\xf5\x55\x41\x9c\x68\x57\x1f\xc3\x31\x98\x8e\x91\x70\x59\xdb\xe3\x91\xa9\x26\x62\x63\x72\xdd\xc6\x3e\x32\x6f\x3e\xbb\xe1\x1d\x22\x88\x27\x74\x2a\x0f\x9e\xc2\xfe\xae\xa6\x87\xe6\x8f\x59\x58\xeb\xba\xd4\xed\x9e\xe7\x43\x2f\x65\x34\x66\x78\x63\x8f\xec\xc9\x2f\xd1\x85\x0d\x39\xf3\x40\xee\x54\x97\x3e\x1d\x1c\x43\x5a\xf7\xd0\x18\x33\xd8\x53\x70\xe9\xfa\x12\x6d\xd1\x40\xdd\x1e\x2e\x03\xb6\xc0\x36\xf6\xfa\x67\x71\xb3\x85\x29\x42\x87\x96\x3f\x1b\x35\xfd\xd9\x09\xdb\x9f\x9d\xae\x06\x46\xa7\xf9\xa0\x2a\x5f\xa6\x13\xf8\xda\x65\xdf\xc9\xeb\x73\xfa\xd9\x30\xa9\x0f\x10\x3c\xac\x61\xe3\x08\x7d\x5a\x1d\x3b\x64\x41\xaf\x39\x7e\x7c\x1a\x9c\x61\xe3\x1f\x9d\x05\xa3\x7e\x1e\x72\xca\x72\x30\x26\x5d\x8c\xbb\x26\x52\x47\xb6\xa0\x0a\xef\xb8\xeb\xf3\xcd\x09\x00\xa5\x3b\x12\x58\xdf\xd8\xd3\x40\xfd\x19\xaa\x73\x64\xfe\x94\x0c\xde\xd9\x6f\x2e\xa0\x36\xdb\x26\x23\x37\x7e\x09\x02\xd7\x60\x3f\x16\x45\x6f\x71\x4d\xa5\x12\Line truncated
|
||||
var _templatesClientParameterGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x5b\x5b\x6f\xe3\x36\xf6\x7f\xd7\xa7\x38\x7f\x63\xda\xbf\x15\x64\xe4\x3e\xa7\xc8\x02\xd3\x24\xdd\x66\x81\x9d\xce\x4e\x82\xd9\x87\xc1\x60\xc1\x48\xc7\x36\x5b\x89\x54\x48\x2a\x89\x6b\xf8\xbb\x2f\x78\xd1\x8d\xa6\x64\x39\x49\x3b\xdd\xc5\x3e\xc5\x92\xc8\x43\x9e\xdf\xb9\x1f\x32\x8b\x05\x5c\xf0\x0c\x61\x85\x0c\x05\x51\x98\xc1\xdd\x06\x56\xfc\xad\x7c\x24\xab\x15\x8a\xef\xe1\xf2\x67\x78\xff\xf3\x2d\x5c\x5d\x5e\xdf\x26\x51\x14\x6d\xb7\x40\x97\x90\x5c\xf0\x72\x23\xe8\x6a\xad\xe0\xed\x6e\xb7\x58\xc0\x76\x0b\x29\x2f\x0a\x64\xca\xfb\xb6\xdd\x02\xb2\x0c\x76\xbb\x28\x8a\x4a\x92\xfe\x4a\x56\xa8\x07\x27\x1f\xdc\x6f\xfd\x61\xb1\x80\xdb\x35\x95\xb0\xa4\x39\xc2\x23\x91\xfd\xcd\xa8\x35\x82\xdb\x0d\x28\xce\xf3\x44\x8f\xbf\xca\xa8\xa2\x6c\x05\xaa\x99\x57\x98\x15\x4b\xc1\x1f\x10\x96\x95\x32\xa4\xd6\xc8\x60\xc3\x2b\x10\xf8\x56\x54\xac\x47\xa9\x5e\xc2\x6c\x9b\xb0\x2c\x8a\x68\x51\x72\xa1\x60\x1e\x01\xcc\x52\xce\x14\x3e\xa9\x99\xfe\xbd\x2c\xec\x5f\x86\x6a\xb1\x56\xaa\x34\x0f\x8a\x16\x38\x8b\xf4\xaf\x15\x55\xeb\xea\x2e\x49\x79\xb1\x58\xf1\xb7\xbc\x44\x46\x4a\xba\x40\x21\xb8\x90\xb3\xe1\x01\xa2\x62\x96\x06\x40\x2a\x0e\x0c\x5a\xa4\x39\x45\xa6\x46\xa8\x49\x25\xea\x6d\x0e\x0c\x78\x24\xab\x91\xcf\x0f\x24\xa7\x19\x51\x96\x25\x2d\x62\x83\x85\x84\xe4\x12\x97\xa4\xca\xd5\xb5\x7b\xde\xed\xbc\xef\x9d\x0f\xb1\x11\xe4\x7b\x7c\xdc\x6e\xa1\x24\x32\x25\x39\xfd\x0d\x21\x79\x4f\x0a\x2d\xe5\x0f\x44\x90\x42\x42\x2a\x90\x28\x94\x40\x80\xe1\x23\x8c\x8d\xe4\x77\xbf\x60\xaa\x4e\x35\xcd\x47\xaa\xd6\x46\x78\x99\xdd\x0d\x68\x50\x78\xa5\x60\xc9\x85\xd5\x00\x0b\x90\xd6\x0c\x3d\xde\x6d\x1a\x1e\x48\x5e\xe9\xb5\x04\x02\xe3\x0a\xd6\x9b\xcc\x28\xd5\x29\x48\xca\xd2\x86\x5a\x3d\x40\x14\x24\xcf\x37\x40\xca\x32\xa7\xad\xe6\xbd\xfb\x70\x0d\x12\xc5\x03\x0a\x90\x34\xc3\x7a\x89\x5b\x0e\xc8\x96\x5c\xb4\x64\xea\xd5\x28\x83\x52\x73\x80\x0a\xc5\x29\x54\x12\xe1\x06\xd5\x65\xbd\x14\x17\xf0\x4f\xaa\xd6\xf5\x73\x12\x2d\x2b\x96\x1e\x00\x6d\x1e\xc3\xc9\x18\x52\xdb\x08\x40\xa0\xaa\x04\x83\x6f\xf7\xc7\xd5\xc3\xf4\x28\x23\xbb\x94\x14\x68\x3f\xdf\x5a\x18\x1d\xb5\x33\x48\x45\x2d\x6f\xf7\xe5\x34\x02\xd8\x45\xbb\x09\x82\xd5\x4c\xb9\x49\x47\xcb\xb8\x27\x62\x72\x47\x73\xaa\x36\xa0\x38\x48\x54\x40\x1a\x59\x73\x06\x04\x04\xde\x57\x28\xd5\x24\xd8\x3a\x5b\x9a\xd7\x44\xf4\xdf\xe4\xb2\x12\x44\x51\xce\xfe\x28\x58\xd5\x73\xc0\xbc\xb0\x1e\xe8\x95\xc1\x74\x7e\xcd\x18\xce\xf1\x68\xba\x3d\xcd\x53\xf5\x54\x53\x4a\xdc\xbb\x57\xc4\xd2\x51\x3c\x83\x54\x3d\x1d\x87\xd9\x4f\xb7\xb7\x1f\x2e\x8c\x27\x78\x6d\xd8\x2a\xa9\x78\x01\x1d\xfa\xcf\x03\xb0\x25\x30\xb7\x1e\x0b\x4e\x74\x44\x49\xec\xbb\x57\xc4\xb0\x5d\xe8\xcc\xf9\xc6\x16\xc9\x93\x51\x38\xb4\x5c\x09\x65\x12\x48\x9e\x1b\x30\x1a\x67\x26\x2d\x1e\x2c\xd3\x7f\x6b\xd7\x88\x2c\x2b\x39\x65\x4a\xaf\x6a\xbd\xb1\x09\xef\xeb\xaa\x20\xac\x4b\x1d\x78\x89\xd6\xea\x12\x1d\x62\xe0\x76\x53\xd2\xd4\xf8\x5b\xb5\x46\x89\xc6\x05\x3f\x0a\xaa\x14\x32\x4d\x9e\x80\xc1\xe5\x63\x8d\xef\xc9\x22\x52\x9b\x12\x47\x77\x2e\x95\xa8\x52\x65\x60\xda\x6e\xdf\x82\x20\x6c\x85\x3a\xcf\x30\x1f\x4d\xe0\xb2\x1f\x74\xfa\x72\x89\x32\x15\xb4\xd4\xfb\x31\x19\x08\xc0\x10\x2c\x76\xbb\xc6\xc2\xef\x72\x9e\xfe\xda\x64\x39\x1e\x09\x80\x0e\x7d\x2e\x20\xb9\xb1\x89\xc6\x8f\x3a\xae\xa8\x26\x90\xb6\x43\x0d\xc9\x52\x50\xa6\x60\x36\xeb\xbf\xb6\x7b\xec\x13\xa8\x07\xd8\xc7\x33\x93\x43\x85\x47\x38\x12\x2e\xeb\xf2\xa9\xfa\xfb\x70\xcf\x86\xe0\x2f\x92\xb3\x81\x9d\x7a\xf4\x7a\x2f\x4e\x16\x0d\xb6\x98\x4b\xac\x01\x5d\x0c\x01\x7a\x14\x54\x8b\xc5\x14\x60\x16\x8b\xd7\x05\xa6\x4d\x22\x5e\x02\x4c\xe0\xb1\x0b\xc8\xf5\xa5\x36\x0c\x9b\x50\x13\x96\xc1\x5c\x27\x29\xc9\xb5\x7c\x27\x04\xd9\xc4\xcd\xe3\xdf\x49\x59\x3f\xfc\x44\xe4\x25\xd5\x6a\x57\x50\x46\x14\x17\xed\xa0\x6b\xa6\x50\x2c\x49\x8a\xed\xab\x1b\x25\x90\x14\x31\xcc\x35\xc4\xd7\xf2\x7d\x95\xe7\xe4\x2e\x47\x80\x18\x76\xbb\x93\x26\x2f\xb7\xeb\xbb\x39\x3f\xd2\x1c\x8d\xc5\xd8\x0f\xc9\x5f\xf9\xad\x36\x3b\x9b\xc6\x5b\xd9\xba\x9c\xd4\x88\x33\xfb\x88\x24\xbb\xc8\xb9\x44\xd1\xe6\xf9\x3d\xae\xa3\xd1\xd8\xd8\x8f\xc7\x51\xe3\xfb\xfd\xe8\x12\x75\x3d\x5a\xcf\x67\xba\xd8\xd0\xcd\xa9\xea\x3c\x4f\x06\x32\xb3\x41\xf7\x54\x5a\x37\x61\xb0\xd3\x83\xee\x2b\x14\x1b\xb8\xe3\xd9\x26\xae\x53\xbe\x77\x79\x5e\x53\x32\x91\x82\xf1\x66\x01\xed\xbd\x04\xea\x58\x61\x5d\x23\x15\xf0\x1b\x0a\x6e\x87\xbb\xe8\x30\xd7\x78\x7e\xc4\x14\xe9\x03\x8a\x7a\xd9\x31\x87\x1f\xf7\xb8\x9a\x92\x04\x1a\xac\xfd\x35\x92\x4e\xfa\x39\x8f\xcd\x28\x17\x45\x02\x83\x1d\x9c\xdd\x8c\xf5\xbf\x06\xcd\x1e\x0e\xb0\x8d\x6a\xc3\xb7\xdf\xb5\x6d\xdd\xf0\x02\x1b\xbe\x8d\x26\x3f\x10\x61\x0a\xc2\x83\x01\x45\x5b\xa6\xef\x1e\xea\x6f\x7d\xb3\x32\x1f\x75\x3a\xf3\xf3\xed\xd5\x59\x97\x6d\x59\x95\xba\x96\xc2\xcc\x04\x52\x53\xd3\x36\xb1\xd7\xc8\xca\xf8\x8b\xae\x9f\xd1\x06\x69\x17\xb0\xb6\x3e\x9d\xba\xb4\xe3\xa7\xd1\x77\xbe\xe1\x07\x9e\x6d\x7a\x4c\x38\x85\x53\x58\x94\xb9\xae\xa4\x67\x92\x16\x65\x8e\x32\x5d\x63\x41\x6a\x1c\x1f\x88\x98\x41\x32\xcd\x41\xf6\x1e\xe2\x09\xb0\x6b\xaf\xd9\x85\x7e\xee\xbb\xb1\x80\x37\xf4\xb9\x89\xbb\x7b\x3b\xc0\x0c\x65\x54\x75\xb8\x19\xda\xbc\x51\x9c\x1c\Line truncated
|
||||
|
||||
func templatesClientParameterGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -162,12 +168,12 @@ func templatesClientParameterGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/client/parameter.gotmpl", size: 12261, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x90, 0xd8, 0x41, 0xd2, 0x6, 0xe3, 0x24, 0x53, 0x68, 0xa4, 0xc6, 0xcc, 0x6d, 0xa3, 0x61, 0xd3, 0x49, 0x4e, 0xe2, 0x3d, 0xf3, 0x9b, 0x1e, 0x12, 0x19, 0xf, 0xd3, 0xd4, 0x4c, 0x37, 0x6f, 0x72}}
|
||||
info := bindataFileInfo{name: "templates/client/parameter.gotmpl", size: 15048, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x4e, 0x97, 0x6b, 0x6, 0x1d, 0x36, 0x14, 0xf0, 0x17, 0xd2, 0x61, 0xf4, 0x38, 0x7a, 0xcb, 0x25, 0x36, 0x59, 0xf, 0x34, 0xa6, 0x71, 0x81, 0x69, 0xb2, 0x5e, 0xc0, 0x52, 0xb8, 0x2f, 0xb4, 0x7c}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesClientResponseGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xdc\x58\xcd\x72\xe4\xb6\x11\x3e\x07\x4f\xd1\x61\xbc\x5b\x43\x65\xc4\xb1\x73\x94\x4b\x07\x5b\x2b\xaf\x75\xf0\xae\x4a\xda\x54\x0e\x2e\x57\x0a\x22\x7b\x66\x90\x25\x01\x1a\x00\x35\x9e\xb0\xf8\xee\x29\xfc\x90\x04\x87\xe0\x48\x9b\x9c\xb2\xba\x68\x08\x34\xba\xd1\xdd\x5f\x7f\x68\xa0\x6d\xa1\xc0\x2d\xe3\x08\x49\x5e\x32\xe4\x5a\xa2\xaa\x05\x57\x98\x40\xd7\x6d\x36\xf0\x01\x0f\x6d\x0b\x35\x55\x39\x2d\xd9\xbf\x11\xb2\x0f\xb4\x42\xe8\x3a\xc8\x25\x52\x8d\x0a\x28\xc4\xe7\x0f\x4c\xef\x8d\x6a\xda\x94\x1a\xf6\x48\x0b\x94\x0a\x9e\x69\xd9\xa0\x22\xdb\x86\xe7\x8b\x9a\x57\x6d\x0b\x6c\x0b\xf8\x3b\x64\x37\xa2\x40\xb8\xfc\x0e\xba\x2e\x37\xbf\x18\xd7\x6d\x0b\xc8\x0b\xe8\x3a\x27\x94\x3d\xe6\x7b\xac\xe8\xf0\x4d\x79\x01\xab\x60\x65\xda\x4b\x64\x77\xea\x51\x4b\xa4\x15\x74\xdd\x1a\xda\x16\x79\x71\xa2\x23\x94\x38\x48\xa6\x51\x02\x13\xd9\x3f\xec\xaf\xd0\xaa\xfb\x91\xc2\x45\xdc\xed\x96\x00\x48\xd4\x8d\xe4\xf0\x36\x2a\x61\x04\x00\x62\x3e\xfe\x53\x69\xaa\x1b\x65\x06\xae\xc0\x38\xbc\xee\x45\x07\xe3\x92\xf2\x1d\x42\xf6\xb3\x0f\xe7\xe0\xc2\xcf\x54\xbd\xf3\xa1\xb6\x63\x73\xb3\x57\x36\x4d\x92\x71\xbd\x85\xe4\xcd\x5f\x9e\x13\xc8\xc6\x15\x73\x43\xe7\x82\x1c\x09\xd8\x3d\x3d\x96\x82\x16\x57\xe0\x22\xb7\xa4\xaf\x23\x1d\x21\x9b\x48\xe4\xba\x0e\xf6\x94\x17\x25\x2a\xd0\x7b\xa6\x20\xa7\x0a\x63\x08\xf2\x00\xca\x08\xf1\x5b\x79\x87\x2a\x97\xac\xd6\x4c\x70\x67\xe8\xa9\x14\xf9\xe7\x5c\x54\x15\x72\x3d\x9f\xc6\x52\xe1\x42\x80\xcc\x76\xf7\x4d\x45\xf9\x24\x59\x0e\x28\xe4\x62\x43\xf4\xb1\xc6\x05\xa8\x2b\x2d\x9b\x5c\xdb\xd4\xc7\xf2\x4a\x00\x82\xd4\x1a\x14\x13\xf2\xba\xb4\x4e\xb7\x6f\x03\x77\xce\x3f\x02\x70\xb1\x19\xf4\x3a\x1b\x71\x47\xb3\xf7\xe2\x93\xf1\xa7\x97\x0a\x57\x4c\x32\x4e\x00\x7c\x6e\x21\xa8\x30\x2e\x74\x80\x82\x1f\xa9\x42\xa3\x2d\x3d\x9d\xb8\xe3\x1a\xe5\x96\xe6\x18\x96\xe1\x8d\xa8\xea\x12\xff\xf8\xf8\xf4\x2f\xcc\xf5\xe9\x0a\x07\xa8\x14\xba\xee\xe2\x04\x84\x8b\x82\xc6\x1b\x3f\x3c\x38\x65\xd6\x96\xca\xfc\x0a\x4a\xd8\x65\x32\x74\xb7\x8b\x66\x8b\x6c\x36\x60\x3f\x77\xa8\x0d\x1c\x11\x5c\xf2\x6c\x49\xc2\x56\x48\x3b\x16\x43\x0b\xf4\xdc\xe9\x08\xce\x10\x59\xf6\x80\x39\xb2\x67\x94\xbd\x48\x9c\x36\x52\x6b\x71\x95\x1a\x70\x84\x14\x12\xd1\x90\x05\x58\x22\x1d\x19\xbd\x21\xff\x85\xd5\x5b\x29\x85\x5c\xa5\x06\xc1\x8c\xef\xa0\x25\x7f\xf2\x86\xb7\x95\xce\x1e\x1d\x5d\xac\x92\x5f\xdb\x16\x9a\xba\x46\x09\xd9\x2f\xa8\xf7\xa2\xe8\x51\x74\x4f\xf5\x1e\xba\xee\xb7\x5f\xdf\x14\xbf\xf5\xd0\x19\x2a\x67\x02\x38\x9f\x8e\x86\x7f\xe6\xe2\xc0\x01\x8d\x5d\x58\xe4\x19\x78\xf3\xd7\xe7\x61\x32\x59\x47\xab\xea\x85\xd0\x8c\x36\x8d\xa0\x5d\x76\x86\xd8\xd6\x20\x32\x8f\xf3\x91\xe2\x0d\x59\xcd\xea\xe1\xcb\x63\xfc\x1e\xb5\x57\xbd\x4a\xbf\x8e\x22\x0a\x70\x32\x84\x6d\x0a\xc5\x2f\x8f\x92\x44\x5a\x3c\xf8\xf2\x59\xf5\x75\x04\xb2\xe1\x9a\x55\x98\xdd\xd8\xd6\xa4\x9f\x5f\x43\x2e\xb8\x6a\x2a\x94\xa3\x80\x1f\x58\x9b\x02\xad\xa8\x56\x06\xd2\x06\xc4\x0f\xb8\x63\x4a\xcb\x63\xda\x63\xce\x31\xc0\x8c\x71\x09\xc0\x66\x33\x14\x70\x7f\xdc\xb4\xad\x3f\x9e\xec\x2a\x83\x84\x1b\xc1\x9f\x51\x9a\xee\xc0\x46\x28\xa7\x15\x4e\x3c\x59\x1b\x3b\x70\x75\x0d\x0e\x76\xa3\xf0\xe0\x54\xf6\x1e\xb5\xb3\xbb\x4a\x82\x2a\x49\xd2\x94\x80\x85\xb9\x94\xf0\xe7\x6b\xe0\xac\x04\xd7\x2b\xf8\x50\xdb\xfd\xab\xec\x8e\x3f\xd3\x92\x15\x26\x49\xab\xa0\x06\xd7\x90\xb8\x3d\x27\x6b\x48\x26\x0c\x9f\xac\xe1\x55\xa6\x3d\x37\xce\x8a\x2a\x7e\x88\x58\x07\x67\xde\x7b\x7a\x35\xb0\x31\xc1\xba\x53\x37\x8d\xd2\xa2\xfa\xc9\xe6\xc4\xc5\xc1\x89\x2c\xc7\xcd\xe7\x2f\xbb\xa7\x52\x59\x0f\x87\xa6\xe5\xf7\x04\xb2\xc7\x03\xdd\xed\x50\x3a\x85\x76\xd9\xd7\x16\xd6\x8b\x55\x2c\x3c\xd9\xea\x62\x62\xdd\xaa\xf6\xa1\x8e\x73\xe1\x92\xfe\x17\x37\x6d\x15\xcf\x0f\xcb\x68\x6f\x70\xda\x10\xf6\x2c\x36\x2f\xa8\xda\x77\x11\x54\x99\x33\xce\x31\x1a\x98\x9e\x8a\x40\x3f\x17\x96\x8e\x16\xf7\x34\xff\x4c\x77\x68\xb7\x95\xfd\x22\x0a\x2c\x95\x1f\x32\xde\xfd\x9d\x57\x54\xaa\x3d\x2d\xcd\xfd\x45\x8a\xba\x9f\x8a\xb1\xd8\x64\x87\x3f\x48\x49\x8f\x5d\xf7\x58\xb2\x1c\x07\xe7\xc6\xda\xfc\x51\x14\xc7\x55\x3a\x12\xcc\xcb\xe0\x39\x93\xe2\xbe\x73\xba\xee\x3d\x3c\x29\x8f\x05\x3a\xef\x5e\xd6\xc7\xf1\xb0\x8a\x71\x76\x7a\xd2\x58\xb2\x2d\xc4\x8f\x99\xc5\x04\x8d\xfe\x5e\x5d\x0f\x51\xe8\xe9\x75\x1e\xa7\xd1\xc6\x4a\xc8\x45\x8f\x62\x47\xce\x5b\xb7\xcf\x38\x78\xbd\xa7\xe9\xf7\x61\xe4\xdf\xbe\xed\xbf\x98\xc8\x6e\x3f\xfe\x74\x26\x15\x27\xf7\x8e\xb1\xa1\xe2\xac\x0c\x4f\xaa\xb1\xd5\xe3\x28\xa9\xc6\x02\x9e\x8e\xb0\x13\x97\xca\xd1\xcc\xf7\xf0\xee\x23\x7c\xf8\xf8\x09\x6e\xdf\xdd\x7d\xca\xc8\xd0\x0e\xdc\x88\xfa\x28\xd9\x6e\xaf\xe1\xd2\xea\x30\x15\xdb\xb7\xe4\x93\xb9\xb0\x3b\xab\x3d\x44\x1d\xbb\xf4\x48\xb6\xed\xe6\x27\x73\xe7\xd9\xb2\x12\xe1\x40\xd5\x74\x33\xb6\xff\x74\xbb\x01\x2d\x44\x99\x19\xf9\xdb\x82\x69\xd3\xaf\xe9\x61\x5d\x65\x2d\xd6\x52\x3c\x23\x6c\x1b\x6d\x55\xed\x91\xc3\x51\x34\x20\xf1\x52\x36\x7c\xa2\xa9\x37\x61\xb7\x4d\x79\x41\x08\x61\x55\x2d\xa4\x86\x15\x01\x48\x98\x48\xcc\x3f\x8e\x7a\xb3\xd7\xba\x4e\xcc\x7d\x25\xd9\x31\xbd\x6f\x9e\xb2\x5c\x54\x9b\x9d\xb8\x14\x35\x72\x5a\xb3\x8d\xa3\xcf\x64\x59\xc0\x9f\xd0\x67\x24\xdc\x49\x7d\x4e\xe0\x40\xLine truncated
|
||||
var _templatesClientResponseGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xe4\x3a\x4b\x73\xdc\xb6\xfd\xe7\x3f\x3e\xc5\x2f\x1c\x5b\xb3\xd4\x7f\xc5\x4d\x7a\x54\x46\x87\x58\x52\x9c\x3d\xc4\xf6\x48\xae\x7b\xc8\x64\x32\x10\x09\xed\x22\x26\x01\x06\x00\x57\xde\x72\xf8\xdd\x3b\x78\x90\x04\xf8\x58\x51\x4e\x3b\x9d\xb6\xa7\x25\x09\xe0\xf7\x7e\x63\xeb\xfa\x02\x32\xf2\x48\x19\x81\x28\xcd\x29\x61\x4a\x10\x59\x72\x26\x49\x04\x4d\x83\x36\x1b\x78\x47\x9e\xea\x1a\x4a\x2c\x53\x9c\xd3\xbf\x13\x48\xde\xe1\x82\x40\xd3\x40\x2a\x08\x56\x44\x02\x86\xe9\xf5\x27\xaa\xf6\x1a\x36\xae\x72\x05\x7b\x82\x33\x22\x24\x1c\x70\x5e\x11\x89\x1e\x2b\x96\xce\x42\x5e\xd5\x35\xd0\x47\x20\x7f\x40\x72\xcd\x33\x02\x17\xdf\x41\xd3\xa4\xfa\x89\x32\x55\xd7\x40\x58\x06\x4d\x63\x37\x25\xf7\xe9\x9e\x14\xb8\x7b\xc7\x2c\x83\x95\x77\x32\x6e\x77\x24\x5b\x79\xaf\x04\xc1\x05\x34\xcd\x1a\xea\x9a\xb0\x6c\x00\xc3\xdf\xf1\x24\xa8\x22\x02\x28\x4f\xfe\x66\x9e\x7c\xac\xf6\x21\x86\xf3\x69\xb6\x6b\x04\xa0\xa5\xaa\x01\xff\x64\xb9\x4e\x7e\xc2\xf2\x9e\x17\xe4\xc6\x0a\x43\x6a\xc9\x02\x1c\xb0\x80\x15\x02\xd8\x6c\x80\x32\xaa\xa8\x85\xd3\x0a\x2a\x90\x9e\x93\x1a\x80\x05\x2d\x30\xdb\x91\x0e\xba\x85\xd6\xae\x19\xb4\x58\x3a\x54\xfd\x9a\x5e\x05\x45\x8a\x32\xc7\x8a\x40\x24\x69\x51\xe6\x44\x1a\xc6\x5b\xb2\x0e\x58\x44\x90\x78\x47\x34\x3c\xcb\x2d\x1a\xbd\xc6\xff\x6a\x6a\xb4\x4c\x02\x72\x4e\x51\x13\xbc\x08\xa2\x2a\xc1\xe0\x6c\x52\x3f\x35\xf2\x68\x0b\x4d\xcc\xac\xfc\x26\x15\x56\x95\xd4\x5f\x2f\x41\x1b\xdd\x7a\x8c\xcd\x50\xff\x72\xb6\xc7\xf4\x34\xcd\x25\x78\x76\xcb\xb8\x82\x64\x2b\x7f\x10\x02\x1f\x63\xf7\xaa\xc1\x50\x99\x0a\x5a\x50\x86\x15\x17\x71\xb7\x6d\xcb\x14\x11\x8f\x38\x25\xfd\x27\x6b\xbf\xb1\x7e\x7c\x57\xe5\x39\x7e\xc8\x35\xcb\x67\xbe\xf5\x1e\xb0\x60\x5a\x12\xc9\xf6\x06\x9a\xc6\x51\xb8\x5e\x20\xe2\x9e\xb3\xce\xe5\x06\x1c\x8f\xdd\xc8\x6c\xf8\x80\x8f\x39\xc7\xd9\x25\x58\xa7\x5a\x86\xab\x41\x0d\x42\x9b\xf3\x49\x99\x41\x46\xb4\x40\x1e\x4c\xec\x69\xc3\x95\x75\x18\xab\x3c\xa3\x37\x7d\xd4\x2a\x57\x3b\xfc\x44\x30\x72\x5e\x95\x20\xe4\x74\x90\xdc\x18\xb8\xa5\xa2\x9c\x59\x61\x3d\xe4\x3c\xfd\x9c\xf2\xa2\x20\x4c\x8d\x97\x49\x2e\x89\xd9\x36\x15\x05\x6a\xd8\x57\x05\x66\x81\xe9\xd9\xa0\x83\xe0\x7c\x83\xd4\xb1\x24\x33\x71\x53\x2a\x51\xa5\xca\x8f\x23\x23\x33\xf5\x8c\x54\xc7\xc4\xa1\x03\xcc\x7b\x65\xab\xaa\x90\x15\xa4\xa3\x90\x91\xf5\x29\x86\x91\xaf\x6c\x2e\x20\xb9\x7f\xc2\xbb\x1d\x11\x3f\x72\x51\x60\xb3\x7b\xe8\xe4\x9a\x3f\x41\x99\x82\x28\x1a\x44\x15\x63\x2e\xc1\xf1\x76\xdd\xbe\x1a\xb7\x98\xd9\x31\xb2\x95\x80\xaf\x90\x06\xf7\x6e\xc0\xfd\x2e\x39\x9b\xa6\x32\x84\x16\xbc\x9f\x6f\xa6\x82\xcd\x8c\xc6\x93\xb7\xfc\xa3\xd6\xeb\x38\x24\x8d\x5d\x07\x75\x8e\x31\x8a\x00\x9d\x1f\xbd\xc1\x92\x68\x80\xf1\x70\xc1\x73\xfd\xfe\xe3\x35\xd7\x41\xf4\xcb\xfb\x87\xdf\x49\xaa\x86\x27\xda\xc8\xd0\x34\xe7\x83\x0c\x3a\xbb\xd1\x68\xc0\x7e\xee\xf8\xd2\x67\x73\xa9\x9f\xbc\xd4\xe8\xac\xda\xe7\xb8\x99\x35\x5e\x5d\x52\x98\xd7\x1d\x51\x12\xd4\x9e\x04\x3e\xfb\xc8\x85\xf9\x36\xe5\x3e\x9d\xab\xdb\xea\x41\x57\x09\xc9\x1d\x49\x09\x3d\x10\xd1\x6e\x99\xce\xc9\xb1\xc1\xb8\x8a\xb5\xaf\x18\xbf\x72\x19\x62\x02\x42\xe2\xb9\x16\x1a\x30\x85\xbe\x02\xf1\xad\x10\x5c\xac\x62\xed\xd4\x94\xed\xa0\x46\xff\xe7\x70\x3f\x16\x2a\xb9\x37\xde\xf1\xb8\x8a\x7e\xa9\x6b\xa8\xca\x92\x08\x48\x7e\x26\x6a\xcf\xb3\xd6\xa0\x3e\x60\xb5\x87\xa6\xf9\xf5\x97\xd7\xd9\xaf\x6d\x94\xea\xa2\x49\x60\x7b\x4e\x2d\x15\xfb\xcc\xf8\x13\x03\xa2\xf1\xc2\x6c\xb1\x04\xaf\xff\xff\xd0\x2d\x46\x6b\x98\xaa\xb8\x9e\x91\x4e\x8f\xd3\x0b\xb4\xb3\x08\xd7\xc0\x13\x67\xef\x7d\x09\x85\x8c\x1b\x8c\x7d\xe3\xe5\x62\x7e\x4b\x94\x83\xbe\x8a\xff\x3b\xfc\xc9\x33\x95\x4e\x72\x23\x83\x7c\xb9\xa0\x04\xc1\xd9\x9d\xf3\xa3\x55\x97\x3b\x45\xc5\x14\x2d\x48\x72\x6d\x3a\x80\x76\x7d\x0d\x29\x67\xb2\x2a\x88\xe8\x37\xb8\x0f\x6b\xed\xa9\x05\x56\x52\x1b\xb6\x36\xe5\x3b\xb2\xa3\x52\x89\x63\xdc\x5a\xde\x6c\x1a\xb2\x15\xef\xfe\x98\x09\xd3\x3d\x74\x34\xb8\xa4\x5c\xd7\x2e\xcb\x23\x80\x7d\x26\xa6\x63\xed\xe5\x55\x77\x2e\x79\x4b\x94\x85\xbe\x8a\x3c\x97\x88\x62\x8d\x88\x3e\xce\xc3\xf8\xe6\x4a\xa7\xa5\xa0\x1c\xd4\xec\x1d\x88\xd0\x95\xbf\xab\xd0\xf3\xba\x86\x14\x17\x24\x38\xba\xd6\x3c\x6a\x1a\xac\xe1\xf7\x47\x56\x73\xc8\x62\x4b\x8b\x3e\xf6\xcd\x15\x30\x9a\x3b\xbc\x4e\xc1\x46\x64\x32\xd9\xb2\x03\xce\x69\xa6\x4d\x63\xe5\x39\xff\x1a\x22\x2b\x9b\x68\x0d\x51\x90\x65\xa2\xf5\x2c\x7b\x1a\xa3\xcb\x55\x23\x27\x9e\x96\xc7\xd5\x1c\xbb\x7d\x02\xd4\x96\x6a\xc4\xb4\xa7\x79\xd6\xeb\xf2\x81\xb2\x4c\x07\x37\xa7\x41\xaa\x48\x21\x4d\x24\xf7\xf4\xd1\x49\x73\x8c\x39\x10\xe7\x90\x56\x0d\xdb\xaa\x77\xba\x55\x9c\xe3\xbf\x33\xd0\xe7\x45\x6f\x24\xf5\x55\xa2\x1a\x2f\x8d\x65\xb5\x95\xd7\x95\x54\xbc\xb0\x45\xcc\x62\xd3\x72\xd4\x27\x1f\xb0\x90\xc6\x1a\x6c\xaa\x80\xe8\xf5\x1f\xd1\xb8\x30\x3a\x6d\x07\xff\x1e\xcb\xf3\xfd\x2a\x68\x47\x34\xf7\x9a\xc5\xd5\x8c\x0c\x92\x55\x80\x2a\x8e\x5f\xa8\x9b\xb3\x83\xdf\x61\xd8\xe8\xfa\xcf\xf1\x84\x21\x65\x27\x3a\x99\x0e\xed\xa0\xdb\x74\x87\x23\x5b\x0f\x44\x2f\x27\x6d\x4e\xec\x7f\x9a\xe7\x80\xb5\x93\x91\xec\xb9\xee\xad\xcd\x52\x5d\x9a\x9a\x6b\x1d\x47\x8d\x63\x9b\xa0\xfb\xd8\xd2\xa5\x87\xd2\x15\xcb\x58\xea\x2a\xce\x66\xLine truncated
|
||||
|
||||
func templatesClientResponseGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -182,8 +188,8 @@ func templatesClientResponseGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/client/response.gotmpl", size: 6363, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x40, 0x2e, 0x8b, 0x3b, 0xc7, 0xb, 0xf9, 0x2c, 0x74, 0x50, 0xe2, 0xd0, 0xb6, 0xa3, 0x6a, 0x54, 0xe0, 0x84, 0x11, 0xaa, 0xa1, 0x6c, 0xe4, 0x98, 0xd1, 0x66, 0x16, 0x20, 0x23, 0x3d, 0x60, 0x14}}
|
||||
info := bindataFileInfo{name: "templates/client/response.gotmpl", size: 10424, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xb, 0x12, 0xba, 0xe0, 0x4e, 0x37, 0xb2, 0xf0, 0x5b, 0x83, 0xc4, 0x4c, 0x3c, 0x98, 0x58, 0x1a, 0x3c, 0xfb, 0x9a, 0x3b, 0x3c, 0x96, 0xf5, 0xbd, 0x93, 0x7d, 0xb4, 0xbc, 0xb5, 0xf4, 0xe, 0x57}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
@@ -227,7 +233,7 @@ func templatesContribStratoscaleClientFacadeGotmpl() (*asset, error) {
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesContribStratoscaleServerConfigureapiGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xcc\x58\xdf\x6f\xe3\xb8\xf1\x7f\xb6\xfe\x8a\xf9\x0a\xdf\x02\x52\xe0\xc8\x40\x1f\xb7\xf0\x83\x6f\x73\xd7\x73\xaf\x97\x18\x9b\xb4\xf7\x50\x14\x05\x43\x8d\x65\x36\x32\xa9\x25\xa9\x24\x5e\x43\xff\x7b\x31\xfc\x61\xcb\xb6\xbc\x71\x90\x2b\xd0\x7d\xd8\x58\xe2\xcc\xf0\x33\x9f\x19\x0e\x47\x33\x99\xc0\x67\x55\x22\x54\x28\x51\x33\x8b\x25\x3c\x6e\xa0\x52\xd7\xe6\x85\x55\x15\xea\x3f\xc1\xcd\x1d\xdc\xde\x3d\xc0\x8f\x37\xf3\x87\x22\x49\x92\xed\x16\xc4\x12\x8a\xcf\xaa\xd9\x68\x51\xad\x2c\x5c\x77\xdd\x64\x02\xdb\x2d\x70\xb5\x5e\xa3\xb4\x47\x6b\xdb\x2d\xa0\x2c\xa1\xeb\x92\x24\x69\x18\x7f\x62\x15\x92\x70\x31\x5b\xcc\x17\xe1\x91\xd6\xc4\xba\x51\xda\x42\x96\x8c\x52\xae\xa4\xc5\x57\x9b\xd2\x4f\xbd\x69\xac\x9a\xd8\xda\xd0\x93\x44\x3b\x59\x59\xdb\xd0\xef\x5a\x55\xf4\x67\xb9\xb6\x69\x92\x8c\xd2\x4a\xd8\x55\xfb\x58\x70\xb5\x9e\x54\xea\x5a\x35\x28\x59\x23\x26\xa8\xb5\xd2\x4e\x75\x78\xbd\x56\xac\xfc\xce\xb2\x6e\xa5\x15\x6b\x7c\x53\x60\xb2\x16\x65\x59\xe3\x0b\xd3\x17\xc8\x1a\xe4\xad\x16\x76\x93\x26\x09\x10\x11\xde\x71\x03\xc5\x0d\x2e\x59\x5b\xdb\x79\x78\xee\xba\xa3\xf5\xde\x42\x4e\x51\xf8\xff\xc8\xe6\xa7\x29\x14\x7d\x2a\xed\xa6\x41\x08\x24\xfe\x82\x1b\x30\x56\x0b\x59\x25\x09\x57\xd2\x58\x98\xb5\x76\x45\x6f\x7b\x02\x53\x48\xe9\x6d\xea\x82\xab\x99\xac\x10\x8a\xbb\x86\xb2\x41\x28\xf9\x67\xad\xda\xc6\x50\x24\x93\xc9\xa4\x52\x9f\x62\x9e\xc0\x5a\xf1\x27\xd4\x1b\xb8\x96\x6c\xed\x42\xda\x30\xc3\x59\x2d\xbe\x21\x14\xb7\x6c\x8d\x5d\x37\x5b\xcc\xe1\x5a\xc8\xe6\xa9\x4a\x92\xc9\xd5\x80\x08\x78\x19\x4a\x87\x1b\x34\x5c\x8b\x86\x76\x84\xae\x83\xab\x89\x77\xe3\xac\x8e\x90\x16\xf5\x92\x71\x84\xed\x10\x6a\x0f\x78\x14\x92\xf5\xbe\x5d\xaf\x19\x41\xa5\x77\xe7\x90\x38\x18\x51\xd2\x43\x20\x7d\xac\x0d\x3a\x23\x7d\x84\x6f\x1b\x3a\xf5\x67\x14\x4e\x42\x04\x76\xaa\x98\x71\xfb\x1a\xe3\x52\x7c\xf6\x7f\xc7\xd0\x30\xcd\xd6\x06\xb6\xdb\x18\xe4\xae\x2b\x06\xd5\x17\x4e\x30\x87\x7d\x36\x16\x5f\xd0\x34\x4a\x96\xa8\x5d\x68\xe3\xee\x5d\xd2\x3b\x94\xee\xfc\xcb\xa5\xa8\x40\x18\xda\x7c\x29\xaa\xd6\x73\x08\x4b\xa5\xe1\x67\x26\xcb\x1a\xb5\x8f\x46\x10\x34\x56\xb7\xdc\xc2\xd6\xb9\xf1\x9d\x7c\x19\xf6\x72\xb6\x98\x1f\x72\xf1\x57\x45\x85\x06\x96\xad\xe4\x99\xcf\xd5\x31\x14\x45\xb1\x8b\xf0\xb6\xcb\x93\xd1\x64\x02\x73\x29\x51\xff\xba\x73\x8e\xf0\x12\x42\xbb\x42\x58\x79\x94\x80\xaf\xc8\x5b\xab\xb4\x29\xe0\x61\x85\x06\xa1\x54\x20\x95\x05\xd6\x34\xf5\x06\xac\x72\xc2\xa1\xb2\x15\xff\x36\x4a\x42\xa9\x78\x4b\x55\xab\x70\x5b\x3c\xac\xb0\x47\x5f\x30\x87\x06\xd8\xd2\xa2\x06\xad\x5a\x2b\x64\x05\x8f\xad\x85\x47\x5c\x2a\x8d\xc0\x5a\xbb\x42\x69\x05\x77\xbe\x8f\xe1\x51\xc8\x92\x44\x98\x2c\xe1\x99\xd5\xa2\x74\xef\x93\xd1\x31\x76\xe7\x2c\xd5\xb2\x22\x10\x9c\x43\xff\x29\x71\x68\xe8\x50\x2a\x2d\xbe\xa1\x26\x5f\x5b\x83\x25\xb9\xc0\xe2\x5b\x60\xa0\xf1\x6b\x8b\xc6\x06\x7c\xe4\x1c\xe9\x38\xeb\x2e\x82\x2f\xcc\x00\x67\x75\x8d\x25\xb4\x86\x70\x91\x88\x3b\xec\x57\xe9\x4e\xca\xb8\xcd\x08\x31\xad\x36\x5a\x48\x2e\x1a\x56\x3b\x65\x63\x95\xc6\x12\x84\x74\x6b\x21\x37\xe3\x63\x1a\x6a\x49\xba\x5b\x78\x66\x75\x8b\x45\x32\xea\x21\x77\x9e\x5e\x39\xe7\xbe\x78\xb4\x39\xb8\xba\x9c\xf4\xd3\xe7\x3e\x54\xc5\x1b\x5c\x0a\x29\x4e\x4f\xf0\xdc\xfc\xc0\x8c\xe0\xce\x3b\x7f\xf8\x3c\x3d\x87\x19\x36\xbf\xa1\xb3\x46\x49\xf1\x48\xd2\x47\xd1\xf1\xb0\x06\x35\x08\x63\x6b\x50\x43\xcc\xbf\x86\x19\x13\x1e\x72\xc8\x7a\xa9\x38\xf6\xe0\xf3\x93\xe3\xec\x51\xce\x16\xf3\x5f\x70\x73\x11\xcc\x59\xd3\xd4\x02\x0d\xbc\xac\x30\xd0\x49\x75\x23\x1c\x92\xd4\x57\x23\xd5\x6a\xee\x4a\x8a\x30\x60\xd0\xbe\xe1\x81\x55\x4f\x28\x2f\x43\x7d\x00\xfa\x8e\xac\xfe\xf1\x4d\xc0\x3f\x29\x0d\x41\xf4\x5d\xc4\xf6\x61\x8d\xc1\x70\xd5\xa0\x81\x7f\xfc\xf3\x5d\xec\xc6\xdf\x3b\x80\x61\x77\x3a\xff\x8a\x8e\x86\x8b\x3a\xab\x6b\xf0\x11\x38\x45\xb8\x0b\xcc\x5e\xf3\xa0\xe2\xec\xfe\x86\x4c\x2c\x1e\x08\xf6\xec\xc0\x4c\x0e\xe1\x16\x2f\x0e\x0c\xbd\x0d\xea\x07\x64\x1a\xf5\x09\xa8\x5d\x4e\x1f\x63\x8a\x18\xfe\x66\x50\x2f\x98\x31\xbf\x17\x8c\xc1\x53\xe1\xc1\x7d\x8f\x9a\x08\xe7\x9e\x62\x57\xbe\x83\x18\x7f\xbf\x84\xa2\x06\x1a\x6d\xab\xa5\x01\x26\x0f\x8a\x1d\x54\xe2\x39\x1c\x81\x58\xc7\x0f\xee\x21\x32\x31\xb7\xb0\x56\xad\xb4\xc6\xf9\x41\xa2\x8f\x54\xd0\xd0\x18\xa8\x55\x25\x38\xb5\x49\x35\x52\x21\x47\x6d\x62\x7d\xf2\x3d\x68\xa8\xda\x45\x42\x3e\x45\x2c\x19\x0f\x97\x59\x0e\x07\x65\x38\x26\x20\x5d\x6e\xab\x31\xfc\xcb\x3d\x53\x87\x15\xd6\x67\x8b\x79\xc6\xf3\x64\xe4\x5d\x81\x95\x5b\x3f\x74\x93\xba\x93\x0f\x78\x1a\xeb\x30\x57\x5a\xfb\xdb\x9b\xea\xf6\xd5\x70\xa7\x21\xa4\xb1\x4c\x72\x2c\xfe\x1b\x1c\x39\x5f\xcf\xd1\x74\xf5\x76\x3f\x32\x5b\xcc\xfb\x74\x9a\x06\xf9\x8e\x4e\xd7\x79\x17\x33\xc9\xea\xcd\x37\x2c\xb3\x70\x25\xd3\x87\x43\x76\xef\x7f\xff\xe5\xfe\xee\x36\x1f\x43\x9a\xe6\xc9\x48\x2c\x9d\xde\xff\x4d\x41\x8a\x9a\x6c\x45\xfe\xa5\xa8\xc7\xfe\xbf\xe5\xda\x16\x3f\xd2\x5e\xcb\x2c\x65\xde\x6c\xbc\xe8\x3f\xc1\x1f\x9e\x53\xb7\x73\x9e\x8c\xba\x64\xc4\x1a\x41\x10\x0e\x1c\xb8\xc5\x97\x73\x3e\x64\x04\x3c\x77\x6a\xc5\x3d\xea\x67\x74\xdb\xc0\xd4\xbb\x66\x7a\xef\xbc\x4c\x68\x67\xa6\xc0\xc3\xcf\xc4\x39\xc0\x8b\xa1\x12Line truncated
|
||||
var _templatesContribStratoscaleServerConfigureapiGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xcc\x59\x5f\x6f\xe3\xb8\x11\x7f\xb6\x3e\xc5\x54\x68\x01\x2b\x70\x64\xa0\x8f\x5b\xf8\xc1\xb7\xb9\xeb\xb9\xd7\xcb\x1a\x9b\xb4\xf7\x50\x14\x05\x43\x8d\x65\x36\x32\xa9\x25\xa9\x24\x5e\x43\xdf\xbd\x18\xfe\xb1\x64\x5b\xde\x78\x2f\xb7\xe8\xed\xc3\x5a\x12\x67\x86\xf3\x9b\x7f\x1c\x4e\xa6\x53\x78\xaf\x0a\x84\x12\x25\x6a\x66\xb1\x80\x87\x2d\x94\xea\xda\x3c\xb3\xb2\x44\xfd\x17\xb8\xf9\x00\xb7\x1f\xee\xe1\xfb\x9b\xc5\x7d\x9e\x24\xc9\x6e\x07\x62\x05\xf9\x7b\x55\x6f\xb5\x28\xd7\x16\xae\xdb\x76\x3a\x85\xdd\x0e\xb8\xda\x6c\x50\xda\xa3\xb5\xdd\x0e\x50\x16\xd0\xb6\x49\x92\xd4\x8c\x3f\xb2\x12\x89\x38\x9f\x2f\x17\xcb\xf0\x4a\x6b\x62\x53\x2b\x6d\x61\x9c\x8c\x52\xae\xa4\xc5\x17\x9b\xd2\xa3\xde\xd6\x56\x4d\x6d\x65\xe8\x4d\xa2\x9d\xae\xad\xad\xe9\xb9\x52\x25\xfd\xac\x36\x36\x4d\x92\x51\x5a\x0a\xbb\x6e\x1e\x72\xae\x36\xd3\x52\x5d\xab\x1a\x25\xab\xc5\x14\xb5\x56\xda\xb1\x0e\xaf\x57\x8a\x15\x5f\x58\xd6\x8d\xb4\x62\x83\xaf\x12\x4c\x37\xa2\x28\x2a\x7c\x66\xfa\x02\x5a\x83\xbc\xd1\xc2\x6e\xd3\x24\x01\x32\x84\x07\x6e\x20\xbf\xc1\x15\x6b\x2a\xbb\x08\xef\x6d\x7b\xb4\xde\x5b\xc8\xc8\x0b\x7f\x8c\xd6\x7c\x37\x83\xbc\x6f\x4a\xbb\xad\x11\x82\x11\x7f\xc2\x2d\x18\xab\x85\x2c\x93\x84\x2b\x69\x2c\xcc\x1b\xbb\xa6\xaf\x3d\x82\x19\xa4\xf4\x35\x75\xce\xd5\x4c\x96\x08\xf9\x87\x9a\xa2\x41\x28\xf9\x57\xad\x9a\xda\x90\x27\x93\xe9\xb4\x54\xef\x62\x9c\xc0\x46\xf1\x47\xd4\x5b\xb8\x96\x6c\xe3\x5c\x5a\x33\xc3\x59\x25\x3e\x23\xe4\xb7\x6c\x83\x6d\x3b\x5f\x2e\xe0\x5a\xc8\xfa\xb1\x4c\x92\xe9\xd5\x00\x09\x78\x1a\x0a\x87\x1b\x34\x5c\x8b\x9a\x76\x84\xb6\x85\xab\xa9\x87\x71\x96\x47\x48\x8b\x7a\xc5\x38\xc2\x6e\x48\x6b\xaf\xf0\x28\x04\xeb\x5d\xb3\xd9\x30\x52\x95\xbe\x9d\xd3\xc4\xa9\x11\x29\xbd\x0a\xc4\x8f\x95\x41\x27\xa4\xaf\xe1\xeb\x82\x4e\xf1\x8c\x42\x26\x44\xc5\x4e\x19\xc7\xdc\xbe\x44\xbf\xe4\xef\xfd\xef\x04\x6a\xa6\xd9\xc6\xc0\x6e\x17\x9d\xdc\xb6\xf9\x20\xfb\xd2\x11\x66\xd0\x45\x63\xfe\x11\x4d\xad\x64\x81\xda\xb9\x36\xee\xde\x26\xbd\xa4\x74\xf9\x2f\x57\xa2\x04\x61\x68\xf3\x95\x28\x1b\x6f\x43\x58\x29\x0d\x3f\x32\x59\x54\xa8\xbd\x37\x02\xa1\xb1\xba\xe1\x16\x76\x0e\xc6\x17\xe2\x65\x18\xe5\x7c\xb9\x38\xb4\xc5\xdf\x15\x15\x1a\x58\x35\x92\x8f\x7d\xac\x4e\x20\xcf\xf3\xbd\x87\x77\x6d\x96\x8c\xa6\x53\x58\x48\x89\xfa\xe7\x3d\x38\xd2\x97\x34\xb4\x6b\x84\xb5\xd7\x12\xf0\x05\x79\x63\x95\x36\x39\xdc\xaf\xd1\x20\x14\x0a\xa4\xb2\xc0\xea\xba\xda\x82\x55\x8e\x38\x54\xb6\xfc\xbf\x46\x49\x28\x14\x6f\xa8\x6a\xe5\x6e\x8b\xfb\x35\xf6\xcc\x17\xc4\xa1\x01\xb6\xb2\xa8\x41\xab\xc6\x0a\x59\xc2\x43\x63\xe1\x01\x57\x4a\x23\xb0\xc6\xae\x51\x5a\xc1\x1d\xf6\x09\x3c\x08\x59\x10\x09\x93\x05\x3c\xb1\x4a\x14\xee\x7b\x32\x3a\xd6\xdd\x81\xa5\x5a\x96\x07\x03\x67\xd0\x7f\x4b\x9c\x36\x94\x94\x4a\x8b\xcf\xa8\x09\x6b\x63\xb0\x20\x08\x2c\x7e\x05\x06\x1a\x3f\x35\x68\x6c\xd0\x8f\xc0\x11\x8f\x93\xee\x3c\xf8\xcc\x0c\x70\x56\x55\x58\x40\x63\x48\x2f\x22\x71\xc9\x7e\x95\xee\xa9\x8c\xdb\x8c\x34\xa6\xd5\x5a\x0b\xc9\x45\xcd\x2a\xc7\x6c\xac\xd2\x58\x80\x90\x6e\x2d\xc4\x66\x7c\x4d\x43\x2d\x49\xf7\x0b\x4f\xac\x6a\x30\x4f\x46\x3d\xcd\x1d\xd2\x2b\x07\xee\xa3\xd7\x36\x03\x57\x97\x93\x7e\xf8\xdc\x85\xaa\x78\x83\x2b\x21\xc5\x69\x06\x2f\xcc\x77\xcc\x08\xee\xd0\xf9\xe4\xf3\xe6\x39\x8c\xb0\xc5\x0d\xe5\x1a\x05\xc5\x03\x51\x1f\x79\x27\x81\xf3\x2c\xa4\x64\x63\x50\x43\x0c\xc0\x9a\x19\x13\x5e\x32\x18\x07\x2d\x96\xd1\x36\x0b\x73\xdb\x54\x15\x7b\xa8\x28\xa0\xaf\xf6\xd9\x44\x89\xbf\xa7\x81\xb6\x9d\x78\xa4\xd9\x49\xee\x7b\x48\xf3\xe5\xe2\x27\xdc\x5e\x84\x69\x5e\xd7\x95\x40\x03\xcf\x6b\x0c\xb6\xa7\xbd\x42\x46\xa5\xbe\x74\xa9\x46\x73\x57\x7f\x84\x01\x83\xf6\x35\xb8\x56\x3d\xa2\xfc\xed\x21\x1e\x20\xfc\x40\x1a\xfc\xf9\x55\x74\x3f\x28\x0d\x81\xf4\xeb\x5c\xd6\xc7\x30\x01\xc3\x55\x8d\x06\xfe\xf5\xef\x6f\xe6\xb7\xf8\xbc\x47\x13\x54\xa5\x32\xa4\x28\x43\x5d\xf0\xb1\xaa\x02\xef\xdb\x63\x38\xa3\xce\xe5\x1d\xe7\x41\xe1\xdb\xff\x86\x84\xc8\xef\x09\xe2\xfc\x40\x4c\x06\xa1\x99\xc8\x0f\x04\xbd\xae\xd4\x77\xc8\x34\xea\x13\xa5\xf6\xa9\x75\xac\x53\xd4\xe1\x1f\x06\xf5\x92\x19\xf3\x5b\xa9\x31\x94\x9c\x23\xaf\xdc\x97\x4c\x13\xd5\xb9\x23\x3f\x17\x5f\x61\x18\x7f\xcc\x85\xda\x0a\x1a\x6d\xa3\xa5\x01\x26\x0f\x6a\x2e\x94\xe2\x29\x24\x57\x3c\x4e\x0e\x8e\x43\x12\xb1\xb0\xb0\x51\x8d\xb4\xc6\xe1\x20\xd2\x07\xaa\xab\x68\x0c\x54\xaa\x14\x9c\xba\xb5\x0a\xe9\x3c\x41\x6d\x62\x99\xf4\xad\x70\x38\x3c\xf2\x84\x30\x45\x5d\xc6\x3c\x9c\xa9\x19\x1c\x9c\x06\x31\x00\xe9\x8c\x5d\x4f\xe0\x3f\xee\x9d\x1a\xbd\xb0\x3e\x5f\x2e\xc6\x3c\x4b\x46\x1e\x0a\xac\xdd\xfa\x21\x4c\x6a\x92\xde\x80\x34\x1e\x07\x5c\x69\xed\x9b\x08\x3a\x3e\xae\x86\x1b\x1e\x21\x8d\x65\x92\x63\xfe\x2d\x6c\xe4\xb0\x9e\x33\xd3\xd5\xeb\x6d\xd1\x7c\xb9\xe8\x9b\xd3\xd4\xc8\xf7\xe6\x74\x17\x80\x7c\x2e\x59\xb5\xfd\x8c\xc5\x38\x74\x06\x74\x7f\x19\xdf\xf9\xe7\xbf\xdd\x7d\xb8\xcd\x26\x90\xa6\x59\x32\x12\x2b\xc7\xf7\x87\x19\x48\x51\x91\xac\x68\x7f\x29\xaa\x89\xff\x6f\xb5\xb1\xf9\xf7\xb4\xd7\x6a\x9c\x32\x2f\x36\xf6\x1b\xef\xe0\x4f\x4f\xa9\xdb\x39\x4b\x46\x6d\x32\x62\xb5\x20\x15\x0e\x00\xdc\xe2\xf3\x39\x0c\x63\x52\x3c\x73\x6c\xf9\x1dLine truncated
|
||||
|
||||
func templatesContribStratoscaleServerConfigureapiGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -242,8 +248,8 @@ func templatesContribStratoscaleServerConfigureapiGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/contrib/stratoscale/server/configureapi.gotmpl", size: 6644, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x40, 0xda, 0x58, 0x57, 0x11, 0x3a, 0xc4, 0x3e, 0x12, 0x28, 0x47, 0xd7, 0x99, 0x62, 0xa, 0xad, 0x1c, 0x36, 0x53, 0xbb, 0x8a, 0xae, 0x4d, 0x9f, 0x56, 0x4f, 0x73, 0x34, 0x5a, 0xca, 0x14, 0xb2}}
|
||||
info := bindataFileInfo{name: "templates/contrib/stratoscale/server/configureapi.gotmpl", size: 7309, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x21, 0xaa, 0xda, 0xe4, 0xfd, 0x5f, 0x38, 0xb4, 0x7b, 0x3a, 0xca, 0x25, 0xf8, 0x94, 0xfa, 0xb1, 0x12, 0x89, 0x82, 0x14, 0xfd, 0xe, 0x38, 0xa7, 0xdc, 0x74, 0xb2, 0xc2, 0x3e, 0x4, 0x31, 0x6f}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
@@ -267,7 +273,7 @@ func templatesContribStratoscaleServerServerGotmpl() (*asset, error) {
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesDocstringGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x6c\x8e\x41\xae\x83\x30\x10\x43\xf7\x9c\xc2\x62\xff\xc9\x25\xfe\xba\xab\x5e\x00\x25\xa6\x1d\x89\x4c\x2a\x92\x6e\x3a\xe2\xee\x15\x8a\x5a\x22\xca\x6e\x64\x3f\xdb\x63\x86\xc0\x49\x94\xe8\x43\xf2\xb9\x2c\xa2\xb7\x1e\xeb\xda\x01\x66\x7f\x90\x09\xc3\x55\xca\xcc\x2a\x55\xd1\xa7\x18\xa9\xe5\xc4\xd9\xf0\x7f\x66\xbf\xc8\xa3\x48\xd2\xcd\x72\xae\x73\x0e\x66\x7b\xea\x00\x7c\xb2\xd4\xb0\xef\x72\xce\x3c\xb6\x9d\x7d\xf0\xd3\xf5\x0d\x37\xf4\xfd\x19\x47\x95\x17\x31\x5c\xc6\xc8\x86\xab\x8b\xcd\xf9\x0e\x00\x00\xff\xff\x57\x05\xa1\xd1\x0e\x01\x00\x00")
|
||||
var _templatesDocstringGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x6c\x91\xb1\x6e\xc4\x20\x0c\x86\xf7\x3c\x85\x95\xbd\xb0\x77\x6e\xc7\x54\x1d\xfa\x02\x28\x71\x5a\x4b\xc1\x20\xa0\x52\x74\x28\xef\x7e\xe2\xb8\xbb\x70\xc0\x16\xec\xcf\x1f\xf9\x4d\x8c\xb0\xe0\x4a\x8c\x30\x2e\x66\xf6\xc1\x11\xff\x8e\x70\x1c\x03\x40\x8c\x6f\x40\x2b\x88\x1f\x0a\x1b\xe6\x52\x2e\xce\x46\x6b\xe4\xd0\xe9\x24\xfc\x03\xfd\xec\xc8\x06\x32\x9c\x5a\x52\x0e\x52\x42\x8c\xe7\x54\x05\x3c\x66\x91\x97\xf3\x5e\xdc\x3c\xd6\xb6\xde\x1f\x34\xae\xe7\x70\x41\xff\xfd\x6b\xc5\x74\x41\x10\x5f\x4a\x63\xc1\x95\x37\xd2\x0a\xc6\x81\x98\x88\xbf\x9d\xb1\xe8\x02\xa1\xaf\x8f\x39\x4e\x19\xb6\xd3\x87\x89\x18\xce\xe2\x7b\xca\xde\x72\x4d\xea\xc2\xa9\xf6\xd6\xa9\xf6\xd6\x59\x73\xfd\x4d\x56\x21\xc5\xe7\xae\xb4\xcd\xcf\x26\x25\xdc\x4f\x37\xa3\x75\x94\x76\x5a\x00\x2f\x8a\xe2\xf3\x1a\x00\x00\xff\xff\x86\x40\x49\xf2\x36\x02\x00\x00")
|
||||
|
||||
func templatesDocstringGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -282,8 +288,8 @@ func templatesDocstringGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/docstring.gotmpl", size: 270, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x1d, 0x3e, 0x50, 0x87, 0x7e, 0xc7, 0xce, 0xf0, 0x64, 0xaf, 0x8f, 0xab, 0x38, 0x17, 0xd1, 0xd7, 0x49, 0x9, 0xe4, 0x59, 0xa4, 0xdd, 0x14, 0x7b, 0x7b, 0xa3, 0x65, 0xb9, 0xe6, 0xf6, 0xa1, 0x23}}
|
||||
info := bindataFileInfo{name: "templates/docstring.gotmpl", size: 566, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x47, 0x8, 0xf2, 0xcc, 0x14, 0x7c, 0x30, 0xa, 0x46, 0x12, 0xc8, 0xf, 0x70, 0xff, 0xf5, 0x47, 0x24, 0xbf, 0xfa, 0x98, 0x17, 0x3e, 0xa4, 0xbd, 0x1c, 0x9a, 0xc, 0x3c, 0x91, 0xa9, 0xbf, 0x5e}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
@@ -307,6 +313,26 @@ func templatesHeaderGotmpl() (*asset, error) {
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesMarkdownDocsGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x5b\xdd\x6e\xdb\x38\x16\xbe\xd7\x53\x1c\x38\x5d\x20\x16\x26\x69\xb1\x97\xc1\x4c\x81\x4c\xd3\x1f\x03\xcd\x26\x9b\xb4\x7b\x93\x2d\x10\x56\xa2\x63\xb5\x92\xa8\x92\x74\x27\xae\x9d\xa7\xd8\xdb\x7d\xba\x7d\x92\x05\xff\x7f\x44\xc9\x4e\x27\x9d\x29\x06\xed\xc5\xc4\x22\x0f\x0f\xc9\x73\xbe\xf3\x2b\xcd\x7a\x7d\x00\x25\x9e\x57\x2d\x86\x09\xbe\xe5\x98\xb6\xa8\x3e\x21\xc5\x04\xee\xee\xd6\xeb\xc7\x39\x50\xdc\x96\x98\x32\x30\x73\x50\x92\x62\xd9\xe0\x96\x23\x5e\x91\x16\xf2\xc7\x77\x77\x19\x80\xe0\xf2\x5b\xc5\x17\x70\xf8\xdc\xf1\x60\x20\xe7\xd4\x6c\x35\x87\xc3\xb7\x17\xaf\xcd\x90\x1b\x3c\xc1\xac\xa0\x55\x27\xb9\xdd\xdd\x65\x4f\xe1\x6a\xbd\x06\x4e\xab\xe6\xb2\x43\x05\x8e\xe7\xdf\xed\xaf\xd7\x86\xd1\xd4\xe3\x84\x6b\x86\xf5\xf2\x0b\x8c\x4a\x68\x08\xc5\x83\xb4\x6d\xe9\x9f\xcc\x2d\x1d\xdb\x38\xeb\xad\xf6\x1e\xbc\x9f\x99\x2f\xd0\x92\x14\xe7\x88\xa2\xa6\x27\x4d\x04\x9d\x18\xc7\x1c\x53\x25\x37\x56\x35\x5d\x8d\x81\x15\x0b\xdc\x20\x25\xd5\x8d\x38\xcf\xe1\x3f\x50\x23\x4e\x07\x1b\xb8\x16\x8f\xaf\x49\x81\xf4\x89\xae\x41\x52\x48\x46\x27\xa4\x78\xb3\xea\x30\x1c\x7a\xa4\x2f\x89\x1c\xb2\x84\x42\xd8\xcf\x48\x5d\xe3\x42\x30\x78\x41\x68\x83\xb8\x98\x5d\xaf\x85\x4e\x7b\x33\x7d\xda\xc3\x67\x8b\xaa\x2e\xf5\x12\x75\x5d\xc7\xf9\x02\x7f\x5a\x56\x14\x8b\xc1\xff\xfd\xf7\x3f\x09\x82\x13\x3c\x47\xcb\xda\xec\xf8\x81\x91\x36\x1e\xf3\x57\x0c\xea\x01\x36\x63\xd2\x3e\x25\x25\xae\x2f\xa5\x10\x13\x32\xf7\xa5\xeb\x00\x38\x63\xc7\x94\xa2\x55\x0c\xd6\x19\x3b\xae\x2b\xc4\xb0\xd2\xf6\x95\xdc\x88\x92\xee\x1c\x15\x1f\xd1\x0d\xf6\xc4\xfb\x6e\x7f\x4f\x88\x10\xb1\x05\xa6\xd5\x17\x0c\xfb\x09\xb2\x29\x1c\x18\x0c\x5a\xc8\xc9\x4d\x38\x6e\x58\xcf\x26\x50\x5b\xea\xa9\xc3\x19\x3b\xa7\x55\x53\xf1\xea\x33\x86\xfd\x96\x70\x37\xae\x4f\x27\x39\x67\x72\xa5\xba\x9e\x83\xc2\x41\xc0\x57\xee\x29\x87\xae\xde\xf5\x6f\xa3\xb8\xee\x78\x27\x9f\xd8\xbb\x99\x33\x89\x83\xd8\xbc\xf4\xbe\xa8\x5d\x09\xc4\xd2\xaa\xe5\x73\x98\xc0\x24\x24\xb4\x0b\x7d\x11\x29\x59\xb0\x53\xd4\x99\xfb\xb3\xe3\xb2\xac\x04\x1a\x50\x7d\x4e\x49\x87\x29\xaf\x30\x9b\x06\xac\x42\xfd\x1d\x7c\x43\x05\x3e\xaf\x71\xa3\xd9\x24\x74\x68\x66\x13\x6a\xf4\xa6\xac\x26\x7b\x33\xb3\x96\x63\x3a\x47\x05\xb6\x5a\x76\x4a\x3e\x45\xdd\xb0\x9e\xfd\xa3\xf9\x7c\x14\x6d\x83\x3a\x20\xe2\x88\x03\xda\x88\x15\xa7\xe9\xfb\x22\xb4\x5b\xec\x28\xcb\x88\xfe\x1e\xd8\xd9\x76\xe4\xad\x00\x32\x60\x48\x59\x14\xbb\x5c\x76\x98\x4a\x0a\x25\xe8\x0d\x48\xb7\xbb\x01\x79\xab\x0d\xbc\x24\xc0\xd5\x2f\xe3\xb1\xc4\x2f\xe7\x96\x36\xf0\xfc\x16\x49\x07\xbe\xc9\x36\x07\xf2\x5f\xf8\x47\xfc\x02\xfd\x03\xdc\x58\x44\xd1\x73\xf9\xbe\xbe\xad\x7f\x57\x44\xfa\x3e\x5a\xec\xf7\x77\xb3\xdb\xbc\xac\xe1\x67\x2e\xa6\xd6\x46\x8f\xc6\x63\x67\x9e\x52\xfe\xdd\x4e\xa0\xa7\x04\x42\x61\x3f\x52\x84\x94\xfd\xfe\x90\x39\x4f\xa7\x76\xc1\x33\x22\x76\xbc\x3d\x7b\xff\x01\x17\x5c\xab\xcc\x37\x7c\x35\x72\x5c\xd7\x67\xf3\xa9\x52\xdf\x43\xd9\x7a\x02\x46\xce\x92\xac\x37\x0a\xad\x57\xba\x2a\x75\x0c\xd4\xae\xb2\x18\xc7\x1a\xaa\x14\xb5\x62\x3f\x79\xe8\x7e\x4a\x34\x63\xc7\x2d\x69\x57\x0d\x59\xca\xd8\x90\x43\xd5\xd6\x55\x8b\x4b\x68\x70\xf3\x1e\x53\xd8\xcf\x3d\x98\xe4\x53\x11\x05\x81\xe3\xa6\xab\x11\x4f\x84\xc1\x43\x48\xfa\x07\x42\xfb\xc2\x0d\x8c\x43\xee\x5c\x90\xa6\x23\x42\x5d\x12\xff\x0f\xe7\x44\xc3\xd4\x2b\x87\x7b\xdd\x20\xca\xdf\xc2\x47\x21\x40\x07\x0f\x99\x24\xe4\xb9\x06\xf3\x8c\xbd\x59\x2a\xf4\xaa\xbf\x4a\x9e\x4c\x20\x59\x9d\xc4\x2d\xb4\xe8\xce\xf3\x6c\xc4\x1f\xd8\xb4\xe7\x77\xb9\x86\x23\xf3\xeb\x68\x17\x2f\xe1\x24\xa1\x61\x14\x5e\x37\xe1\x44\x02\xd1\x2a\xa9\x5e\xca\x84\x73\xa2\x3d\xca\x60\xc2\xf8\x60\x69\xdd\xc3\xfa\x9b\x1e\x18\x52\x0e\x68\x10\x1e\xaf\x50\xd2\xe9\x68\xac\xb8\x29\x70\x73\x79\xee\xed\xa9\x2a\x9d\x21\x16\x00\xb1\x35\x3b\xa7\x21\x76\x50\x6e\x21\x11\xb0\x23\xe3\xcb\x1e\x20\xfc\xdc\x27\xee\x6c\x01\x49\xaa\xac\xf8\x0e\x30\x10\x3a\x92\x9d\x3d\x61\x0f\x1b\x3b\xba\x16\x1d\x06\x94\xfb\x08\x81\x94\xc8\xe5\x63\xa0\x58\x92\x10\x66\x72\xd8\x22\xec\x07\x72\xfe\x4a\xc8\xf1\x13\xd3\x6d\x85\x6b\xa2\x64\x95\x24\x55\xba\xd5\xd2\xeb\x9c\x88\x2b\xc7\xad\x09\x87\xa6\xb8\x33\x13\x5c\x38\x68\xfd\x1c\xf6\x1a\x1c\xa0\x05\x2c\x92\x06\x7f\xdb\x14\xd3\x74\x22\x68\xaf\x3d\x26\xe5\x71\x19\x85\xc8\xea\x57\xf7\xaa\x85\xd2\x29\x67\xbc\x4a\x94\xf9\xdf\xa2\x1e\x8c\xec\x30\xdd\x4a\xf8\x51\xe5\x6f\x29\xd2\x74\x85\x1f\xd7\xf0\x3f\xaa\xeb\xef\xbd\xba\x0e\x64\xbf\x05\xa3\x11\x4e\x1e\xd2\x00\x77\x74\xb0\xbf\x92\x72\x15\x36\x64\x6b\xb4\x22\x4b\x0e\x73\x42\xe1\x3d\x29\x57\xaa\x9b\x3a\xde\x86\x15\x74\xd7\xdb\xf3\x6a\xf5\xe8\x85\x3f\x35\x10\x66\xd9\x7f\x7c\x9e\x3d\x26\xa3\x57\x18\x09\x5f\xda\xf3\xad\x14\xb3\x8e\xb4\x0c\xc3\x42\x11\xc4\xae\x55\xaf\x83\xd1\xce\xc9\x25\x16\xb2\xe5\x84\x0e\x27\x23\xc3\x05\x52\x3a\xfb\x08\xb3\x92\xb8\xb8\x0e\x4e\xd5\x2b\x89\xd4\x55\xfe\xfc\xbe\xf9\xc3\xb5\xc5\x07\x53\x8f\x9e\x61\x3c\xce\x81\x75\xb8\x00\x4e\xba\x83\x1a\x7f\xc6\x35\x54\xed\x5c\x9e\x55\x30\x7b\x5f\x93\xe2\xa3\x52\xb1\x0d\x60\xed\x9c\x40\x94\x7d\x88\xb1\xc3\x37\x15\x97\xe9\x55\xb6\x27\x25\xdc\x8f\xf7\xbd\x15\x51\xd2\x92\x5c\x05\xb0\x25\x37\x71\xd8\x93\x5d\x0c\xc1Line truncated
|
||||
|
||||
func templatesMarkdownDocsGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
_templatesMarkdownDocsGotmpl,
|
||||
"templates/markdown/docs.gotmpl",
|
||||
)
|
||||
}
|
||||
|
||||
func templatesMarkdownDocsGotmpl() (*asset, error) {
|
||||
bytes, err := templatesMarkdownDocsGotmplBytes()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/markdown/docs.gotmpl", size: 14106, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x5d, 0xa8, 0x4b, 0x6f, 0xe, 0x98, 0x3f, 0x90, 0x8e, 0xef, 0x51, 0x79, 0x4a, 0x94, 0xd5, 0xf5, 0x9f, 0x28, 0x15, 0xec, 0xd0, 0xbf, 0x42, 0x61, 0x58, 0x99, 0xee, 0xf2, 0xd7, 0x53, 0xec, 0xa0}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesModelGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xac\x90\xcd\x4e\x2b\x31\x0c\x85\xf7\x7d\x8a\xa3\x2e\x2b\xdd\x99\xfd\x5d\x22\x8a\xc4\x02\x36\xf0\x02\x56\xe2\x4e\x23\xe5\x67\x14\xa7\xa2\x60\xe5\xdd\x51\xda\xd2\x4e\x07\x54\xb1\x60\x97\xb1\xbf\xb1\xfd\x1d\x55\x14\x0e\xa3\xa7\xc2\x58\x6e\x99\x2c\xe7\x25\x3a\xd4\xba\x50\xfd\x07\xb7\x41\xf7\x18\x8d\xdf\x59\x7e\x4a\x96\x7d\xab\x03\xe7\x8e\xac\xf7\x63\xca\x85\x6d\xab\xf7\x3d\x54\x31\x92\x18\xf2\xee\x83\xd1\x3d\x53\x60\xd4\x8a\xab\x15\x36\x19\x29\xd9\xc5\xe1\xb4\x05\x38\xce\xbb\x10\x14\x63\x2a\x54\x5c\x8a\x72\x66\x1a\xc1\xd1\x5e\x3e\x2e\xb8\x98\x2d\x07\x9a\xdc\x7c\xe2\x16\xaa\xc8\x14\x07\x46\xb7\xde\x97\x4c\x2f\x07\x4e\x66\x06\xdf\xdc\xfe\xde\xee\x37\x7e\x33\xc3\x9b\x8e\x57\xec\xec\x69\x79\xe3\xe2\x7c\x47\xad\xaa\xfd\x0a\x93\x1a\x4a\xc2\xc0\x91\x73\x9b\x2e\x23\x1b\x6c\x72\x0a\x90\xb4\xcb\x86\xb1\xea\xa7\x19\xc5\x54\x5a\x16\x77\x24\xfc\xfa\x3e\xf2\x31\x8b\x16\x87\xbc\xd1\x30\x70\xfe\x1f\x0e\xe1\xa9\x9e\x23\xf9\xba\xd0\xcb\x0f\xb4\x75\x62\xb2\x0b\x2e\x52\x49\x79\xfa\xd7\xe1\x7d\x3f\xed\x3e\x38\xf6\xf6\x96\xf1\x67\x00\x00\x00\xff\xff\x75\xb1\xeb\x60\xbc\x02\x00\x00")
|
||||
|
||||
func templatesModelGotmplBytes() ([]byte, error) {
|
||||
@@ -327,7 +353,7 @@ func templatesModelGotmpl() (*asset, error) {
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesSchemaGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x58\x5f\x6f\xdb\x36\x10\x7f\xcf\xa7\xb8\x79\xd9\x20\x05\xa9\xbc\xf5\x69\xeb\x90\x87\xa4\x69\xd7\x0e\x58\x53\xd4\x5d\x0b\xac\x2b\x0a\x5a\x3c\x59\x6c\x29\x52\x25\xa9\xb4\x9e\xe0\xef\x3e\x50\xa4\x64\xca\xa6\x9c\x06\xd9\x80\x61\x58\x9e\x1c\xf1\x74\xbc\xfb\xdd\xdf\x9f\xda\xf6\x1e\xb0\x02\x88\xa0\x90\x3d\xd5\x17\x44\xe3\xcb\x75\x8d\xf6\xf7\xa3\xcf\xb5\x54\x06\x29\x24\x42\x1a\xfb\x60\xd1\xd4\xa8\xce\x39\x23\x3a\x85\xcd\xe6\x08\xc0\xbe\x6b\xb0\xaa\x39\x31\x08\x33\x9d\x97\x58\x91\xe7\x92\xaf\x2b\xa9\xea\x92\xe5\x33\xc8\xac\x9c\x95\x42\xae\xd1\x5e\x33\xd2\xe2\x94\x18\x7b\x5d\xdb\x42\x4d\x74\x4e\x38\xfb\x13\x21\x7b\x46\x2a\x84\xcd\xc6\x3e\xdd\xaa\xb7\x72\x8b\xee\x0a\x6b\xa0\xd3\xdd\xb6\xf3\x13\x78\x2c\x55\xa7\x44\x03\xc5\x9c\x13\x85\x14\x88\x86\x63\x85\x05\x48\x01\x5a\x56\x08\xd2\x94\xe8\x84\x4e\xe1\x7d\xa3\x4d\x2f\x09\xa6\x44\x67\x00\xd1\x40\x60\x25\x39\x11\x2b\x78\x47\xac\x75\x48\xdf\xf9\x37\x30\x5b\x65\x4e\xea\x1c\xce\xe0\x22\x83\x67\x12\x2a\x34\xa5\xa4\xa0\x4b\xc2\x39\x2c\x11\x14\xf6\x97\x67\x00\x27\xf3\x01\x1e\xe7\xf3\x00\x6b\xf7\x1c\xc6\x8e\x2d\xfd\xe1\x02\x15\xeb\x00\x50\x81\x73\xaf\x4b\x14\x9d\x95\x9d\x4d\xdb\x6b\xac\xb9\xf5\x16\x6a\x6f\x29\xc5\x82\x09\x84\x82\xe4\x46\xaa\xb5\x37\x52\xc3\x27\x66\x4a\x30\x25\xd3\x4e\x4b\x16\x1a\x88\x82\x46\x82\xf4\xa8\x5a\x22\xa5\x48\xa7\xe3\xdc\x4b\xec\x06\x39\xf4\x5c\x2a\xab\xeb\xa1\xac\x6a\x8e\x9f\xaf\x96\xef\x31\xef\xf2\xe8\x65\x53\xf3\x2e\xc3\xce\x29\x65\x86\x49\x41\xf8\x73\x25\x6b\x54\x86\xa1\xee\x1d\x7f\x79\x75\x79\x95\x14\x0a\x69\xfa\x00\x4a\x22\x28\x47\xc8\x89\x46\x90\x05\xe8\x66\xd9\x45\x83\x89\x12\x15\x33\x4c\xac\xa0\x50\xb2\x02\x0b\xa4\x8b\x53\xe7\x70\x4c\xfb\x29\x30\xad\x1b\x84\xaf\xef\xdf\xbf\xff\x5d\x0f\x83\x8f\x88\xf5\xdc\x67\x5e\x9f\x93\xac\x00\x9f\xfb\x43\x31\x58\xf3\x06\xb9\xb6\xed\x9d\x8e\x26\xb0\x3d\x16\x34\xfc\x31\x8e\xbc\x43\xf2\x42\xd2\xb5\x47\xd1\x59\x72\x0f\x14\x11\x2b\x84\x6c\x84\xca\x60\xe8\x54\x52\xd9\xbf\xf9\x3c\x52\x4a\x9b\x0d\xac\xd0\xe8\x2e\x8d\xda\x16\xca\xa6\x22\x62\x54\x67\xb2\x70\xd9\x31\x00\xd8\x45\xc0\x66\x76\xbd\xb5\xe0\x53\xc9\xf2\x12\x6c\xd1\xc8\x02\x48\x00\xb6\x95\x21\x2b\xeb\x10\x33\x1a\x98\x30\xa8\x0a\x92\x63\x88\x2e\x40\xd1\x88\x1c\x92\xb6\x85\xe3\xec\x05\xe6\xc8\xae\x51\x79\xd3\x4e\x46\x06\x1f\x7b\x8b\xd3\xa8\x1f\x49\x1a\x03\x30\xe8\x07\xc3\x7d\x03\x50\xf8\x11\x8e\xb3\x4b\xa6\x73\xc5\x2a\x26\x88\x91\xea\x31\x43\x4e\x07\xe7\x83\x37\x00\x14\x9a\x46\x89\xee\x6a\xc5\x84\x29\x60\xf6\xcd\xc7\xd9\xee\xfb\xaf\x08\x6f\x76\xde\x1c\x67\x7f\x4c\xdf\xd8\x6d\xd8\x6c\xb2\xb6\xcd\x49\x85\xa1\x77\x9d\x61\xbb\x5a\x05\x0d\x95\x6e\x8e\xc2\x50\x2f\xd0\x44\xa3\xad\x6f\x17\xed\x3b\x04\x69\xc2\x82\xe4\x9a\xf0\xc3\x91\x4a\x21\x12\x2b\x81\xb7\x88\xd5\x6d\x40\x85\x33\xb8\x26\xfc\x26\x68\xa3\x47\x91\x7f\x6d\xf9\x5d\x62\x41\x1a\x6e\xf6\xbb\x15\xdc\x1b\x5a\xcc\xf7\x3f\xfc\x18\x16\x41\x8f\xee\x61\x6c\x7b\x5f\x53\xf8\x4d\x54\x44\xd9\x01\xf3\xcb\xe2\xea\x59\xb2\x84\x37\x6f\x97\x6b\x83\x29\xa0\x52\x52\x05\xf0\x4d\x0f\x50\x37\x65\xa3\x47\xc3\xdb\xd7\x44\x81\x39\xf0\xfa\x20\x68\x6b\x49\x29\x78\x70\x06\xef\xb5\x14\xd9\x60\x5d\xe2\xec\x4a\xda\x36\xac\x99\xc4\x0a\x0d\x30\xa5\x9b\x4d\x7a\x0a\xdf\x9a\xf4\xa7\x4e\xc7\x57\x67\x20\x18\x1f\x65\x80\xaf\x14\x54\x6a\x2f\x20\x07\xae\x5e\xde\x41\xe9\xc9\x7e\x24\xce\xe2\x38\x24\x26\x3d\xda\x51\x29\x58\x9f\x4d\x91\x2c\xd9\xed\x06\x77\xd9\x70\x8e\x22\xba\x59\x01\x89\xdf\xd7\x9e\xdb\x4a\x31\xec\xda\x8d\x53\xb7\xb6\x74\x33\xb7\xd1\x46\x56\x8f\xa5\xaa\x88\x31\xa8\xdc\x0a\x97\x68\xa3\x98\x58\x3d\x94\xc2\x10\x26\x34\x64\xbf\xa3\x92\x30\x4b\xfe\x98\xcd\xd2\x34\x8d\xee\x26\x7e\x13\xda\x5d\x4d\x26\xac\xea\xb6\xbb\xe5\xce\xa2\xe3\x67\xd9\x39\xe7\x57\x45\x38\xc6\x0e\x0d\xb9\xa9\x31\xf7\x37\xcd\x39\xbf\x40\xec\xf5\xbd\xff\x67\xd3\xbf\x65\x36\xdd\x39\x42\xff\xc1\xc1\x14\x39\xdc\x3e\x98\xda\x99\xa3\x2b\x36\x13\xc1\xfa\x36\x4c\xa8\xbd\x49\x17\xa0\x54\x91\xfa\x4a\x2d\x38\xcb\xf1\x67\xb4\x0d\x65\xaa\x0d\xec\x01\xbb\xd7\x39\x76\x38\xc7\x40\x3d\x45\xce\x1b\x8a\xaf\x08\x67\xd4\xe2\x1b\x25\x9d\xfd\xb3\x9e\x7b\xa4\xbd\xe3\xbe\x4d\x79\x1a\xb8\xa5\x6a\x40\x65\xb7\xc0\x5b\xda\xd4\x31\xa3\x9e\x11\x8d\x19\x9a\xb5\xc0\x75\x48\xc7\x58\x9e\x0e\x3b\xac\x35\xc0\x28\x24\x55\x9a\xba\xc3\x17\xf8\xb1\x61\x96\x62\x66\x4f\x88\xf6\xd6\x32\x69\x9b\xe9\x13\x32\xb4\xaa\x78\x2f\x75\x80\x5c\xf7\x1e\x8e\x21\xf4\xd4\xeb\x06\x23\xec\x0b\xf3\x39\xf8\x7b\x11\xbc\x32\xeb\xb3\xad\x9a\x58\x49\x75\xf8\xb8\x9a\xea\xee\x07\x66\xd9\x58\x85\xc2\x97\xa1\x6a\x84\x61\x15\x66\x5e\x27\x59\x72\x0c\x76\xf8\x65\x63\xa0\x24\x1a\x84\xec\xef\xea\x9c\x35\x12\xf2\x12\xf3\x0f\x0e\xc7\xa9\xc5\xc6\x11\x28\xe7\xcd\xc0\xf9\xf6\xd8\xe0\x04\x09\x3c\x09\xc9\x93\x53\x93\xec\x70\xb1\x14\xc2\x9a\xf4\xd4\x11\xc6\x75\x76\x0b\x92\x96\x0e\xb8\x26\x45\x37\x38\x35\x68\xa3\x8a\xca\x64\x2f\x70\xc5\xb4\x51\xeb\x70\xf7\x0a\x16\x81\x9d\x99\xdf\x21\x1e\x90\x44\xa0\x12\x75\x17\xd9\x01\xfa\x9b\x91\x7f\x00\x42\xca\x7a\x8a\xa8\x8f\xea\x27\x7b\x4d\x84\xd1\xbf\xba\x95\xe8\x82\x09\xa2\xd6\x91\x72\xac\xc2\xf3\x9b\xaa\xd2\x57\x4b\xa4\xec\xbd\x7b\x9a\xLine truncated
|
||||
var _templatesSchemaGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x58\xdd\x6e\xdc\xb6\x12\xbe\xf7\x53\xcc\xf1\xf1\x39\x90\x0c\x47\xdb\xe6\xaa\x4d\xe1\x0b\x3b\x4e\xea\x14\x68\x1c\xc4\x69\x02\x34\x0d\x02\xae\x38\x5a\x31\xa1\x48\x85\xa4\x1c\x6f\x85\x7d\xf7\x82\x22\xa5\xa5\xb4\xdc\xb5\x5d\xa7\x40\xd0\xd6\x57\x6b\x91\x1c\xce\x7c\xf3\xfb\xb1\x6d\x1f\x00\x2b\x80\x08\x0a\xd9\x33\x7d\x4a\x34\xbe\x5a\xd6\x68\x7f\x3f\xb9\xae\xa5\x32\x48\x21\x11\xd2\xd8\x0f\x97\x4d\x8d\xea\x84\x33\xa2\x53\x58\xad\xf6\x00\xec\x59\x83\x55\xcd\x89\x41\xd8\xd7\x79\x89\x15\x79\x21\xf9\xb2\x92\xaa\x2e\x59\xbe\x0f\x99\xdd\x67\x77\x21\xd7\x68\xaf\x19\x49\x71\x42\x8c\xbd\xae\x6d\xa1\x26\x3a\x27\x9c\xfd\x8e\x90\x3d\x27\x15\xc2\x6a\x65\xbf\xae\xc5\xdb\x7d\x97\xdd\x15\x56\x41\x27\xbb\x6d\x67\x87\xf0\x54\xaa\x4e\x88\x06\x8a\x39\x27\x0a\x29\x10\x0d\x07\x0a\x0b\x90\x02\xb4\xac\x10\xa4\x29\xd1\x6d\x3a\x82\x0f\x8d\x36\xfd\x4e\x30\x25\x3a\x05\x88\x06\x02\x0b\xc9\x89\x58\xc0\x7b\x62\xb5\x43\xfa\xde\x9f\xc0\x6c\x91\xb9\x5d\x27\x70\x0c\xa7\x19\x3c\x97\x50\xa1\x29\x25\x05\x5d\x12\xce\x61\x8e\xa0\xb0\xbf\x3c\x03\x38\x9c\x0d\xf0\x38\x9b\x07\x58\xbb\xef\x30\x36\x6c\xee\x17\x2f\x51\xb1\x0e\x00\x15\x18\xf7\xa6\x44\xd1\x69\xd9\xe9\xb4\xbe\xc6\xaa\x5b\xaf\xa1\xf6\x9a\x52\x2c\x98\x40\x28\x48\x6e\xa4\x5a\x7a\x25\x35\x7c\x66\xa6\x04\x53\x32\xed\xa4\x64\xa1\x82\x28\x68\xc4\x49\x4f\xaa\x39\x52\x8a\x74\xbb\x9f\xfb\x1d\x53\x27\x87\x96\x4b\x65\x65\x3d\x96\x55\xcd\xf1\xfa\x62\xfe\x01\xf3\x2e\x8e\x5e\x35\x35\xef\x22\xec\x84\x52\x66\x98\x14\x84\xbf\x50\xb2\x46\x65\x18\xea\xde\xf0\x57\x17\x67\x17\x49\xa1\x90\xa6\x8f\xa0\x24\x82\x72\x84\x9c\x68\x04\x59\x80\x6e\xe6\x9d\x37\x98\x28\x51\x31\xc3\xc4\x02\x0a\x25\x2b\xb0\x40\x3a\x3f\x75\x06\xc7\xa4\x1f\x01\xd3\xba\x41\xf8\xef\xc3\x87\x0f\xbf\xe9\x61\xf0\x1e\xb1\x96\xfb\xc8\xeb\x63\x92\x15\xe0\x63\x7f\x48\x06\xab\xde\xb0\xaf\x6d\x7b\xa3\xa3\x01\x6c\x97\x05\x0d\x7f\x8c\x3d\xef\x90\x3c\x95\x74\xe9\x51\x74\x9a\x3c\x00\x45\xc4\x02\x21\x1b\xa1\x32\x28\xba\x2d\xa8\xec\xdf\x6c\x16\x49\xa5\xd5\x0a\x16\x68\x74\x17\x46\x6d\x0b\x65\x53\x11\x31\xca\x33\x59\xb8\xe8\x18\x00\xec\x3c\x60\x23\xbb\x5e\x6b\xf0\xb9\x64\x79\x09\x36\x69\x64\x01\x24\x00\xdb\xee\x21\x0b\x6b\x10\x33\x1a\x98\x30\xa8\x0a\x92\x63\x88\x2e\x40\xd1\x88\x1c\x92\xb6\x85\x83\xec\x25\xe6\xc8\xae\x50\x79\xd5\x0e\x47\x0a\x1f\x78\x8d\xd3\xa8\x1d\x49\x1a\x03\x30\xa8\x07\xc3\x7d\x03\x50\xf8\x09\x0e\xb2\x33\xa6\x73\xc5\x2a\x26\x88\x91\xea\x29\x43\x4e\x07\xe3\x83\x13\x00\x0a\x4d\xa3\x44\x77\xb5\x62\xc2\x14\xb0\xff\xbf\x4f\xfb\xd3\xf3\xaf\x09\x6f\x26\x27\xc7\xd1\x1f\x93\x37\x36\x1b\x56\xab\xac\x6d\x73\x52\x61\x68\x5d\xa7\xd8\x54\xaa\xa0\xa1\xd0\xd5\x5e\xe8\xea\x4b\x34\x51\x6f\xeb\xbb\x79\xfb\x1e\x4e\xda\xa2\x41\x72\x45\xf8\x6e\x4f\xa5\x10\xf1\x95\xc0\x3b\xf8\xea\x2e\xa0\xc2\x31\x5c\x11\x7e\x13\xb4\xd1\xa5\xc8\xbf\x36\xfd\xce\xb0\x20\x0d\x37\x9b\xd5\x0a\x1e\x0c\x25\xe6\xdb\xef\xbe\x0f\x93\xa0\x47\x77\x37\xb6\xbd\xad\x29\xfc\x22\x2a\xa2\x6c\x83\xf9\xe9\xf2\xe2\x79\x32\x87\xb7\xef\xe6\x4b\x83\x29\xa0\x52\x52\x05\xf0\x6d\x6f\xa0\xae\xcb\x46\x97\x86\xd3\x57\x44\x81\xd9\x71\x7c\xd8\x68\x73\x49\x29\x78\x74\x0c\x1f\xb4\x14\xd9\xa0\x5d\xe2\xf4\x4a\xda\x36\xcc\x99\xc4\x6e\x1a\x60\x4a\x57\xab\xf4\x08\xfe\x6f\xd2\x1f\x3a\x19\xff\x39\x06\xc1\xf8\x28\x02\x7c\xa6\xa0\x52\x1b\x0e\xd9\x71\xf5\xfc\x1e\x42\x0f\x37\x3d\x71\x1c\xc7\x21\x31\xe9\xde\x44\xa4\x60\x7d\x34\x45\xa2\x64\x5a\x0d\xee\x33\xe1\xec\x45\x64\xb3\x02\x12\x3f\xaf\xbd\xb0\x99\x62\xd8\x95\x6b\xa7\x6e\x6c\xe9\x7a\x6e\xa3\x8d\xac\x9e\x4a\x55\x11\x63\x50\xb9\x11\x2e\xd1\x46\x31\xb1\x78\x2c\x85\x21\x4c\x68\xc8\x7e\x45\x25\x61\x3f\xf9\x6d\x7f\x3f\x4d\xd3\xe8\x6c\xe2\x27\xa1\xe9\x68\xb2\x45\xab\x6e\xba\x9b\x4f\x06\x1d\xdf\xcb\x4e\x38\xbf\x28\xc2\x36\xb6\xab\xc9\x6d\x6b\x73\x5f\xa8\xcf\xf9\x01\x62\xa3\xee\xfd\xdb\x9b\xbe\x96\xde\x74\x6f\x0f\xfd\x0d\x1b\x53\x64\x71\xfd\x61\xdb\xcc\x1c\x1d\xb1\x99\x08\xc6\xb7\xa1\x43\x6d\x74\xba\x00\xa5\x8a\xd4\x17\xea\x92\xb3\x1c\x7f\x44\x5b\x50\xb6\x95\x81\x0d\x60\x37\x2a\xc7\x84\x73\x0c\xd4\x53\xe4\xbc\xa1\xf8\x9a\x70\x46\x2d\xbe\x51\xd2\xd9\x7f\xeb\xb9\x47\xda\x1b\xee\xcb\x94\xa7\x81\x6b\xaa\x06\x54\x76\x03\xbc\xa5\x4d\x1d\x33\xea\x19\xd1\x98\xa1\x59\x0d\x5c\x85\x74\x8c\xe5\xd9\x30\xc3\x5a\x05\x8c\x42\x52\xa5\xa9\x5b\x7c\x89\x9f\x1a\x66\x29\x66\x76\x4e\xb4\xd7\x96\x49\x5b\x4c\xcf\xc9\x50\xaa\xe2\xb5\xd4\x01\x72\xd5\x5b\x38\x86\xd0\x53\xaf\x1b\x94\xb0\x07\x66\x33\xf0\xf7\x22\x78\x61\xd6\x66\x9b\x35\xb1\x94\xea\xf0\x71\x39\xd5\xdd\x0f\xcc\xb2\xb1\x0a\x85\x4f\x43\xd5\x08\xc3\x2a\xcc\xbc\x4c\x32\xe7\x18\xcc\xf0\xf3\xc6\x40\x49\x34\x08\xd9\xdf\xd5\x19\x6b\x24\xe4\x25\xe6\x1f\x1d\x8e\xdb\x06\x1b\x47\xa0\x9c\x35\x03\xe7\xdb\x60\x83\x5b\x48\xe0\x61\x48\x9e\x9c\x98\x64\xc2\xc5\x52\x08\x73\xd2\x53\x47\x18\xe7\xd9\x1d\x48\x5a\x3a\xe0\x9a\x14\x5d\xe3\xd4\xa0\x8d\x2a\x2a\x93\xbd\xc4\x05\xd3\x46\x2d\xc3\xd9\x2b\x18\x04\x26\x3d\xbf\x43\x3c\x20\x89\x40\x25\xea\xce\xb3\x03\xf4\x37\x23\xff\x08\x84\x94\x75\x84\xa8\xff\x99\xa0\x3d\x27\xda\x36\x7d\xbc\x36\x41\xc4\xee\x0a\xd2\xdc\xed\xfe\x12\xb1\x3a\xbe\xf8\x56\x21\xdb\x15\xLine truncated
|
||||
|
||||
func templatesSchemaGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -342,8 +368,8 @@ func templatesSchemaGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/schema.gotmpl", size: 5504, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x4d, 0x80, 0x58, 0x1d, 0x87, 0xd8, 0xdb, 0xff, 0xc9, 0x33, 0x69, 0x35, 0x93, 0x22, 0x2, 0xe3, 0x44, 0xb, 0x31, 0x1a, 0xe7, 0x60, 0xc2, 0xe8, 0x97, 0xe8, 0xff, 0x64, 0x99, 0xaf, 0xb2, 0xc5}}
|
||||
info := bindataFileInfo{name: "templates/schema.gotmpl", size: 6259, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x3a, 0xd6, 0xc6, 0x56, 0x8c, 0xce, 0x4f, 0x11, 0x45, 0xba, 0xcb, 0xb6, 0xc2, 0x28, 0xd4, 0x31, 0x52, 0x91, 0xbd, 0x36, 0xa7, 0xe5, 0xc4, 0x21, 0x15, 0xa1, 0xaa, 0x46, 0x3a, 0x8, 0x9f, 0x4f}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
@@ -367,7 +393,7 @@ func templatesSchemabodyGotmpl() (*asset, error) {
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesSchemaembeddedGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x6c\x91\xcd\x8e\x1a\x31\x10\x84\xef\x7e\x8a\x12\x27\x26\x4a\xfc\x00\x89\x38\x25\x28\xe2\x42\x22\x84\x72\x37\x9e\x36\xf1\xe2\x9f\x51\xdb\x33\x82\xb5\xfc\xee\x2b\xc3\x20\xb1\xec\x9e\x6c\xb5\x3f\x77\x55\x75\x97\x82\x9e\x8c\x0d\x84\x45\xd2\xff\xc9\xab\xb5\x3f\x50\xdf\x53\xbf\x40\xad\x22\x5f\x06\x42\x29\x18\x54\xd2\xca\xd9\x57\x82\xdc\x2a\x4f\xa8\x15\x29\xf3\xa8\x33\x8a\x40\x03\xac\x81\x5c\x3b\xf2\xfb\xcb\x40\x72\x93\xb6\xa3\x73\xea\xe0\x1a\xf8\xa5\x14\x50\xe8\x51\x6b\x29\x0f\xcc\xef\xd8\x8e\xa6\x51\x85\x30\x63\xd0\x58\x96\x22\x77\xa4\xc9\x4e\xc4\x77\x91\x5b\xe7\xc8\x90\x9b\xb4\x1f\x07\x47\xed\xf2\x33\xfa\xc1\xd1\xf9\xcf\xe1\x85\x74\x7e\x56\x68\x46\x7e\xd9\xa4\xd9\x7a\x1b\x54\xa6\x74\x2b\x6b\xe5\xe9\x9d\xff\xf6\xc7\x25\xba\xf2\x9b\xb4\x3e\x0f\x91\x33\xcd\x3d\x3e\xa6\xbd\xd3\xb7\x10\x0f\xc5\xab\x6c\x87\x7f\xca\xd9\x5e\x65\x5a\x9a\xc8\x5e\xe5\xd4\xa6\x63\x7c\x96\x3b\x3a\xda\x94\xf9\xd2\x81\x98\x23\x5f\xa7\x35\x29\x86\x81\x0d\x99\xd8\x28\x4d\xa5\x62\xd5\x72\x3e\x67\x97\x6d\x33\x1c\x87\xbf\x4a\x9f\xd4\x91\x3e\x1d\x1d\x9a\xfd\xe9\x2b\xe2\x09\xdf\x57\x30\x72\xc9\x63\xc8\xd6\x93\x9c\xfd\xb4\x15\x74\xf8\xd1\xde\x9b\x32\xc0\x94\x47\x0e\x98\xe4\xb3\xe1\x4e\x00\xad\xdf\x0c\x04\xeb\x44\x15\xa5\x7c\x9b\x13\x8a\xb7\x00\x00\x00\xff\xff\x18\x59\xcb\x94\x27\x02\x00\x00")
|
||||
var _templatesSchemaembeddedGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xdc\x51\x4b\x6e\xdb\x30\x10\xdd\xeb\x14\x0f\x59\xd9\x45\xca\x03\xb4\xc8\x2a\x35\x0a\x6f\xd2\x22\x08\xba\xa7\xa9\x61\xca\x86\x1f\x61\x38\x12\xe4\x12\xbc\x7b\x41\x4b\x09\x12\xd7\xdd\x17\x59\x49\x98\x79\x9c\xf7\x2b\x05\x3d\x59\x17\x09\x57\xd9\xfc\xa4\xa0\x77\xe1\x40\x7d\x4f\xfd\x15\x6a\xed\xe4\x38\x10\x4a\xc1\xa0\xb3\xd1\xde\xfd\x26\xa8\x3b\x1d\x08\xb5\x22\x0b\x8f\x46\x50\x3a\x34\x80\xb3\x50\x3b\x4f\xe1\xe1\x38\x90\xda\xe7\xbb\xd1\x7b\x7d\xf0\x0d\xf8\xa1\x14\x50\xec\x51\x6b\x29\xaf\x30\x5f\x53\xfb\x34\x8e\xda\x75\x76\x8c\x06\x9b\x52\xd4\x3d\x19\x72\x13\xf1\x33\xc9\x72\x39\x31\xd4\x3e\x3f\x8c\x83\xa7\xf6\x73\x9b\xc2\xe0\x69\xfe\x76\xf8\x45\x46\xce\x19\x9a\x90\x2f\x2e\x1b\x76\xc1\x45\x2d\x94\x97\xb1\xd1\x81\xde\xe8\x6f\x6f\x7c\xa6\x13\x7e\x9f\x77\xf3\x90\x58\x68\xbd\xf1\xb7\xdb\x67\xf4\x62\xe2\xd5\xf0\x44\xbb\xc5\x0f\xed\x5d\xaf\x85\x36\x36\x71\xd0\x92\x5b\x3a\x36\x88\xba\xa7\x47\x97\x85\x8f\x5b\x10\x73\xe2\x53\x5a\x93\x66\x58\xb8\x28\xc4\x56\x1b\x2a\x15\x37\xcd\xe7\xb9\x77\xd5\x9a\xe1\x34\x7c\xd7\xe6\x49\x3f\xd2\xc5\xe8\xd0\xe4\x4f\xd7\x48\x4f\xf8\x74\x03\xab\x36\x3c\x46\x71\x81\xd4\xaa\xa7\x55\xb0\xc5\xe7\xb6\x6f\xcc\x00\x93\x8c\x1c\x31\xa9\x73\xc1\xdb\x0e\x68\xf7\x56\x40\x74\xfe\x5d\xf4\x72\x9b\xa2\xd0\x2c\x2f\x6e\x8d\xcc\x30\xcb\x4c\xad\xbb\x6b\xfc\x27\x9d\xbd\xd5\xfa\xef\xea\x2e\x78\x7a\xf1\x70\xb1\xc6\x52\x3e\xae\x81\x74\x7f\x02\x00\x00\xff\xff\xc7\x64\x36\xad\xee\x03\x00\x00")
|
||||
|
||||
func templatesSchemaembeddedGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -382,12 +408,12 @@ func templatesSchemaembeddedGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/schemaembedded.gotmpl", size: 551, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x20, 0x86, 0x25, 0x7d, 0x64, 0xed, 0xf7, 0x80, 0x5c, 0x4d, 0x25, 0xbc, 0xfd, 0xcd, 0xbe, 0x94, 0x37, 0xa5, 0x11, 0xa9, 0xb7, 0x27, 0xff, 0xa4, 0x49, 0xe, 0xd9, 0x21, 0xff, 0xf7, 0x51, 0x4d}}
|
||||
info := bindataFileInfo{name: "templates/schemaembedded.gotmpl", size: 1006, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xe4, 0xa4, 0x81, 0x1e, 0x5f, 0xcc, 0xb5, 0xc5, 0x89, 0x34, 0xe8, 0x25, 0xa0, 0x6e, 0x11, 0xd1, 0x44, 0x15, 0xb9, 0x8a, 0x52, 0x89, 0x1d, 0xad, 0xc2, 0x2b, 0x2, 0x7d, 0xf7, 0x9a, 0x12, 0x2d}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesSchemapolymorphicGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xbc\x95\x4f\x8f\xdb\x36\x10\xc5\xef\xfe\x14\x0f\xee\x16\xb5\x8c\xad\x0c\xa4\xb7\x00\x3d\xb8\x08\x1a\xf8\x52\x07\xf5\x36\xf7\x89\x34\x5a\xb1\xe5\x1f\x85\xa4\x9c\xba\x84\xbe\x7b\x21\x4a\x96\x68\x57\xdb\x4d\x2f\xd5\x91\x1c\xce\x3c\xfe\xde\x0c\x15\x02\x4a\xae\x84\x66\xac\x5d\x51\xb3\xa2\x0f\x46\x5e\x94\xb1\x4d\x2d\x8a\x35\xba\x6e\x05\xf8\x4b\xc3\x08\x01\x0d\xb9\x82\xa4\xf8\x8b\x91\xff\x42\x8a\xd1\x75\x10\xda\xb3\xad\xa8\x60\x84\x15\x10\xc2\xf7\x10\x15\xb4\xf1\xd8\x18\x8b\xfc\xe0\x0e\xd3\x7e\x7e\x70\x27\x6f\x99\x54\x86\xae\x0b\x61\xb7\x5d\x61\xfc\xf6\xf8\x44\x8e\x87\x2a\xc2\x81\xe4\x17\xba\x38\x7c\x24\x29\x4a\xf2\xf4\x49\x72\x3e\x85\xfe\xa6\x4b\xb6\xd0\xc6\x2a\x92\x28\x8c\x2e\x85\x17\x46\xbb\x47\x7c\x61\x14\xa4\xbf\xf3\xa8\xe9\xcc\xa0\x24\xa3\xe5\xfe\x0c\x97\xa0\x59\x02\xee\xc4\xbd\x85\xaf\x85\x43\x51\x73\xf1\x47\x2f\xe1\xf7\xd6\x79\x54\xc6\xc2\x91\x16\xfe\x32\x6c\x64\xf9\x6a\xd2\x71\xd0\xf0\x35\x0f\xe0\xa2\x04\x98\x2a\xae\x24\x37\xf1\x8e\x65\xf5\x38\x64\x56\x4c\xda\xc1\xd7\xe4\x63\x54\xab\xf9\xcf\xc6\x58\xcf\x25\x9c\xb7\x6d\xe1\x51\x1b\x59\x0a\xfd\x3c\x15\x78\x2d\x7b\x4d\x0e\x74\x65\xc4\x9b\x0c\x55\xab\x8b\x81\xd3\x76\x17\x4d\x1b\x3e\xdb\x6a\x2f\x14\xe7\x09\xcd\xd1\x27\xd6\xe5\xe0\x6e\x08\xb0\xa4\x9f\x19\xf9\x5e\xca\x63\x85\xf1\xf4\xe8\x65\x7e\x70\x7b\x6d\xf4\x45\x99\xd6\x61\x4a\x3c\x9f\xf9\x60\x4d\xc3\xd6\x0b\x4e\x76\xe3\xbe\xa8\xf0\x90\x1f\xdc\x53\xdb\x48\x8e\x8e\xc3\xb3\x6a\x24\x79\xc6\xda\xf7\x8b\x95\x60\x59\x1e\x7a\xfc\x6b\xe4\x43\x04\x4b\x37\xc4\xce\xa1\x03\x9f\xa5\xd8\xab\xfe\xab\xd8\xbb\x85\xa4\x9c\xa2\xe6\x68\x4f\x52\x14\xfc\x9e\xbd\x67\x3b\xe4\x98\x6e\x39\x56\x9d\x4f\xe6\xef\xcd\x53\x0f\x39\x8d\x99\x69\x2d\xa2\xfb\x27\x86\x91\x5f\xca\x60\x49\xdb\x22\x8a\x97\xa5\xbd\x06\xe6\x75\xc1\x5f\x81\xa5\x5b\x25\x43\x5f\x90\xe2\xdb\x99\xbf\x95\x11\xdf\x8c\x9f\x4c\x79\xb9\x3a\xb3\xdb\xa6\xfd\x2d\x54\x23\x59\xb1\xf6\x94\x36\xf2\xfc\x6c\x6c\x9e\x8e\xef\x8e\x9b\xca\x72\x99\xbd\x05\x79\x35\x0e\x8c\x70\xf1\x15\x69\x1d\x97\x8f\x10\xce\xb5\x8c\x6f\xde\xfc\xf0\x26\xbb\x76\x77\x7f\xab\x45\xf4\x11\xc0\x6e\xb7\xf0\x5c\x75\x1d\x9e\xd9\xbb\x58\x3f\x04\xd4\xad\x22\x7d\x73\xaf\xa8\x4d\x38\x34\xf3\x03\x18\x29\xc4\x94\xfd\x7c\x61\x13\x02\x1e\xf2\x5f\xb9\x60\x71\x66\x3b\x26\xdd\xa6\x90\x1e\xc6\x52\xd9\xa2\x80\x4d\xb6\x04\xaf\xef\xb5\x11\x5e\xd2\xce\xa2\x02\x7f\xc6\x43\xfe\x4e\xb8\xc2\x0a\x25\x34\x79\x63\x7f\xee\xed\x9e\x14\xcf\x53\xce\xbe\xb5\x3a\x96\xb4\x42\xfb\x0a\xeb\x6f\x3f\xaf\xef\xcf\x7e\x24\xd9\xf2\xdd\xc8\xdc\xb4\x57\x9a\xe7\xf6\x96\xe8\xba\x3c\x84\xdb\x4e\xe8\xba\x28\x66\x79\x00\x67\x1f\x4e\xec\x17\xad\x70\xff\xa3\x15\x2f\x68\xd8\x9c\x49\xfe\xbb\x1f\x19\xee\x1c\xd1\xfc\x95\x8e\xfc\x17\x84\xf8\x11\x67\x92\x2f\x81\x4c\x97\xe2\x70\xa5\x03\xb3\x2f\x87\x3f\x20\xc9\x64\x0a\xa6\x11\x49\x6e\x96\x80\x3c\xb1\x15\x91\xc3\x75\xe0\x93\x92\x7f\x07\x00\x00\xff\xff\x5c\xdd\xd1\x0d\x0d\x08\x00\x00")
|
||||
var _templatesSchemapolymorphicGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xbc\x55\x4d\x6f\xdb\x46\x10\xbd\xeb\x57\x3c\xa8\x2e\x2a\x19\x2e\x05\xa4\xb7\x00\x3d\xb8\x0d\x1a\xe8\x52\x07\xb5\x9b\xfb\x84\x1c\x9a\xdb\xee\x07\xb3\x3b\x74\xa2\x2e\xf8\xdf\x0b\x2e\x29\x71\xa5\xd0\x75\x7a\x89\x8e\x9c\xd9\x99\x37\xef\xcd\x1b\xc5\x88\x8a\x6b\x65\x19\xeb\x50\x36\x6c\xe8\x9d\xd3\x07\xe3\x7c\xdb\xa8\x72\x8d\xbe\x5f\x01\x72\x68\x19\x31\xa2\xa5\x50\x92\x56\xff\x30\x8a\xdf\xc9\x30\xfa\x1e\xca\x0a\xfb\x9a\x4a\x46\x5c\x01\x31\xfe\x08\x55\xc3\x3a\xc1\xc6\x79\x14\xfb\xb0\x3f\xc5\x8b\x7d\xb8\x17\xcf\x64\xb6\xe8\xfb\x18\x77\xd7\x2b\x4c\xbf\x5b\x7c\xa0\xc0\x63\x17\x15\x40\xfa\x13\x1d\x02\xde\x93\x56\x15\x09\x7d\xd0\x5c\x9c\x52\xff\xb4\x15\x7b\x58\xe7\x0d\x69\x94\xce\x56\x4a\x94\xb3\xe1\x06\x9f\x18\x25\xd9\x1f\x04\x0d\x3d\x31\x28\xab\xe8\x79\x78\xc3\x15\x68\x86\x80\x0b\x70\xaf\x21\x8d\x0a\x28\x1b\x2e\xff\x1e\x20\xfc\xd5\x05\x41\xed\x3c\x02\x59\x25\x87\x31\xb0\x2d\x56\x27\x1c\x7b\x0b\x69\x78\x24\x2e\x41\x80\xab\xd3\x97\x6c\x12\x09\xac\xeb\x9b\xb1\xb2\x61\xb2\x01\xd2\x90\xa4\xac\xce\xf2\xe7\xd6\x79\xe1\x0a\x41\x7c\x57\x0a\x1a\xa7\x2b\x65\x1f\x4f\x0d\x5e\xaa\xde\x50\x00\x1d\x39\xe2\xcd\x16\x75\x67\x4b\x90\x1d\xc6\xfc\xd5\x59\xe1\xcf\x32\x04\x65\x0e\x8e\x24\x5e\xef\x92\xa2\xe3\xcf\x77\x56\x94\xe1\x22\xa3\xfa\x8b\x58\x56\x6c\x4e\x19\x74\x66\x5b\x8d\xdb\x11\x23\x3c\xd9\x47\x46\x71\xab\xf5\x5d\x8d\xa9\xc1\xb4\x0b\xc5\x3e\xdc\x5a\x67\x0f\xc6\x75\x01\xa7\xde\xf3\x9b\x77\xde\xb5\xec\x45\x71\x16\x4d\x71\x55\xe3\xaa\xd8\x87\x87\xae\xd5\x9c\x36\x06\xc2\xa6\xd5\x24\x8c\xb5\x0c\x1f\x6b\xc5\xba\xda\x0f\xf2\xad\x51\x8c\x19\xac\xc3\x98\x3b\xa7\x8e\xfc\x2e\xe5\x1e\xf1\x1f\xc1\x5e\x7c\xc8\xda\x19\x6a\xef\xfc\xbd\x56\x25\xbf\x65\x11\xf6\x63\x8d\xd3\x94\x53\xd7\xf9\x65\xf1\xd6\x3d\x0c\x22\xe5\x39\x33\x5b\x8b\xd4\x7d\x49\xc3\xc4\x5f\xce\xc1\x12\xb6\x45\x2a\x9e\x87\xf6\x12\x31\x2f\x03\xfe\x0a\x5a\xfa\x55\x76\x34\x4a\x32\x7c\x7e\x33\xce\x61\xa4\x9b\xf3\x8b\xab\x0e\x47\x65\x76\xd7\xb9\x3f\x94\x69\x35\x1b\xb6\x42\xb9\x11\xe6\xb3\xb3\x79\xb8\x7b\x73\xb7\xa9\x3d\x57\xdb\xd7\x20\x31\x93\xe1\x54\x48\x57\xa8\x0b\x5c\xdd\x40\x85\xd0\x31\xbe\x7b\xf5\xd3\xab\xed\xd1\x00\xc3\x54\x8b\xd4\x27\x02\x76\xbb\x85\x73\xd7\xf7\x78\x64\x09\xa9\x7f\x8c\x68\x3a\x43\xf6\x6c\xae\x84\x4d\x05\xb4\xf3\x01\x4d\x2c\xa4\x92\xc9\x9f\x9b\x18\x71\x55\xfc\xc1\x25\xab\x27\xf6\x53\xd1\xeb\x9c\xa4\xab\xa9\xd5\x76\x11\xc0\x66\xbb\x44\xde\xb0\x6b\x13\x79\xd9\x3a\xab\x1a\xfc\x11\x57\xc5\x1b\x15\x4a\xaf\x8c\xb2\x24\xce\xff\x36\xc8\x7d\x42\x3c\x9b\x9d\xa5\xf3\x36\xb5\xf4\xca\x4a\x8d\xf5\xf7\x1f\xd7\x97\x6f\xdf\x93\xee\xf8\xc2\x32\x67\xeb\x95\xd7\x39\x9f\x12\x7d\x5f\xc4\x78\xbe\x09\x7d\x9f\xc0\x2c\x1b\x70\xd6\xe1\x9e\x65\x51\x8a\xf0\x0d\xa5\x78\x06\xc3\xe6\x89\xf4\x7f\xeb\xb1\xc5\x85\x22\x96\xbf\x52\x91\xff\x43\x21\x7e\xc6\x13\xe9\xe7\x88\xcc\x3f\x25\x73\xe5\x86\xb9\xad\xc6\x7f\x50\xd2\x99\x0b\x4e\x16\xc9\x26\xcb\x88\xbc\x67\xaf\x12\x0f\x47\xc3\x67\x2d\xff\x0d\x00\x00\xff\xff\x41\xad\xdc\xe8\x4d\x08\x00\x00")
|
||||
|
||||
func templatesSchemapolymorphicGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -402,8 +428,8 @@ func templatesSchemapolymorphicGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/schemapolymorphic.gotmpl", size: 2061, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xd8, 0x38, 0x31, 0x5b, 0x7b, 0xaf, 0x27, 0xcd, 0xb5, 0x5f, 0x2d, 0x20, 0xa9, 0x78, 0xd9, 0x99, 0xfb, 0xc6, 0xb8, 0x2a, 0x88, 0x27, 0xdd, 0xd5, 0x59, 0x3f, 0xa5, 0xee, 0xdc, 0x33, 0x74, 0x7a}}
|
||||
info := bindataFileInfo{name: "templates/schemapolymorphic.gotmpl", size: 2125, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x95, 0x81, 0xb5, 0xb0, 0x9e, 0x91, 0x1d, 0xa4, 0xde, 0x61, 0x53, 0xa, 0xdc, 0x28, 0xc1, 0x77, 0x7c, 0xda, 0x72, 0xfe, 0x8d, 0xc6, 0x82, 0x2, 0xf1, 0x30, 0x41, 0x46, 0x35, 0x40, 0xde, 0x71}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
@@ -427,7 +453,7 @@ func templatesSchematypeGotmpl() (*asset, error) {
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesSchemavalidatorGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x5d\x5b\x73\xdb\x36\x16\x7e\x5e\xff\x8a\xb3\x9e\xec\xae\x94\xba\x54\x1f\x3a\x7d\x50\x37\x3b\x93\xa6\x69\xeb\xd9\xa6\xc9\x34\x4d\x1f\x36\x93\xd9\xc0\xd4\x91\x84\x86\x02\x19\x80\x94\xed\xd5\xe8\xbf\xef\x00\xe0\x05\x04\x01\x8a\xd4\xc5\x96\x5d\xf9\x49\x22\x41\x5c\xce\xe5\x3b\xe7\x7c\x00\xe5\xd5\x0a\x26\x38\xa5\x0c\xe1\x3c\xe1\x74\x41\x53\xba\xc4\x29\xc5\x68\xb2\x24\x11\x9d\x90\x34\xe6\xe7\xb0\x5e\x9f\x01\xac\x56\x40\xa7\x10\xfc\x8a\x9f\x33\xca\x71\xa2\x2f\xd2\x29\x20\xe7\x30\x7e\x06\x79\x73\x2c\x1b\xe8\xf6\x84\x4d\x60\x80\x9f\x21\xf8\x31\xfe\xed\x36\x41\x38\x17\x29\xa7\x6c\x76\x3e\x84\x01\x8b\x53\x08\x2e\xc5\x2f\x59\x14\x91\xab\x08\x87\xb0\x5e\xbf\x55\x37\x57\x2b\x40\x26\x07\x18\xe4\x63\xbe\x21\xe9\x1c\xd6\xeb\xd5\xca\xfc\x88\x91\x40\x58\xaf\xcf\xcf\xcb\xe6\x17\x72\x8e\x09\xa7\x2c\x9d\xc2\xf9\xdf\x3e\x9f\x43\xf0\x73\x1c\x92\x94\xc6\xac\xb8\x49\xa7\x20\x47\x1d\xc4\x5c\x8e\xfc\x9c\xc5\xec\x76\x11\x67\xc2\x9e\x86\x1c\x28\x9f\xaf\x9e\x84\xee\x7f\xb5\x0a\x7e\x27\x51\x86\x2f\x6f\x12\x8e\x42\xe8\x7e\xbb\xf7\x3a\x2c\x3b\x1a\x7e\xab\xa4\xf6\xd7\x67\xc0\x68\x04\xab\x33\x00\x00\x8e\x69\xc6\x99\xbc\x7e\x06\x90\xcb\x5b\xb7\xae\x64\xff\x8a\xb2\x9f\x91\xcd\x94\x04\xdc\xc2\x2f\x5b\xec\x57\x74\x5a\x69\x45\x9f\xd5\xb2\x60\xbd\x7e\xda\x2e\x9e\xa1\xec\xb9\x36\xf1\xad\x17\x4f\x6e\x36\x2d\xbe\x68\x71\x64\x8b\x37\x26\xbe\xed\xe2\xdf\x90\x34\x45\xce\xbc\x4b\xcf\xef\x1f\xd1\xc2\x3f\xae\x56\xc6\xac\x3f\xee\x60\xf2\x74\x91\x2d\xda\x0c\x5e\xde\xd7\xad\x25\xce\xbc\xbd\x26\xb3\x19\x72\x0d\x36\x94\xa5\x38\x43\x85\x60\x97\x2c\x3d\x28\xae\xb4\x8d\x4d\xf5\xd8\xba\xe3\x69\x14\x93\x6a\x2a\xdf\x7c\xbd\x93\x57\xe5\xb2\x51\x5f\x5f\xde\x84\x51\x26\xe8\x12\xab\xeb\x3b\xf8\x5a\xbb\xd4\xf5\xfd\x3f\xa7\xd4\x4b\xd9\x58\x52\x2f\xaf\x6f\x2d\xf5\x2c\x4a\x69\x12\xe1\xeb\xa9\x5f\xf0\x65\x93\xfd\x4a\x53\x89\x67\x27\xa9\x98\x73\xdf\x56\x00\x2f\x59\x61\x73\xa3\x91\x5c\x73\x86\x80\x2c\x5b\xd4\x44\xb1\x5a\x05\xbf\x62\x88\x74\x89\xfc\x17\xb2\x90\xf3\x0b\x0a\xe9\xc8\x15\x12\x11\x92\x88\xfe\x0f\x21\xc8\xef\x4a\xc1\xbc\xcd\xa6\x53\x7a\x03\xeb\xb5\x1c\xe0\x10\x66\xd8\x4f\x60\xfd\xa5\xf3\x65\x91\x4a\x05\x97\xe2\x45\x26\xd2\x78\xf1\x43\xcc\x17\x0a\x5d\xcb\x3c\xea\x6d\xca\x91\x2c\xaa\xbc\xea\x3b\x22\xf0\x9b\xaf\x87\xba\x0b\xd5\x61\x8a\x8b\x24\x22\x29\xc2\x79\x2e\x31\x1a\x33\xdd\xdb\x54\xf5\x76\x0e\x41\xa9\x8e\x7c\xf0\xea\xd3\xd9\x6a\x55\xe4\x89\x22\xa2\x21\x76\x4a\x0f\x5b\x13\xc4\xbd\x2b\xa2\xa3\xac\x2d\x69\xfb\xac\x51\x66\x73\xaf\x28\xbb\x4c\x71\x21\x14\x22\xea\x4f\x95\x38\x83\x4b\x36\xc1\x9b\xdf\x09\xd7\x33\x6e\x9a\xde\x5b\xf9\x65\xfc\x0c\x28\x93\xae\x15\xa1\x0c\xcf\xae\x39\x0e\xbd\xa1\xaf\x36\xa4\x3b\xfa\xa9\x26\xfb\x17\x65\x97\xb5\x15\x41\xa8\x98\xe5\x0e\xc2\x6e\xc8\xd7\x1d\x74\xee\x7d\xb1\xd5\x2c\x77\x59\xec\x3b\x46\x3f\x67\xb8\x69\xbd\x46\xab\x7d\x2f\x79\xbf\x9e\x62\xe0\xb6\x42\xee\x69\xcc\x41\x61\x84\xb5\xb2\xbe\xd0\x7d\x08\xb4\xde\xf3\xca\x2d\x4c\x28\x71\x5a\xd7\x82\xf2\x66\x85\x88\xf9\xf7\x9f\x88\xf8\xbd\x84\x5f\x51\x5c\xd5\x78\xad\x72\x98\xf2\xca\xf3\x88\x12\x81\x93\x12\xd2\xf3\xcb\x97\x2c\x45\x3e\x25\x21\xda\x37\x8a\x08\x90\x4f\x07\x94\x22\x56\x2b\xd3\xbc\xa5\x1a\xbe\xfa\xd6\xbe\xf8\x4f\xf0\x83\x93\xdd\xf8\x8b\x2f\x4a\x11\xc9\xf5\x5e\xd3\x74\x6e\x89\xc1\x12\x85\x19\x1b\xf5\x7c\x0b\x89\x54\xb1\xea\x15\x49\x64\x9b\xd7\x4b\xe4\x9c\x4e\x70\x68\x76\xa5\x2c\x48\x5c\x93\x59\x70\x29\xfe\x83\x3c\x1e\x78\x90\x1e\x56\xd2\xf6\x64\x87\x3c\xef\xdf\xe8\x02\x20\x8c\x59\x4a\x59\x86\xc6\xc5\xfa\x74\x4b\xd5\x16\x97\x8c\x78\x99\xf0\x38\x41\x9e\xde\x1a\x41\x2f\xa8\x1a\x37\x9e\xae\xcc\xa1\x16\xc3\x73\x73\x35\x6d\x25\xa7\x0c\xb4\xa2\x61\xc0\xb0\xb9\xb4\x9a\xcf\x68\x76\x62\xf4\x14\x12\x8e\x4b\x64\xa9\x80\x19\x32\xe4\x24\xc5\x09\x84\xf1\x04\x21\x8d\x21\x24\x51\x04\x34\x15\x18\x4d\xc7\x90\xce\xa9\x00\x2a\x80\xa3\x40\xbe\xc4\x89\xb2\x09\x92\x8f\x97\xde\x26\x28\xe0\xe9\xa8\xb6\x12\xaf\xda\xfc\x6a\xa2\x53\x4f\xf8\xb5\x9d\xaa\x21\xa9\x1a\x38\x34\x9f\x0f\x72\x4f\xc1\x81\xce\x50\x84\xdb\x57\x55\x3f\x4b\xbc\x80\xf8\x93\xec\x0a\x39\x0f\x06\x4f\x91\xf3\x98\x8b\xa0\xf2\xb5\xe1\xb7\xf2\xfe\xca\x30\x80\xdc\xc7\x97\x58\x8e\x23\x65\xdc\x13\x72\x86\x67\x4d\x7b\xb2\xc0\xa3\xba\xb5\xa5\x80\x3d\x96\xd6\xb4\x30\x3b\x6b\x33\xd8\xbd\x05\x49\x6a\x39\x9b\x32\xa3\x02\x7f\x05\x90\xc9\x84\x4a\x29\x91\xe8\x8d\x36\x76\x5a\x99\x46\x2e\x90\x9f\x88\x78\xee\x6a\x55\x37\x69\x08\x5c\x8d\x6c\xd8\x33\x9e\x79\x52\x4c\x62\xa2\x0c\x40\x48\x15\xba\x89\xb6\x27\x9f\xf0\x56\xa2\x90\x6c\xe0\x1c\xe4\xdf\xfa\x7e\xde\xb9\x86\xbf\x4d\x4d\x65\x6f\x9c\xb0\x19\xfa\x6c\xb8\x32\xde\x1c\xed\xda\x84\x60\xc7\x01\x0b\xf0\xea\x85\x82\x52\x81\xf8\x44\x13\xb8\x9e\x23\x03\x96\x45\xca\x25\xa5\xbf\x92\x30\xc4\x44\x7a\xb5\xe1\x9d\x4d\x1c\x6c\x88\x6e\xbd\x7e\x6f\xc8\x69\xbd\xfe\xd0\x06\x8b\x16\x24\x5a\x70\x28\x0d\xbd\x58\x85\x03\xb2\x9f\x73\x4e\x6e\x4b\x38\x2a\x83\x9c\x8a\xfb\x72\x01\x09\x8f\x43\x14\x12\x65\xae\x30\x8a\xaf\xad\x75\xdc\x59\x4d\xd0\x41\x42\x1e\x48\xf1\xfa\xb0\x27\x5c\x7c\x99\x17\x82\x6f\x0a\x16\xbd\x1e\xc4\xaa\x06\x05\xda\xd7\x6e\x97\x0d\x0a\xf1\Line truncated
|
||||
var _templatesSchemavalidatorGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x5d\x5b\x73\xdb\x38\x96\x7e\x5e\xfd\x8a\xb3\xae\xec\xac\xe4\x71\x4b\xd9\xaa\xa9\x79\x70\x4f\xba\xaa\x3b\x49\xcf\x78\x77\xdc\x49\x75\xd2\xd9\xaa\x4d\xa5\xb6\x61\x0a\x92\xd1\xa6\x40\x06\xa0\x7c\x59\x95\xfe\xfb\x16\x2e\x24\x41\x10\x20\x41\x49\xb4\x64\x47\x7e\x92\x49\x5c\x0f\xce\xf5\x3b\x00\xb8\x5a\xc1\x14\xcf\x08\xc5\x70\x92\x32\xb2\x20\x19\xb9\xc5\x33\x82\xe3\x69\x94\xd0\x0c\xdf\x67\xb7\x28\x26\x53\x94\x25\xec\x04\xd6\xeb\x01\xc0\x6a\x05\x64\x06\xe3\x5f\x31\x9a\xbe\xa3\xf1\x83\x7a\x08\xe2\x19\x66\x0c\xce\x5f\x81\xae\x80\x8b\x22\xc3\x28\xbb\x3f\xcb\xeb\xbd\x47\xd9\x35\xac\xd7\xab\x95\xf9\x13\xc7\x1c\xc3\x7a\x7d\x72\x22\x7e\xd3\x29\xac\xd7\xb2\x7c\xca\x08\xcd\x66\x70\xf2\x6f\x5f\x4f\x60\xfc\xcf\x24\x42\x19\x49\x68\xfe\x92\xcc\x80\x26\x19\x0c\x13\x06\xe3\x0b\xfe\x23\x4d\xe8\xc3\x22\x59\x72\xf1\xcf\x2f\xcb\x38\x46\x57\x31\x1e\xe9\x8e\xfe\x9e\x7c\x7c\x48\x45\x07\xc3\xa2\xfd\xd5\x6a\xfc\x09\xc5\x4b\xfc\xf6\x3e\x65\x98\x73\xd5\x6e\x78\xab\xa3\xa2\xa1\xd1\xf7\x72\xde\xff\xfa\x0a\x28\x89\x57\x92\x14\x00\x0c\x67\x4b\x46\xc5\x0b\xf9\x40\x93\x4d\x55\x18\x54\x7e\xb9\x49\xef\xa5\xf9\xd7\x25\x61\x78\x9a\xd3\x7c\xb5\xfa\x4e\x3c\x47\x74\x0a\x43\xfc\xb5\x98\xe7\x09\xcf\x18\xa1\xf3\x93\x11\x0c\xc5\x5c\xac\xa1\x0f\x3c\x6b\xa5\x9a\xfe\x20\xab\x0e\x7b\x58\x2c\x41\xce\x98\x20\x8e\xa7\x1b\xad\x4a\xa5\xba\x87\xfc\xb0\x2a\xc8\xa2\x07\xd9\x3c\xd9\x3e\xa6\x79\x70\x3c\x69\x12\x85\x16\xac\x53\xe1\x50\xc5\x62\xc6\x7b\x4d\x97\x4b\x42\xff\x89\xe9\x5c\x52\xc4\x27\xe4\x45\x99\x9d\x13\x73\xfc\x31\x51\xdc\xa8\x1f\x54\x86\xe3\x9a\x62\xd8\x9c\xd0\xbd\x39\x27\xd7\x8c\xf2\x12\x8f\x30\x23\x63\x30\x81\x33\xaa\x4d\xe8\x3d\xca\x32\xcc\xa8\x77\x3a\xfa\x7d\xcf\x93\xf9\x5d\xd4\xe4\x11\x4a\xf1\x4f\x28\xba\xc9\x48\x74\xc3\xcd\xa1\xfd\xbe\xf9\x7a\x11\x4a\x16\xcb\x45\xa9\xf2\x20\xc3\x8b\x34\x46\x19\x86\x13\x3d\x47\x92\x50\x5d\xea\x04\xc6\x45\x65\xc7\xc2\x87\x34\xa4\x4a\x35\x36\xb4\x8c\x33\x92\xc6\xf8\xdd\xac\xad\xad\xa2\x60\x53\x73\x6f\x69\x3e\xa8\xc9\x44\xac\xda\x12\x03\xa6\xcb\x45\x65\x31\x57\xab\xf1\xaf\x38\xc2\xe4\x16\xb3\x5f\xd0\x42\x2c\xd5\x38\x5f\x5f\xb1\x4c\x88\x47\x28\x26\xff\x87\x61\xac\xdf\x8a\xe5\xf9\xb0\x9c\xcd\xc8\x3d\xac\xd7\xa2\x83\x9e\x14\x7a\xae\x7e\x60\xbd\x3e\x6d\x56\x63\x9b\xae\xbf\xb0\x6d\xe3\x0b\xfe\x7a\xc9\xb3\x64\xf1\x73\xc2\x16\x92\xa5\x0a\xc3\xf6\x21\x63\x18\x2d\x4a\x43\xf7\x13\xe2\xf8\xaf\x7f\x19\xb5\x2c\x8c\x6a\x6d\x26\x5b\x33\x96\xe6\xbb\xba\x85\x36\x4d\x34\x8f\x49\x84\x8f\x4e\x51\x3f\x4e\x51\x41\xc2\x8b\x0c\x2f\xb8\xcb\xc1\x91\x9d\x8b\x97\x25\x95\xf5\xff\xff\x40\xfc\xb5\x5a\x96\x4f\xc5\x12\xf3\x82\x27\x64\x91\x0b\x7e\x41\x33\xcc\x66\x28\xc2\xf6\x8b\x9c\x85\x74\x97\x00\xb3\x84\x09\x81\xbb\xa0\x53\x7c\xff\x09\x31\x58\xaf\xc5\x02\xbe\xfc\xde\x7e\xf8\x37\x88\xb1\x50\xab\x6e\x6e\xaf\x16\xfe\xf3\x9f\x21\x27\x83\x98\xd3\x1d\xc9\xae\xad\xa9\xd6\xd8\x35\x65\x49\x8a\x59\xf6\x50\xe7\xb8\x71\x59\xc7\xb2\xea\x8a\xaa\x35\x41\x32\xdd\xa1\x82\xa8\x7a\x31\xb5\x4f\x35\xa4\x18\x6a\x13\xa9\x28\x1d\xc5\x37\x93\x53\x48\x19\xbe\xc5\x34\xe3\x30\xc7\x14\x33\x94\xe1\x29\x44\xc9\x14\x43\x96\x40\x84\xe2\x18\x48\xc6\x71\x3c\x3b\x87\xec\x9a\x70\x20\x1c\x18\xe6\x98\xdd\xe2\xa9\x24\x2c\xd2\xfd\x65\x0f\x29\xe6\x70\x3a\xa9\xcc\xa4\x94\xf7\x42\xb1\xe4\x82\x7d\x89\x52\xf1\xec\xdd\x2d\x66\x8c\x4c\xf1\xc8\x90\x30\xc1\xcc\xf5\x25\xa8\xaa\x1a\x07\xa5\x2a\xda\xb5\x5e\x7f\x5c\x65\x29\xac\xe4\x55\xe9\x0c\xee\xd2\x66\xba\xcd\x5b\x7c\x06\xc9\x8d\x68\x16\x33\x36\x1e\x9e\x62\xc6\x12\xc6\xc7\x25\x67\x8e\xbe\x17\xef\xcb\x3a\x85\x60\xdc\xe2\xbc\x14\x16\xf4\xee\xa8\xb2\x47\x45\x83\x25\x3f\x59\x12\x57\xbe\xda\x90\xd8\x1e\xae\xab\x73\x9b\x43\x8d\x56\xb4\x68\x60\x7c\xf3\x98\xae\x7b\xa0\xcd\x0a\x54\x63\x42\xb8\x2e\x09\x55\x12\x2e\x5c\x0f\x4b\xad\x81\xa9\x1c\x9c\x26\xfc\x83\xf8\xe7\xfc\x15\x10\x9a\xfd\xf5\x2f\x43\xbf\xa6\x19\x79\x9c\x94\xbc\xf3\x46\xcf\x5d\x16\xd9\x3d\x29\x43\xe6\x96\x7b\xf4\xf9\x28\xb7\x20\x76\x8d\xbe\x6e\xa7\x7e\xef\x93\x2d\x47\xb9\xcd\x64\x7f\xa3\xe4\xeb\x12\xb7\xcd\xd7\x28\xb5\xeb\x29\xef\x56\x52\x0c\xff\x57\x7a\xc0\xc2\x48\x48\x1d\x31\xa8\x29\xe9\x4e\x2e\x70\x1f\x5e\xef\x8e\x67\x1e\xe4\xea\x68\x8d\x58\xba\x3a\x86\x8f\x53\x3a\x31\xc2\xef\x95\xee\x5c\xf1\x44\x1b\xf6\xce\x6e\x90\xf9\xf4\xc3\x0d\x49\xdf\xde\x8b\x10\x0e\xc5\x86\x01\x3b\x0c\x57\xa9\xc1\x82\xe5\x54\x1b\xb5\x5a\xb4\x4a\x63\x26\x79\xaa\x05\xfc\x5e\xc6\x2b\xbd\xf0\x82\x75\x45\x5f\x4c\x77\x6d\xb5\x6e\xfa\x5f\x45\x93\xfc\x0e\xcd\xc7\x17\xfc\x7f\x30\x4b\x86\x1e\x0b\xd4\xde\xb0\xe9\xd2\xa8\x3f\xe1\x30\x12\xba\xc4\xc6\xc3\x2a\xdd\xac\x3a\x4e\xaf\x73\xe7\xee\x66\xc9\xd8\x9d\x7c\x4e\xb5\x80\x1e\x46\xfc\xd6\x5c\xd2\xc2\x17\x3d\xba\xa1\x0e\xfa\xb5\xbb\xa1\x46\x30\xbf\x40\xa9\x37\x94\x2f\x07\xe5\x01\xdc\x15\x1b\x17\xe3\x75\xe9\x0d\xcd\x04\xb6\xc9\x72\x9a\xaa\x42\x89\xd4\xac\x87\x58\xb2\x7e\x3c\x5e\x4a\xe2\xd1\xc0\x92\x60\x43\x68\x1b\x3c\xef\x12\x97\x09\xcf\x39\x28\xa0\xb0\x18\xdb\xc1\xe1\xee\x81\x0b\xb5\x2b\x2c\xde\xe9\x20\xf8\x19\xb8\x70\x18\xfe\x81\xf8\x8f\xd3\x29\x11\x33\x47\xf1\x7b\xa5\xa9\x09\xb6\x5d\x08\x18\xbb\x0a\xb9\Line truncated
|
||||
|
||||
func templatesSchemavalidatorGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -442,12 +468,12 @@ func templatesSchemavalidatorGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/schemavalidator.gotmpl", size: 31954, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xf4, 0x45, 0xe4, 0x3d, 0x35, 0x81, 0x2f, 0xdb, 0x7b, 0xba, 0x7e, 0x80, 0x2d, 0x28, 0x7b, 0x73, 0x23, 0x69, 0x4e, 0xfc, 0x8d, 0xdc, 0xa2, 0x16, 0x87, 0x17, 0xff, 0xf7, 0xee, 0x89, 0x9, 0x71}}
|
||||
info := bindataFileInfo{name: "templates/schemavalidator.gotmpl", size: 51727, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xd0, 0xc2, 0x39, 0xa0, 0x71, 0x8a, 0xa0, 0xcf, 0x3c, 0xd5, 0x93, 0xe0, 0xed, 0x21, 0x1b, 0x9c, 0xa, 0x25, 0xbd, 0x5b, 0xfb, 0x2a, 0xd3, 0x57, 0xf8, 0x5a, 0xa7, 0x38, 0x29, 0x59, 0x2b, 0x68}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesSerializersAdditionalpropertiesserializerGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xc4\x56\x4d\x6f\xe3\x36\x10\xbd\xeb\x57\xbc\x1a\x6d\x56\x2a\x14\xb9\xc9\xde\xd2\xba\xc0\x16\xdb\x02\x2d\xb0\x69\x91\xed\xf6\x62\xe4\xc0\x48\x63\x9b\x1b\x9a\x54\x49\xda\x6e\x2a\xe8\xbf\x17\xfc\x58\x4b\x6a\x24\xc3\x9b\xcb\xea\x46\x6a\x38\xf3\xe6\xcd\xcc\x23\x9b\x06\x15\xad\xb8\x24\xcc\x58\x55\x71\xcb\x95\x64\xe2\x0f\xad\x6a\xd2\x96\x93\x79\x4f\x9a\x33\xc1\xff\x25\x3d\x43\xdb\x26\xf3\x39\x3e\xc8\x2d\xd3\x66\xc3\xc4\x6f\xef\x7f\xbf\xc5\xee\xd3\xca\xc0\x6e\xb8\x81\x7a\xf8\x48\xa5\xc5\x81\xdb\x0d\x3a\x7f\xa8\x8f\x0e\xb1\xd2\x6a\x0b\x77\x36\x59\xed\x64\x89\xb4\x69\x8a\x3b\x2a\x89\xef\x49\xdf\xb2\x2d\xb5\x2d\xbe\x6d\x1a\xd4\xcc\x94\x3e\x2e\x0a\xb7\x8b\xb6\xcd\x86\x91\xd3\x8a\x59\x86\xe5\xfd\xc3\x93\xa5\x0c\xa4\xb5\xd2\x68\x12\x60\x3e\x87\xb1\x6c\x4d\xb8\xca\xf1\xc0\x65\x05\xbb\xa1\x5e\xf8\x04\xd8\x33\x1d\x4c\xae\xd0\x34\xb0\xb4\xad\x05\xb3\x84\x99\xc3\xac\x76\xf6\xcd\x11\xf5\x4f\xaa\x7a\x9a\xa1\x70\x79\x03\x7c\xe5\x82\xe0\x66\x81\x8f\x46\xc9\xe2\x88\xc5\xe3\xc8\x71\x11\x3c\x66\xdf\x7b\xab\xaf\x16\x90\x5c\x78\x3c\x80\x26\xbb\xd3\xd2\xed\x27\x40\x1b\x01\xe8\x72\x8f\xd1\x34\x13\xb8\x7d\xcd\xe4\x9a\x50\x74\x75\x08\x7f\x74\xb9\x2f\x46\x4f\x61\x11\x53\x1a\xff\xed\x9d\x5e\x82\x64\x15\x16\x8e\xe1\x01\xeb\xc1\x85\x2e\xf7\x49\x9f\xc2\xeb\x1c\x9a\xb6\x6a\xdf\x27\x10\x4c\x56\xae\xb2\xb0\x0a\x5b\x56\x27\x08\xb6\xd7\x8e\x99\x2d\x7b\xa4\x74\xcb\xea\xa5\xb1\x9a\xcb\xf5\x7d\xd3\x38\xda\x8a\x37\x23\x7d\x85\xb6\xf5\x3c\xde\xb1\xc3\x3b\x32\x86\xad\xa9\x69\x40\xc2\x38\x24\x5c\x5a\xd2\x2b\x56\x52\xd3\xba\x4d\x0f\x3a\x3b\xb7\x04\xd7\x67\x94\xe0\x24\xc7\x15\x09\xb2\x94\x06\x67\xb9\x2f\x92\xe6\xd2\xae\x30\xfb\xe6\xef\x59\xd7\x8d\x43\x4a\xe3\xea\x44\xb6\x7d\x5e\x5f\xe7\x9e\xc1\xf1\xf9\xd8\x33\xb1\xf3\x7d\xca\x57\x10\x24\x23\x90\x0c\x3f\xe2\xbb\x63\x36\x66\x27\xec\x04\xe1\x5d\x3f\x9b\x72\x43\x5b\xf6\xe7\x53\x4d\xb3\x49\x54\x99\x77\xb8\x52\x1a\x8f\x39\xf6\xce\x65\x60\x25\xd6\x34\xc4\x0b\x1d\x6b\x95\xc3\xfc\xd9\x11\xa2\x87\xc9\xda\xed\x1d\xc5\x7c\x05\xa9\xec\xb8\x8f\xe2\x57\x73\xbb\x13\x82\x3d\x08\xc7\xfb\xc5\xb1\x23\x3c\x9e\xb1\x62\x3f\x2b\xb8\xfb\x3e\xe1\x08\xdc\x2d\x1f\xef\xb1\x08\x19\x25\xdd\x5f\x37\x14\x7f\x39\xf6\x7f\xfe\xa7\xd6\x64\x0c\x57\x32\xce\x85\x3f\x14\xa7\xd7\x57\x3d\x34\x6a\x72\xe2\x4c\x60\xf0\x59\x97\x44\x60\x92\x8b\xa4\x4d\x9c\x9c\xbe\xeb\x89\xe9\xe7\x4a\x29\x97\x56\x81\x79\x31\x8d\xd6\x93\x9a\x3a\x21\xa9\xbd\xe8\x69\x86\x34\xc8\x69\x1e\xe4\x34\xf3\x7c\xbe\x4c\x2d\xa7\xc7\xeb\x94\x4c\x61\x31\xc1\xe7\x33\x1a\xe7\x73\xdf\xfb\xfd\xd4\x43\x17\x4b\x75\x90\x43\xb9\x77\x0b\x93\x0f\xba\x2f\x66\x9d\x46\xcd\xee\xa4\x65\x4c\x34\x24\x17\x79\x5f\x39\xe2\x58\x8e\x03\xcd\xb0\x58\xf4\xe6\xd4\x3b\x88\x00\x5c\xc9\xa3\x8b\x29\xf4\xee\xaa\x1a\xad\x74\x82\xde\xfe\x78\x2e\x13\x78\x5e\x94\x9b\x47\x9c\xe1\x07\xbc\x1e\x9a\xf7\x31\x0c\xd3\x29\x95\x2c\x99\x25\xe9\x5a\xc3\x65\x71\x1d\xd3\x3a\x16\x60\xd9\xf9\xbd\xbc\x72\xc3\xf7\x2a\x7f\xd5\x8d\x03\xab\x6b\x92\x55\x1a\x99\xea\xc2\x2c\xaf\x6e\xee\x8b\xa2\xc8\xf2\x38\x30\xfd\x26\xe8\x3d\x5c\xa4\x1a\x13\x8e\x97\x3e\x5d\x36\x5c\x10\x2a\x6e\x98\x10\xea\xc0\xe5\xfa\xcb\xbc\x63\xdc\xdc\x79\x3e\xce\x1f\x3b\x7f\x79\x95\xc7\xce\xb8\xa5\xc3\x5b\x2a\x55\x45\x3a\x75\xce\x8d\xdb\xb8\x23\xe6\xd6\x2e\x66\x96\x05\xfb\xe2\x6d\x4c\xf5\x83\xf4\xd3\xf3\x0b\x27\x51\x99\x74\x78\xe1\x7a\x3b\xef\x2c\xbd\x08\x55\x3c\xf3\x96\xbd\xc4\xd7\xee\xa9\x73\xb3\xc0\xb3\x07\xc7\x49\x99\x08\xca\xfa\xbf\x13\x93\xaa\xe1\x21\x9d\xf7\xf4\x19\x08\x70\xef\xcf\x7f\x01\x00\x00\xff\xff\xe9\x8a\xbc\x88\x08\x0b\x00\x00")
|
||||
var _templatesSerializersAdditionalpropertiesserializerGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xc4\x56\x5d\x8f\xdc\x34\x14\x7d\xcf\xaf\x38\x8c\x60\x95\xa0\x34\x43\xb7\x6f\x0b\x83\x54\x28\x48\x20\x75\x41\x5b\xca\xcb\x6a\x1f\xbc\xc9\xcd\x8c\xbb\x8e\x3d\xd8\x9e\x0c\x4b\x94\xff\x8e\xfc\xd1\x49\x86\x4d\x86\xe9\xbe\x34\x6f\x76\xec\xeb\x73\xcf\x3d\xf7\xd8\x5d\x87\x8a\x6a\x2e\x09\x0b\x56\x55\xdc\x72\x25\x99\xf8\x5d\xab\x2d\x69\xcb\xc9\xbc\x23\xcd\x99\xe0\xff\x90\x5e\xa0\xef\x93\xe5\x12\xef\x65\xc3\xb4\xd9\x30\xf1\xeb\xbb\xdf\xae\xb1\xfb\x38\x32\xb0\x1b\x6e\xa0\xee\x3f\x50\x69\xb1\xe7\x76\x83\x21\x1e\xb6\x87\x80\xa8\xb5\x6a\xe0\xf6\x26\xf5\x4e\x96\x48\xbb\xae\xb8\xa1\x92\x78\x4b\xfa\x9a\x35\xd4\xf7\xf8\xba\xeb\xb0\x65\xa6\xf4\xe7\xa2\x70\xb3\xe8\xfb\xec\xf8\xe4\xb4\x62\x96\xe1\xf6\xee\xfe\xd1\x52\x06\xd2\x5a\x69\x74\x09\xb0\x5c\xc2\x58\xb6\x26\xbc\xcc\x71\xcf\x65\x05\xbb\xa1\xd1\xf1\x09\xd0\x32\x1d\x96\xbc\x44\xd7\xc1\x52\xb3\x15\xcc\x12\x16\x0e\xb3\xda\xd9\xd7\x07\xd4\x3f\xa8\xea\x71\x81\xc2\xe5\x0d\xf0\xda\x1d\x82\xab\x15\x3e\x18\x25\x8b\x03\x16\x8f\x23\xc7\x45\x88\x98\x7d\xeb\x57\x7d\xb1\x82\xe4\xc2\xe3\x01\x34\xd9\x9d\x96\x6e\x3e\x01\xfa\x08\x40\x97\x2d\x26\xd3\x4c\xe0\xe6\x35\x93\x6b\x42\x31\xd4\x21\xfc\xd1\x65\x5b\x4c\xee\xc2\x2a\xa6\x34\xfd\xdb\x07\x7d\x01\x92\x55\x18\x38\x86\x8f\x58\x0f\x21\x74\xd9\x26\x63\x0a\x2f\x73\x68\x6a\x54\x3b\x26\x10\x4c\x56\xae\xb2\xb0\x0a\x0d\xdb\x26\x08\x6b\x2f\x1d\x33\x0d\x7b\xa0\xb4\x61\xdb\x5b\x63\x35\x97\xeb\xbb\xae\x73\xb4\x15\xaf\x27\x74\x85\xbe\xf7\x3c\xde\xb0\xfd\x5b\x32\x86\xad\xa9\xeb\x40\xc2\x38\x24\x5c\x5a\xd2\x35\x2b\xa9\xeb\xdd\xa4\x07\x9d\x9d\x5b\x82\xcb\x33\x4a\x70\x92\xe3\x8a\x04\x59\x4a\x43\xb0\xdc\x17\x49\x73\x69\x6b\x2c\xbe\xfa\x6b\x31\xa8\xf1\x98\xd2\x38\x3a\x91\xed\x98\xd7\x57\xb9\x67\x70\xba\x3f\x5a\x26\x76\x5e\xa7\xbc\x86\x20\x19\x81\x64\xf8\x1e\xdf\x1c\xb2\x31\x3b\x61\x67\x08\x1f\xf4\x6c\xca\x0d\x35\xec\x8f\xc7\x2d\x2d\x66\x51\x65\x3e\x60\xad\x34\x1e\x72\xb4\x2e\x64\x60\x25\xd6\x34\x9c\x17\x14\x6b\x95\xc3\xfc\xc9\x27\xc4\x08\xb3\xb5\x6b\x1d\xc5\xbc\x86\x54\x76\x3a\x46\xf1\x8b\xb9\xde\x09\xc1\xee\x85\xe3\xfd\xe2\xa0\x08\x8f\x67\xaa\xd8\x4f\x0a\xee\xbe\x8f\x38\x02\x77\xb7\x0f\x77\x58\x85\x8c\x92\xe1\xaf\x6b\x8a\x3f\x1d\xfb\x3f\xfd\xbd\xd5\x64\x0c\x57\x32\xf6\x85\xdf\x14\xbb\xd7\x57\x3d\x08\x35\x39\xb1\x27\x30\xf8\x44\x25\x11\x98\xe4\x22\xe9\x13\x67\xa7\x6f\x47\x66\xfa\xa9\x56\xca\xa5\x55\x60\xde\x4c\xe3\xea\x59\x4f\x9d\xb1\xd4\xd1\xe9\x69\x86\x34\xd8\x69\x1e\xec\x34\xf3\x7c\x3e\xcf\x2d\xe7\xdb\xeb\x94\x4d\x61\x35\xc3\xe7\x13\x1a\x97\x4b\xaf\xfd\x71\xea\x41\xc5\x52\xed\xe5\xb1\xdd\xbb\x81\xc9\x8f\xd4\x17\xb3\x4e\xa3\x67\x0f\xd6\x32\x65\x1a\x92\x8b\x7c\xec\x1c\xb1\x2d\xa7\x81\x66\x58\xad\x5c\x9f\x3a\x80\x52\x4d\x97\x6d\x1c\x3c\x82\x73\x72\x88\xe1\xe7\x32\x73\xd7\xd8\x5c\xb8\x61\x7e\x3a\xcf\x19\xac\xcf\xca\xdb\x23\xce\xf0\x1d\x5e\x85\x2c\x17\x5d\xbf\xb8\x82\x92\xe2\xf1\xff\xb3\x1d\xe3\x3c\x4e\xb9\x54\xb2\x64\x96\xa4\x93\x96\xcb\xf4\x32\xa6\x6e\x86\x96\x31\x7b\xb6\x2e\x7e\xf4\xeb\xbc\x5c\x23\x75\x43\xcc\x2c\x8f\x6d\x35\x96\xca\xe8\x79\x23\xd5\x94\xbd\x3c\xf7\x81\xb3\xe1\x82\x50\x71\xc3\x84\x50\x7b\x2e\xd7\x9f\xe7\xb5\xe3\xba\xd3\x13\x71\x7e\x73\xfa\x2b\xae\x3c\x68\xe4\x9a\xf6\x6f\xa8\x54\x15\xe9\xd4\x05\x37\x6e\xe2\x86\x98\x1b\xbb\x33\xb3\x2c\xac\x2f\xde\xc4\x54\xdf\x4b\xdf\x63\x3f\x73\x12\x95\x49\x8f\xaf\x65\xbf\xce\x07\x4b\x2f\x82\x4e\xce\xbc\x8b\x5f\xe0\x4b\xf7\x20\xba\x5a\xe1\xc9\xb3\xe4\xa4\x99\x04\xff\xfd\xcf\x8e\x59\x6f\xf1\x90\xce\x7b\x20\x1d\xd9\xf4\xe8\xcf\xbf\x01\x00\x00\xff\xff\xe1\x74\x4b\x47\x2e\x0b\x00\x00")
|
||||
|
||||
func templatesSerializersAdditionalpropertiesserializerGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -462,8 +488,8 @@ func templatesSerializersAdditionalpropertiesserializerGotmpl() (*asset, error)
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/serializers/additionalpropertiesserializer.gotmpl", size: 2824, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x2f, 0x47, 0x3f, 0xb1, 0x62, 0x4b, 0x2b, 0x29, 0x88, 0x51, 0xf, 0x95, 0x6d, 0xcd, 0x3, 0x0, 0x3d, 0xd6, 0x57, 0x55, 0x3f, 0xb3, 0x58, 0x2c, 0xb4, 0x2c, 0x2d, 0x41, 0x26, 0xbc, 0xf, 0x47}}
|
||||
info := bindataFileInfo{name: "templates/serializers/additionalpropertiesserializer.gotmpl", size: 2862, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xe5, 0xaa, 0x7f, 0x2c, 0x81, 0x11, 0x85, 0x37, 0x2f, 0x55, 0xab, 0xb3, 0xd4, 0x6c, 0xaf, 0xef, 0x65, 0x95, 0x4e, 0x49, 0xa, 0x29, 0x76, 0xa0, 0xcc, 0x51, 0x22, 0x54, 0x54, 0x8d, 0x84, 0xf7}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
@@ -607,7 +633,7 @@ func templatesSerializersTupleserializerGotmpl() (*asset, error) {
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesServerBuilderGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xcc\x3c\x5d\x6f\xe3\x38\x92\xcf\xa7\x5f\x51\x6b\xec\xde\x59\x0d\xb7\xdd\xb8\xa7\x43\x06\x39\x20\x93\xcc\xec\xe6\x6e\x66\x3a\xe8\xf4\xdc\x3d\x04\x8d\x05\x23\x95\x6d\x5e\xcb\xa4\x86\xa4\xe2\xc9\x0a\xfa\xef\x07\x7e\x8a\xfa\xb2\x1d\x77\x7a\xa7\xf3\x92\x48\x24\xeb\x9b\xc5\xaa\x62\x29\xab\x15\x5c\xf3\x1c\x61\x83\x0c\x05\x51\x98\xc3\xe3\x33\x6c\xf8\x5b\xb9\x27\x9b\x0d\x8a\xef\xe0\xe6\x3d\xfc\xf2\xfe\x23\xfc\x70\x73\xfb\x71\x99\x24\x49\x5d\x03\x5d\xc3\xf2\x9a\x97\xcf\x82\x6e\xb6\x0a\xde\x36\xcd\x6a\x05\x75\x0d\x19\xdf\xed\x90\xa9\xde\x58\x5d\x03\xb2\x1c\x9a\x26\x49\x92\x92\x64\x9f\xc9\x06\xa1\xae\x97\x77\xf6\xcf\xa6\xd1\x00\xff\xec\x07\x2e\x2e\xc1\x8f\x98\x15\xab\x15\x7c\xdc\x52\x09\x6b\x5a\x20\xec\x89\xec\x52\xa9\xb6\x08\x8e\x4c\x50\x9c\x17\x4b\x3d\xff\x87\x9c\x2a\xca\x36\xa0\xc2\xba\x9d\x21\xa5\x14\xfc\x09\x61\x5d\x29\x03\x6a\x8b\x0c\x9e\x79\x05\x02\xdf\x8a\x8a\x75\x20\x79\x14\x86\x1f\xc2\xf2\x24\xa1\xbb\x92\x0b\x05\xf3\x04\x60\x96\x71\xa6\xf0\x77\x35\xd3\x7f\xaf\x77\xf6\x37\xe5\xe6\x17\x43\xb5\xda\x2a\x55\x9a\x07\xa9\x04\x65\x1b\x39\x4b\xf4\xc3\x86\xaa\x6d\xf5\xb8\xcc\xf8\x6e\xb5\xe1\x6f\x79\x89\x8c\x94\x74\x85\x42\x70\x21\x67\xd3\x13\x0a\x4e\xf2\x43\xe3\xa2\x62\x8a\xee\xf0\xf8\x8c\xd5\x8e\xe6\x79\x81\x7b\x22\x4e\x99\x2c\x31\xab\x04\x55\xcf\x07\xa6\xca\x12\xb3\x43\xc3\x4a\x78\xd9\x4c\x4c\xd8\x93\x8d\x11\x8d\xb6\x26\x23\x5d\x09\xcb\x1b\x5c\x93\xaa\x50\xb7\xee\xb9\x69\x7a\xe3\xd1\x40\x6a\x4c\xe3\x17\xdc\xd7\x35\x94\x44\x66\xa4\xa0\xff\x40\x58\xfe\x42\x76\xda\x6e\xae\xee\x6e\x21\x13\x48\x14\x4a\x20\xc0\x70\x0f\xa3\xd3\x80\x32\xa9\x08\xcb\x30\x59\x57\x2c\x3b\x04\x6d\xae\xf9\x85\x37\x46\x1f\xcb\x1b\x9e\x55\xda\xce\x53\x78\x33\x89\xbd\x4e\x00\x04\xaa\x4a\x30\xf8\xd7\xa9\x49\x7a\x0e\xc0\x96\xb0\xbc\x40\x21\x2f\xa0\xfb\xb3\x23\x9f\x71\xbe\x23\xe5\x83\x35\xa4\x4f\xd1\x9f\xda\xc6\x96\x7f\xb3\xeb\xd2\x85\x81\xb2\xe6\x62\x47\xd4\x00\x08\x58\x45\x78\xc9\xda\xb9\xb9\x7d\xb8\xe6\x4c\x56\x3b\x6c\xd7\xcc\xea\x3a\xe8\xc0\x0f\x42\xd3\xcc\x3a\xab\xee\x04\xcf\xab\x6c\x62\x95\x1f\x6c\x57\x65\x95\x54\x7c\xe7\xa0\x45\x4c\xf6\xb9\x73\xa6\xb7\xf4\x33\xd3\x78\xb9\x03\x7b\xc2\x72\x3f\xd3\x2d\xbf\x13\x78\x8f\xe2\x09\xc5\xfd\xb6\x52\x39\xdf\x33\x07\x40\xab\x7b\x9e\x42\x0d\xd0\xd8\x89\xa3\xb3\xc6\x26\x6a\x3b\x18\x08\xd9\xbd\xb7\x33\x2a\x89\xf7\xd6\x91\xfc\x7a\x1b\xcf\x5c\x93\x42\x62\x84\xed\x07\xbd\xf9\xbb\xa0\xac\x3f\x58\xb6\xc3\x76\xfa\xf7\x44\xd2\xec\xaa\x52\x5b\x64\x8a\x66\x44\xf9\x65\x7e\x9b\x2e\xc3\x04\x3b\xff\xea\xee\xf6\xbf\xf1\x79\xb8\x20\xcc\x6f\x27\x38\x04\x48\x04\x8a\x03\x0b\xda\x09\x76\x41\x5d\x83\x20\x6c\x83\xb0\x8c\xec\x24\xb1\x4c\xd4\xf5\x5b\x73\x3e\xdc\xee\xca\x02\xf5\x36\x21\x8a\x72\xd6\x8e\xc3\xf8\x5e\xf4\x8a\xbf\xd0\xc3\xc3\xc5\x8b\x08\x3a\x16\x12\x5f\x00\xaf\x6f\x5a\x3f\x6a\x9d\x1a\xc5\x0a\xa0\x7c\xf9\x01\x49\x8e\x62\x01\x8a\x88\x0d\x2a\xa0\x4c\xa1\x58\x93\x0c\xeb\x26\xb5\x0a\x81\x3a\x69\x55\xe4\xf6\xb4\xd3\xd4\x2f\x5c\x05\x4a\x31\x9f\xcf\xea\xda\xa0\x6f\x1a\xc8\x1c\x32\xd8\x12\x09\x8c\x2b\x78\x46\x05\x8f\x88\x4c\x7b\x33\xbf\x60\x96\x06\xc8\x4d\xda\xe1\xd0\x9e\x97\xa3\x8f\x5e\xf2\xd1\x5e\xfb\x32\xc9\xfb\x3d\xf3\x5a\x92\x6f\xe1\xf5\x77\x65\x2b\xf9\xbd\x96\xfc\xff\x0a\xaa\xb4\xe4\x73\xa2\xc8\x6b\xc9\xbd\x74\xa8\xbe\x9e\xdc\xdf\x97\x3a\x38\xa0\x9c\x75\x24\xaf\x05\xcf\xb0\x8d\x5d\x42\x40\x63\xe2\x9f\x48\x48\x77\xf1\x7b\x8b\x60\x54\x8a\xce\xbd\x5f\x44\xb2\x7e\x7b\x18\x89\x7f\x7d\x55\x50\xa2\x69\x5b\x9e\x84\xa0\xd5\x49\x49\x04\xd9\xc9\xa3\xbc\x8c\xa0\xe9\x89\x8d\xae\xe1\xcf\xcb\xbf\x22\x7b\x5f\x2a\xb9\xbc\x57\x82\x66\xea\x03\xca\x92\xb3\x1c\x85\xec\x58\xcf\xdb\x31\xf3\x31\x64\xd4\xb5\xb6\x64\xed\x71\xb8\xa0\xff\xc0\xbc\x69\x16\x50\x0a\xca\x32\x5a\x92\x02\xcc\xa8\xd6\xee\x1c\xf0\x37\xbd\x15\xfc\xc0\x2c\x32\xa3\x19\xa4\x4d\xf3\x26\x12\x42\x3b\x4f\x3f\x21\xcb\x9b\x26\x75\xa0\x8e\x72\x7b\x5c\x9e\x81\xc5\x60\xb7\xce\x66\x5f\x0d\x43\xcf\xea\x53\x27\x70\xbd\x29\xbf\x35\xa9\xb6\xe1\xe6\x72\x52\x2e\xd1\x9c\xfe\x7e\xe6\x7e\x8f\x9d\x6c\x8d\x3d\xe9\xf5\x04\xd0\x34\xa7\xf8\x03\xb7\xfe\xad\x13\xa6\x77\x0d\x93\x9e\xe0\xde\x1d\x8f\x37\xb8\xa6\x8c\x0e\x5c\x82\x73\xc6\x32\x9c\xce\xed\xe0\x6a\x05\x57\x65\x59\x50\x94\x36\x11\xd1\xd9\x87\xd7\x8a\xe5\x7b\x6b\x4e\x25\xa0\x12\x24\x2a\xd8\x53\xb5\x35\x93\x0c\x2c\x90\xd9\x16\x77\x98\x0c\x3d\xf0\xed\x8d\x8e\x2c\x2b\xb5\xbd\xb0\x91\x4b\x25\x51\x80\x0d\x91\x16\x7a\x9e\x74\x0f\x29\xcc\xbf\x5c\xd9\x0b\xeb\x8d\xd3\xbe\x5e\x19\x2d\x16\x53\x8e\xfa\xd1\xd0\x4f\xb4\x30\x34\x09\x8e\xe2\xf4\x14\xed\x34\x13\x8e\x3a\x16\x75\x1b\xd8\x1c\x96\xb5\x89\x59\xdd\xce\x98\x99\x63\xef\x9e\x57\x22\xb3\x39\x81\x11\xf9\x09\xc2\x55\xfc\x33\xb2\x3f\x5a\xa0\xa4\xa4\xf0\x19\x9f\xad\x48\x63\x89\xb6\x47\xe2\x5a\xf0\x9d\x7e\xb4\x2c\xea\x33\x52\xfb\x02\x78\x88\x64\xf0\xe9\xb5\x14\xf0\x5e\xcb\xe7\xdf\xa3\xad\x72\xa2\xfc\x16\x20\x33\x5e\xa2\x84\x87\x4f\x7f\xb0\x40\x39\x31\x1c\x3c\x9a\x88\x77\x28\xd6\x2f\x90\xd3\xc8\xa3\x16\xda\x01\x2f\xb2\x5a\xf9\xac\xcb\x10\x62\x7c\xb6\xf1\x09\xe1\x29\x87\x1d\x12\x46\xd9\x06\x18\x07\x81\xbf\x55\x28\x95\x04\x22\x10\x1e\x0Line truncated
|
||||
var _templatesServerBuilderGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xcc\x3c\x5d\x6f\xdb\xb8\x96\xcf\xab\x5f\x71\xae\x71\xef\xae\x55\x38\x76\xb1\x4f\x8b\x0c\xb2\x40\x26\x99\xb9\x37\xbb\x33\x6d\xd0\x74\x76\x1f\x82\xe2\x82\x91\x8e\x6d\x6e\x65\x52\x43\x52\xc9\x64\x04\xfd\xf7\x05\x3f\x45\x7d\xd9\x8e\x9b\xce\xb4\x2f\xad\xa4\xc3\xf3\xc5\xc3\xf3\xc5\xe3\xae\x56\x70\xc5\x73\x84\x0d\x32\x14\x44\x61\x0e\x0f\xcf\xb0\xe1\x67\xf2\x89\x6c\x36\x28\xbe\x83\xeb\xf7\xf0\xee\xfd\x47\xf8\xe1\xfa\xe6\xe3\x32\x49\x92\xba\x06\xba\x86\xe5\x15\x2f\x9f\x05\xdd\x6c\x15\x9c\x35\xcd\x6a\x05\x75\x0d\x19\xdf\xed\x90\xa9\xde\xb7\xba\x06\x64\x39\x34\x4d\x92\x24\x25\xc9\x3e\x93\x0d\x42\x5d\x2f\x6f\xed\x3f\x9b\x46\x23\xfc\xab\xff\x70\x7e\x01\xfe\x8b\x59\xb1\x5a\xc1\xc7\x2d\x95\xb0\xa6\x05\xc2\x13\x91\x5d\x2e\xd5\x16\xc1\xb1\x09\x8a\xf3\x62\xa9\xe1\x7f\xc8\xa9\xa2\x6c\x03\x2a\xac\xdb\x19\x56\x4a\xc1\x1f\x11\xd6\x95\x32\xa8\xb6\xc8\xe0\x99\x57\x20\xf0\x4c\x54\xac\x83\xc9\x93\x30\xf2\x10\x96\x27\x09\xdd\x95\x5c\x28\x98\x27\x00\xb3\x8c\x33\x85\xbf\xa9\x99\xfe\xf7\x7a\x67\xff\xa6\xdc\xfc\xc5\x50\xad\xb6\x4a\x95\xe6\x41\x2a\x41\xd9\x46\xce\x12\xfd\xb0\xa1\x6a\x5b\x3d\x2c\x33\xbe\x5b\x6d\xf8\x19\x2f\x91\x91\x92\xae\x50\x08\x2e\xe4\x6c\x1a\xa0\xe0\x24\xdf\xf7\x5d\x54\x4c\xd1\x1d\x1e\x86\x58\xed\x68\x9e\x17\xf8\x44\xc4\x31\xc0\x12\xb3\x4a\x50\xf5\xbc\x07\x54\x96\x98\xed\xfb\xac\x84\xd7\xcd\x04\xc0\x13\xd9\x18\xd5\x68\x6b\x32\xda\x95\xb0\xbc\xc6\x35\xa9\x0a\x75\xe3\x9e\x9b\xa6\xf7\x3d\xfa\x90\x1a\xd3\x78\x87\x4f\x75\x0d\x25\x91\x19\x29\xe8\xef\x08\xcb\x77\x64\xa7\xed\xe6\xf2\xf6\x06\x32\x81\x44\xa1\x04\x02\x0c\x9f\x60\x14\x0c\x28\x93\x8a\xb0\x0c\x93\x75\xc5\xb2\x7d\xd8\xe6\x5a\x5e\x78\x63\xf6\x63\x79\xcd\xb3\x4a\xdb\x79\x0a\x6f\x26\xa9\xd7\x09\x80\x40\x55\x09\x06\xff\x3a\x05\xa4\x61\x00\xb6\x84\xe5\x05\x0a\x79\x0e\xdd\x3f\x3b\xf2\x19\xe7\x3b\x52\xde\x5b\x43\xfa\x14\xfd\x53\xdb\xd8\xf2\x1f\x76\x5d\xba\x30\x58\xd6\x5c\xec\x88\x1a\x20\x01\xbb\x11\x5e\xb3\x16\x36\xb7\x0f\x57\x9c\xc9\x6a\x87\xed\x9a\x59\x5d\x87\x3d\xf0\x1f\xa1\x69\x66\x9d\x55\xb7\x82\xe7\x55\x36\xb1\xca\x7f\x6c\x57\x65\x95\x54\x7c\xe7\xb0\x45\x42\xf6\xa5\x73\xa6\xb7\xf4\x90\x69\xbc\xdc\xa1\x3d\x62\xb9\x87\x74\xcb\x6f\x05\xde\xa1\x78\x44\x71\xb7\xad\x54\xce\x9f\x98\x43\xa0\xb7\x7b\x9e\x42\x0d\xd0\x58\xc0\x51\xa8\x31\x40\x6d\x07\x03\x25\xbb\xf7\x16\xa2\x92\x78\x67\x1d\xc9\x2f\x37\x31\xe4\x9a\x14\x12\x23\x6a\x3f\xe8\xc3\xdf\x45\x65\xfd\xc1\xb2\xfd\x6c\xc1\xbf\x27\x92\x66\x97\x95\xda\x22\x53\x34\x23\xca\x2f\xf3\xc7\x74\x19\x00\x2c\xfc\xe5\xed\xcd\x7f\xe3\xf3\x70\x41\x80\x6f\x01\x1c\x01\x24\x02\xc5\x9e\x05\x2d\x80\x5d\x50\xd7\x20\x08\xdb\x20\x2c\x23\x3b\x49\xac\x10\x75\x7d\x66\xe2\xc3\xcd\xae\x2c\x50\x1f\x13\xa2\x28\x67\xed\x77\x18\x3f\x8b\x7e\xe3\xcf\xf5\xe7\xe1\xe2\x45\x84\x1d\x0b\x89\x2f\xc0\xd7\x37\xad\x1f\xf5\x9e\x9a\x8d\x15\x40\xf9\xf2\x03\x92\x1c\xc5\x02\x14\x11\x1b\x54\x40\x99\x42\xb1\x26\x19\xd6\x4d\x6a\x37\x04\xea\xa4\xdd\x22\x77\xa6\xdd\x4e\xbd\xe3\x2a\x70\x8a\xf9\x7c\x56\xd7\x86\x7c\xd3\x40\xe6\x88\xc1\x96\x48\x60\x5c\xc1\x33\x2a\x78\x40\x64\xda\x9b\xf9\x05\xb3\x34\x60\x6e\xd2\x8e\x84\x36\x5e\x8e\x3e\x7a\xcd\x47\x67\xed\xcb\x34\xef\xcf\xcc\x6b\x69\xbe\xc5\xd7\x3f\x95\xad\xe6\x9f\xb4\xe6\xff\x57\x50\xa5\x35\x9f\x13\x45\x5e\x4b\xef\xa5\x23\xf5\xf5\xf4\xfe\xbe\xd4\xc9\x01\xe5\xac\xa3\x79\xad\x78\x86\x6d\xee\x12\x12\x1a\x93\xff\x44\x4a\xba\x8d\xdf\x5b\x02\xa3\x5a\x74\xee\xfd\x3c\xd2\xf5\xd9\x7e\x22\xfe\xf5\x65\x41\x89\xe6\x6d\x79\x14\x81\x76\x4f\x4a\x22\xc8\x4e\x1e\x94\x65\x84\x4c\x4f\x6d\x74\x0d\x7f\x5d\xfe\x1d\xd9\xfb\x52\xc9\xe5\x9d\x12\x34\x53\x1f\x50\x96\x9c\xe5\x28\x64\xc7\x7a\xce\xc6\xcc\xc7\xb0\x51\xd7\xda\x92\xb5\xc7\xe1\x82\xfe\x8e\x79\xd3\x2c\xa0\x14\x94\x65\xb4\x24\x05\xd8\xaf\xb7\xfe\xf9\x46\xbe\xab\x8a\x82\x3c\x14\x7a\xfd\x9b\x48\xec\x16\x44\x3f\x21\xcb\x9b\x26\xb5\x8b\x0f\xcb\x77\x58\x83\x41\xa8\x60\xa9\xce\x4a\x5f\x8d\x42\xcf\xce\x53\xa7\x62\x7d\x0c\xff\x7c\x3d\xb6\x29\xe5\x72\x52\x13\x11\x4c\xff\xcc\x72\x7f\x8e\x8e\xb6\xb8\x9e\xbe\x7a\x22\x37\xcd\x31\x67\xde\xad\x3f\x73\xea\xf3\xc7\x7f\xf2\xb4\xdf\xb9\x10\x78\x8d\x6b\xca\xe8\xe0\xd8\x3b\x87\x2b\x43\x04\x6e\x3f\xae\x56\x70\x59\x96\x05\x45\x69\x8b\x0d\x5d\x61\xf8\x7d\xb0\x72\x6f\x4d\xe4\x01\x2a\x41\xa2\x82\x27\xaa\xb6\x06\xc8\xe0\x02\x99\x6d\x71\x87\xc9\xd0\xcb\xde\x5c\xeb\xec\xb1\x52\xdb\x73\x9b\x9d\x54\x12\x05\xd8\x34\x68\xa1\xe1\xa4\x7b\x48\x61\x7e\xca\xf6\x2e\xac\x8f\x4d\xfb\x3b\xc9\x68\xb1\x98\x72\xbf\x0f\x86\x63\xa2\xc5\xd7\x44\x1d\x8f\xe9\x31\xfb\xd1\x4c\xb8\xdf\x58\xb9\x6d\xba\xb2\x5f\xbb\x26\x13\x75\xd6\x3f\x33\xc1\xec\x8e\x57\x22\xb3\x99\xbe\x51\xf2\x11\xea\x54\xfc\x33\xb2\x3f\x5e\x85\xa4\xa4\xf0\x19\x9f\xad\x12\x63\x1d\xb6\xa1\x6d\x2d\xf8\x4e\x3f\x5a\xa1\x74\xac\xd3\x27\x1c\xee\x23\xa9\x3f\xbd\x96\xca\xdf\x6b\x8d\xfc\x7b\x74\x1c\x8e\xd4\xd8\x02\x64\xc6\x4b\x94\x70\xff\xe9\x0f\x57\x21\x27\x86\xe7\x07\x93\xab\x0e\x15\xf9\x05\x9a\x19\x79\xd4\x22\xed\xf1\x0d\xab\x95\xaf\x97\x0c\x23\xc6\xf7\x9a\x93\x1e\x9e\x72\xd8\x21\x61\x94\x6d\x80\x71\x10\xf8\x6b\x85\x52\x49\x20\x02\xe1\xa1\xe0\xd9\x67\xcc\x7d\x2Line truncated
|
||||
|
||||
func templatesServerBuilderGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -622,12 +648,12 @@ func templatesServerBuilderGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/server/builder.gotmpl", size: 18967, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xcd, 0x9, 0x7f, 0x2a, 0x86, 0xd5, 0x9a, 0x75, 0x25, 0x2d, 0x98, 0xc0, 0xc2, 0xb3, 0x1, 0xf3, 0x73, 0xa6, 0xe1, 0x1b, 0x6f, 0x95, 0x62, 0xb, 0xb6, 0x3f, 0xe3, 0x6d, 0x3c, 0x4d, 0x3a, 0x5b}}
|
||||
info := bindataFileInfo{name: "templates/server/builder.gotmpl", size: 18855, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x58, 0x21, 0x57, 0xdd, 0x44, 0xf7, 0xbf, 0xcd, 0x95, 0xdc, 0x7d, 0x5f, 0xc3, 0xd0, 0x35, 0xea, 0x13, 0x62, 0x19, 0xb2, 0xf5, 0xab, 0xba, 0xf4, 0xe7, 0x6f, 0xa4, 0xde, 0xa4, 0x17, 0x2f, 0xa7}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesServerConfigureapiGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xc4\x58\x4b\x93\xdb\xb8\x11\x3e\x47\xbf\xa2\x4b\xb5\x07\xc9\x25\x51\x55\x39\xba\x6a\x0e\x13\xdb\xeb\x55\xc5\x5e\xab\xac\x71\x72\xd8\xda\x03\x44\xb6\x24\x64\x40\x00\x01\x40\xcf\x68\x59\xfc\xef\xa9\x6e\x80\x14\x25\x51\x33\xb3\x99\x4d\xf6\x44\xe2\xd5\x8f\xaf\x1f\xe8\xc6\x62\x01\x77\x7b\xe9\x61\x2b\x15\x82\xf4\xe0\xc5\x16\x21\x18\xc0\x42\x86\x0c\xbe\xe8\x1c\x41\x06\xc0\x47\xe9\x83\xa7\xbf\x07\xa9\x14\x68\x13\x60\x83\x60\xbe\xa3\x7b\x70\x32\x04\xd4\xa3\x51\x5d\x83\xdc\x42\xf6\xce\xd8\x83\x93\xbb\x7d\x80\x79\xd3\x2c\x16\x50\xd7\x90\x9b\xb2\x44\x1d\xce\xd6\xea\x1a\x50\x17\xd0\x34\xa3\xd1\xc8\x8a\xfc\x5e\xec\x90\x36\x67\xb7\xab\xe5\x2a\x0d\x69\x4d\x96\xd6\xb8\x00\x93\x11\xc0\x38\x37\x3a\xe0\x63\x18\xf3\xbf\x3b\xd8\x60\x16\x41\x79\x1e\x4a\xc3\x1f\x65\x76\xfc\xd5\x18\x16\xfb\x10\xec\x78\x44\xa3\x9d\x0c\xfb\x6a\x93\xe5\xa6\x5c\xec\xcc\xdc\x58\xd4\xc2\xca\x05\x3a\x67\x5c\x3c\x3d\xbc\xc1\x55\x3a\xc8\x12\x9f\xdf\xb1\x28\x65\x51\x28\x7c\x10\xee\x25\x9b\x3d\xe6\x95\x93\xe1\xc0\xb2\x11\x6a\xac\xa1\x87\xec\x3d\x6e\x45\xa5\xc2\x32\x8d\x9b\xe6\x6c\xbd\xb7\x30\x65\xbc\x1f\x64\xd8\x43\xf6\x11\xf5\x17\x1b\xa7\x17\x8b\x9d\x79\xbb\x43\x8d\x4e\x04\x04\xff\x20\x76\x3b\x74\x70\x9c\x40\xf7\x1d\x1d\xcc\xe7\x41\xb8\x1d\x06\x86\xfb\x8e\x7f\x57\x22\xec\xa1\x69\x60\x3e\xd7\xa2\x8c\x76\xf8\x99\x7e\x78\xca\x5b\xcc\x79\x6a\x6d\x31\x4f\x3b\x47\x75\x3d\x67\x7b\x9f\x98\x2b\xfa\x80\xc6\x93\xe9\xb1\xb1\xc4\x5e\x1a\xed\xc7\x91\xa0\xb0\x72\x7e\xd5\xe4\x9d\x5f\x1c\x1d\xa4\xe5\xf5\xd9\x14\xa8\x86\xb8\x9d\x2c\x8c\x4b\x1a\xb5\xbc\x78\x70\xc2\xed\x92\xca\x35\x7e\x6b\xc6\x6b\x88\xe1\xe9\xca\xd8\xa1\x0f\xc2\xca\x71\x84\x8b\xd7\x4e\x58\x0e\x10\xba\xc6\xf3\x9d\x92\xa8\xc3\x10\xcf\xd3\x95\x71\xce\xc3\xa4\x65\x1c\x9c\xf0\x1c\x20\x74\x8d\xe7\x1d\x96\x56\x89\x80\xef\xa5\x8b\xe4\x42\x9a\x98\x17\xd2\x45\x2f\x39\xd9\x71\x4a\xc1\x09\xbd\x43\xc8\xbe\x74\x56\x8e\x34\x3a\xab\x33\x81\x6b\xa7\xee\xc4\x2e\xed\x0f\xf4\x37\xb8\x95\x44\x5c\x39\xa9\x73\x69\x85\x8a\x9b\x6d\x37\xa4\x13\xfd\xc5\xcb\xa3\x29\xac\xd6\xf9\x1e\xcb\x53\x44\x4f\x57\xc6\x9c\x30\x22\xfd\x22\xae\xcc\x7d\x5c\x22\x26\x03\x64\x86\xf0\x4c\x7a\xb1\x93\xf9\x9e\x0b\x5e\x55\xcd\x38\x98\x50\x3e\xcd\x96\x3a\x57\x55\x81\x7c\x72\x7a\x3a\xf7\x0f\xa1\x64\x21\x82\x71\xd3\x14\x91\xf7\xd2\x46\xb2\xfe\x59\x7a\x3f\x09\x5d\x28\x74\x67\x14\x57\xc2\x89\x12\x03\x3a\x0f\x67\x2b\x5f\xd1\x5b\xa3\x3d\xfa\x3e\xaf\x63\x08\x5f\xf0\xeb\x9f\x5d\x57\x96\xb3\xf5\xf1\xa0\x8f\x33\x4f\x9e\xfa\x2c\xa4\x8e\x47\xf0\x91\x27\xe6\xa5\x90\xfa\xd2\x90\x1f\xe2\x2a\x65\xa1\xd3\xed\x94\xa0\x06\xec\x5e\x95\xf6\xbd\x08\x22\x59\xb4\x2a\xed\xbc\x10\x41\x0c\x84\x79\x70\x32\x0f\x51\xef\x82\x10\x89\xe2\xf3\xec\xdc\x75\xd3\xfd\x83\xed\xdf\xb6\xd2\x39\xe4\x46\x6f\xe5\xae\x72\xf8\xa3\x12\x3b\x3f\x11\x56\xc2\x9b\xba\xce\x52\xe8\x35\x4d\x56\xd7\x60\x85\xcf\x85\x92\xbf\x61\x97\x58\x6f\x57\xcb\x29\xd4\x23\x80\xc5\x02\x84\x95\xd9\x3b\x53\x96\x42\x17\x9f\xa4\xc6\x2f\x96\xa1\xfe\xe8\x4c\x65\x3d\xdc\xc0\x2f\xbf\x52\x2a\xbf\xb6\xa3\x86\x2c\xcb\xa0\x19\x35\xa3\x33\x71\x6e\x57\xcb\xdf\x25\x0c\xf9\x7f\x96\xdc\xa5\x95\xac\x23\x06\x61\x8f\x24\x27\xec\xd1\xe1\x08\x58\x64\x4e\x6b\x1f\xe8\x1a\x85\x1b\x88\xd7\x69\x6f\x6e\x14\x29\xac\x31\xc0\xc1\x54\x0e\xf2\xca\x07\x53\x82\x32\x7c\x29\x71\x08\x62\x81\x45\x06\x29\xb2\xc0\x68\xae\x40\x94\xd9\x71\x44\x87\x6d\x24\xf0\xe1\xd1\x62\x1e\xb0\x00\xa9\x03\xba\xad\xc8\x11\x48\xcf\x09\x19\x48\xef\x66\xa4\x7d\xb7\x52\x37\x53\x3e\xd4\x9e\x14\xa5\x55\xf8\xf6\x08\xf2\xa7\xc8\xfc\xa6\xcf\x24\x29\xf3\xcd\xe3\x3a\x5e\x98\xdf\x96\x93\x48\x05\xee\x0c\x01\x10\xa4\xae\x10\x2a\x2f\xf5\x0e\x1c\x16\x26\x07\xe1\xa3\x4a\xdf\x96\x33\xa8\x74\x5b\xdf\x10\x42\x5b\xa3\x94\x79\xa0\x9d\x4a\x6a\x3c\x32\xfe\xe6\xf1\x2b\x1d\x9d\x4c\xd3\xad\x9f\xf2\xc4\x3b\xa3\x7d\x55\x62\xba\xed\x69\x25\xfa\xe4\x92\x04\x27\xaa\x31\x85\xf2\x2a\xd1\x19\xb4\x5e\x22\x42\x7a\x51\x96\x19\x3a\x1b\x29\xa3\xf2\xf8\x72\x5a\xa9\x60\x69\x65\x74\x3f\x12\xea\x0c\xbd\x03\x69\xb2\xaf\x28\x0a\x74\x33\x48\xc5\x44\xdf\x06\xd1\x19\xd8\x87\x00\x1c\x86\xca\xe9\xd6\x3f\x7e\x36\xa1\x93\x0f\x8b\xc9\xb8\xae\x99\x73\xd3\x10\xd2\x91\xf3\x5e\x78\xce\x0f\x07\xa4\x2a\x13\x35\x55\x40\xed\x81\x31\x59\x86\x8d\x9c\x34\x8a\x71\x78\x31\x68\xf1\x5d\x39\x53\x54\xf9\x2b\xf1\x4d\x44\xfe\x10\x7c\x7b\xb4\x5a\x7c\xdb\xa9\x23\xbe\x0f\x84\xef\x3f\x9d\x0c\x84\x2f\x25\xad\xd7\xa3\x6b\x5b\xbe\xaf\x41\xf7\x0c\xdc\x75\xaa\x64\xdf\xe3\x56\x6a\xd9\xde\xfd\xa7\x38\xfb\xbf\x09\x2f\xf3\xdb\x2a\x56\x8d\x1c\x0f\xb7\xd6\x2a\x89\x1e\x1e\xf6\xa8\x39\x68\x68\xd5\x38\xf9\x5b\xc4\x73\xcf\x7e\xc5\xbd\x08\x86\x58\xe3\xd2\x26\xa6\x03\xf1\x42\x1e\x01\x11\xbf\xc4\x78\xf9\x9e\x72\x19\xf1\xba\xb9\x01\x2d\x55\xc2\xe8\xc9\x8d\x31\x99\x54\x1e\x1d\xb4\x19\xc5\x0a\xef\xd3\x60\x0a\x93\xba\x4e\xf7\xd5\x04\xf0\xdf\xfd\x62\x63\xdc\x33\xca\x18\xa6\x4d\xf3\xa6\x57\x13\x1c\xf7\x35\xcd\x2c\x9a\x67\x9a\xc4\xe9\x8c\xa6\xa5\x9a\x5d\xb3\xdc\x86\xd5\x15\x24\x22\x89\x90\x44\x9e\x3e\x6f\x3e\x00\x82\xf9\xcc\x27\xa3\x29\x6e\x57\xcb\xbf\xe3\xe1\x69\x5b\x8c\x7b\xb5\xff\x38\x16\xaf\xa6\x72\xLine truncated
|
||||
var _templatesServerConfigureapiGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xc4\x59\x4b\x8f\x1b\xb9\x11\x3e\x47\xbf\xa2\x20\xec\x41\x32\xa4\x56\xe0\xbd\x19\x3b\x87\x59\x3f\x85\x78\x6c\xc1\x1a\x27\x08\x16\x7b\xa0\xba\x4b\x12\x63\x36\x49\x90\x6c\xcf\x68\x1b\xfd\xdf\x83\x22\xd9\x4f\xb5\x66\xc6\x3b\x8b\xe4\xa4\x26\x59\xac\xc7\x57\xc5\xaa\x22\xb5\x5a\xc1\xed\x91\x5b\xd8\x73\x81\xc0\x2d\x58\xb6\x47\x70\x0a\x30\xe3\x2e\x81\xcf\x32\x45\xe0\x0e\xf0\x9e\x5b\x67\xe9\xeb\x8e\x0b\x01\x52\x39\xd8\x21\xa8\xef\x68\xee\x0c\x77\x0e\xe5\x64\x52\x96\xc0\xf7\x90\xbc\x56\xfa\x64\xf8\xe1\xe8\x60\x59\x55\xab\x15\x94\x25\xa4\x2a\xcf\x51\xba\xc1\x5a\x59\x02\xca\x0c\xaa\x6a\x32\x99\x68\x96\x7e\x63\x07\x24\xe2\xe4\x7a\xb3\xde\xc4\x21\xad\xf1\x5c\x2b\xe3\x60\x36\x01\x98\xa6\x4a\x3a\xbc\x77\x53\xff\x6d\x4e\xda\xa9\x95\x13\xd6\x0f\xb9\xf2\x3f\x42\x1d\xfc\xaf\x44\xb7\x3a\x3a\xa7\xa7\x13\x1a\x1d\xb8\x3b\x16\xbb\x24\x55\xf9\xea\xa0\x96\x4a\xa3\x64\x9a\xaf\xd0\x18\x65\xc2\xee\x71\x02\x53\x48\xc7\x73\x7c\x9c\x62\x95\xf3\x2c\x13\x78\xc7\xcc\x53\x88\x2d\xa6\x85\xe1\xee\xe4\x75\x23\xd4\xbc\x85\x16\x92\x37\xb8\x67\x85\x70\xeb\x38\xae\xaa\xc1\x7a\x67\x61\xee\xf1\xbe\xe3\xee\x08\xc9\x7b\x94\x9f\x75\x98\x5e\xad\x0e\xea\xd5\x01\x25\x1a\xe6\x10\xec\x1d\x3b\x1c\xd0\x40\x3b\x81\xe6\x3b\x1a\x58\x2e\x1d\x33\x07\x74\x1e\xee\x5b\xff\xb9\x61\xee\x08\x55\x05\xcb\xa5\x64\x79\xf0\xc3\x27\xfa\xf0\x53\x56\x63\xea\xa7\xb6\x1a\xd3\x48\x39\x29\xcb\xa5\xf7\x77\xcf\x5d\x21\x06\x24\xf6\xa6\xa7\x4a\x93\x78\xae\xa4\x9d\x06\x86\x4c\xf3\xe5\x45\x97\x37\x71\xd1\x06\x48\x2d\xeb\x46\x65\x28\xc6\xa4\xf5\x16\xa6\x39\x8d\x6a\x59\x7e\xd0\x93\x76\xce\xe5\x92\xbc\xad\xc7\x6b\x4c\x60\x7f\x65\x6a\xd0\x3a\xa6\xf9\x34\xc0\xe5\xd7\x7a\x22\x47\x18\x5d\x92\xf9\x5a\x70\x94\x6e\x4c\x66\x7f\x65\x9a\xfa\x61\xb4\x32\x0c\x7a\x32\x47\x18\x5d\x92\x79\x8b\xb9\x16\xcc\xe1\x1b\x6e\x02\x3b\x17\x27\x96\x19\x37\x21\x4a\x7a\x14\x7d\x0e\x86\xc9\x03\x42\xf2\xb9\xf1\x72\xe0\xd1\x78\xdd\x33\xb8\xb4\xeb\x96\x1d\x22\xbd\xa3\xaf\x51\x52\x52\x71\x63\xb8\x4c\xb9\x66\x22\x10\xeb\x66\x48\x3b\xba\x8b\xe7\x5b\xe3\xb1\xda\xa6\x47\xcc\xfb\x88\xf6\x57\xa6\x3e\x61\x04\xfe\x59\x58\x59\xda\xb0\x44\x42\x46\xd8\x8c\xe1\x19\xed\xf2\x41\x66\x3b\x21\x78\xd1\x34\x65\x60\x46\xf9\x34\x59\xcb\x54\x14\x19\xfa\x9d\xf3\xfe\xdc\x3f\x99\xe0\x19\x73\xca\xcc\xe3\x89\xfc\xc6\x75\x60\x6b\x1f\xe5\xf7\x81\xc9\x4c\xa0\x19\x70\xdc\x30\xc3\x72\x74\x68\x2c\x0c\x56\xbe\xa0\xd5\x4a\x5a\xb4\x5d\x59\xed\x11\x3e\x93\xd7\xdd\xbb\x2d\xb4\xcf\xd6\xed\x46\x1b\x66\x1e\xdc\x75\xc3\xb8\x0c\x5b\xf0\xde\x4f\x2c\x73\xc6\xe5\xb9\x23\xdf\x86\x55\xca\x42\x7d\x72\x4a\x50\x23\x7e\x2f\x72\xfd\x86\x39\x16\x3d\x5a\xe4\x7a\x99\x31\xc7\x46\x8e\xb9\x33\x3c\x75\xc1\xee\x8c\x10\x09\xea\xfb\xd9\xa5\x69\xa6\xbb\x1b\xeb\xaf\x7d\x21\x53\x48\x95\xdc\xf3\x43\x61\xf0\x9d\x60\x07\x3b\x63\x9a\xc3\x8b\xb2\xec\x64\xb5\x6b\xc1\x99\xad\xaa\xa4\x2c\x41\x33\x9b\x32\xc1\xff\xc0\x26\xc1\x5e\x6f\xd6\x73\x28\x27\x00\xab\x15\x30\xcd\x93\xd7\x2a\xcf\x99\xcc\x3e\x72\x89\x9f\xb5\x87\xfc\xbd\x51\x85\xb6\x70\x05\xbf\xfd\x4e\x29\xfd\x12\x45\x09\x49\x92\x40\x35\xa9\x26\x03\xb5\xae\x37\xeb\x3f\xa5\x14\x9d\x87\x24\x86\x4f\xad\x61\xc3\x14\xdc\x11\x49\x5f\x38\xa2\xc1\x09\x78\xd5\x7d\x9a\x7b\x4b\x65\x15\xae\x20\x94\xd7\xce\xdc\x24\x70\xd8\xa2\x83\x93\x2a\x0c\xa4\x85\x75\x2a\x07\xa1\x7c\x91\xf2\x47\x12\x33\xcc\x12\x88\x27\x0d\x94\xf4\x1d\x89\x50\x07\x7f\xc2\xdd\x3e\x30\x78\x7b\xaf\x31\x75\x98\x01\x97\x0e\xcd\x9e\xa5\x08\x64\xef\x8c\x1c\x26\x0f\x0b\x42\xa1\x59\x29\xab\xb9\xdf\x54\xef\x64\xb9\x16\xf8\xaa\x05\xfb\x63\x10\x7e\xd5\x15\x12\x8d\xf9\x6a\x71\x1b\x0a\xe8\xd7\xf5\x2c\x70\x81\x5b\x45\x00\x38\x2e\x0b\x84\xc2\x72\x79\x00\x83\x99\x4a\x81\xd9\x60\xd2\xd7\xf5\x02\x0a\x59\xf7\x3b\x84\xd0\x5e\x09\xa1\xee\x88\x52\x70\x89\xad\xe0\xaf\x16\xbf\xd0\xd6\xd9\x3c\x76\x01\x31\x6f\xbc\x56\xd2\x16\x39\xc6\xea\x4f\x2b\x21\x46\xd7\xa4\x38\x71\x0d\x29\xd5\xaf\x12\x9f\x51\xef\x45\x26\x64\x17\x65\x9d\xb1\xbd\x81\x33\x0a\x8b\x4f\xe7\x15\x1b\x98\x5a\x47\xf3\x8e\x50\xf7\xd0\x1b\xe0\x2a\xf9\x82\x2c\x43\xb3\x80\xd8\x5c\x74\x7d\x10\x82\xc1\xc7\x10\x80\x41\x57\x18\x59\xc7\xc7\x27\xe5\x1a\xfd\x30\x9b\x4d\xcb\xd2\x4b\xae\x2a\x42\x3a\x48\x3e\x32\xeb\xf3\xc5\x09\xa9\xeb\x44\x49\x1d\x51\xbd\x61\x4a\x9e\xf1\x4e\x8e\x16\x85\x73\x79\x36\xa8\xf1\xdd\x18\x95\x15\xe9\x33\xf1\x8d\x4c\xfe\x12\x7c\x3b\xbc\x6a\x7c\xeb\xa9\x16\xdf\x3b\xc2\xf7\x5f\x86\x3b\xc2\x97\x92\xd8\xf3\xd1\xd5\xb5\xdc\xe7\xa0\x3b\x00\x77\x1b\x3b\xdb\x37\xb8\xe7\x92\xd7\xbd\x40\x1f\x67\xfb\x2b\xb3\x3c\xbd\x2e\x42\x17\xe9\xcf\xc3\xb5\xd6\x82\xa3\x85\xbb\x23\x4a\x7f\x68\x68\x55\x19\xfe\x47\xc0\xf3\xe8\xe3\xca\xdf\x4d\xd0\x85\x9e\x97\x88\x3c\x1f\x08\x05\x7a\x02\xc4\xfc\x1c\xe3\xf5\x1b\xca\x65\x24\xeb\xea\x0a\x24\x17\x1e\xa3\x07\xc9\x42\x2a\x29\x2c\x1a\xa8\xf3\x89\x66\xd6\xc6\xc1\x1c\x66\xf1\x9a\xd3\xb4\x1c\x6b\xfb\xa9\x10\x82\xed\x04\x39\xf3\x45\xa7\x29\x68\x49\xaa\x6a\x11\xfc\x31\x8f\x3e\x6a\xbc\x24\xb9\x58\x5c\x72\xd5\xce\xdb\xc7\x48\x2b\x2f\x35\x68\x39\x7f\xdc\x5f\x00\x84\xeb\x20\x08\x03\xf6\xd7\x9b\xf5\x3f\xf0\xf4\x30\xf8\xd3\x4e\xf3\x3f\x0d\xdd\xab\x2a\x4c\xLine truncated
|
||||
|
||||
func templatesServerConfigureapiGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -642,8 +668,8 @@ func templatesServerConfigureapiGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/server/configureapi.gotmpl", size: 6786, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x80, 0x9, 0x27, 0xe2, 0x95, 0x78, 0x35, 0xb1, 0x73, 0x83, 0xa2, 0xd, 0x6e, 0x5, 0x7d, 0x1e, 0xbf, 0xbd, 0x6b, 0xa5, 0x4b, 0xd5, 0xf2, 0x6a, 0x86, 0x1b, 0xa3, 0xa5, 0x56, 0x85, 0x2e, 0x5d}}
|
||||
info := bindataFileInfo{name: "templates/server/configureapi.gotmpl", size: 7308, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x33, 0xee, 0x9c, 0x38, 0x1d, 0x9b, 0xe0, 0x8b, 0xc3, 0xb3, 0xdf, 0xa9, 0x1f, 0x24, 0xf0, 0x42, 0xcf, 0x83, 0xa6, 0x3e, 0x6f, 0xf1, 0xff, 0x32, 0x30, 0x44, 0x1, 0xce, 0x78, 0x9c, 0xaf, 0x70}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
@@ -667,7 +693,7 @@ func templatesServerDocGotmpl() (*asset, error) {
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesServerMainGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x57\x4d\x6f\xe3\x36\x13\x3e\x8b\xbf\x62\x56\xc0\x0b\x48\xfb\x3a\x52\x17\xbd\x65\xe1\x43\x90\x8f\xad\x8b\x6c\x1c\xc0\xd9\x43\xd1\x2d\x16\x8c\x38\x92\xd9\xd0\xa4\x4a\x52\xf1\xa6\x86\xfe\x7b\x41\x8a\xb6\xe5\x8f\xa4\x2e\x82\xa0\x8b\x6e\x2e\x71\xc4\x19\x0e\x87\xcf\x7c\x3c\x9c\x3c\x87\x53\xc5\x10\x2a\x94\xa8\xa9\x45\x06\xb7\x0f\x50\xa9\x23\x33\xa7\x55\x85\xfa\x3d\x9c\x8d\xe1\x6a\x7c\x03\xe7\x67\xa3\x9b\x8c\x10\x02\x8b\x05\xf0\x12\xb2\x53\x55\x3f\x68\x5e\x4d\x2d\x1c\xb5\x6d\x9e\xbb\xe5\x42\xcd\x66\x28\xed\x96\x6c\xb1\x00\x94\x0c\xda\x96\x10\x52\xd3\xe2\x8e\x56\x08\x33\xca\x25\x21\x7c\x56\x2b\x6d\x21\x21\x00\x71\x39\xb3\xb1\xfb\x15\xaa\xf2\xbf\x12\x6d\x3e\xb5\xb6\xf6\x1f\xca\xc4\xc4\xfd\x56\xdc\x4e\x9b\xdb\xac\x50\xb3\xbc\x52\x47\xaa\x46\x49\x6b\x9e\x0b\x45\x99\x89\x49\x14\x1c\xfb\x64\xf0\x83\x9a\x58\xdd\x14\xf6\x42\xd0\xca\x40\xdb\x96\xfe\xb7\xbf\xfd\x77\x34\x06\xef\xd9\x9d\xb3\xe3\xa5\xee\x9c\xe0\xe9\x51\xdb\x76\x1f\xc1\xda\x75\xdf\xcc\x86\x15\x53\x97\xef\x7e\xcc\x6b\xb7\xfe\xc4\xfe\xe5\xf6\x78\x8f\x5e\x50\xf4\x40\x18\xc8\xce\xb0\xa4\x8d\xb0\xa3\xf0\xbd\x32\xb4\x94\xf7\x04\x29\x21\x79\x0e\x37\x53\x6e\xa0\xe4\x02\x61\x4e\xcd\x66\x0c\xed\x14\x21\x04\x11\xac\x52\x22\x73\xfa\x1f\xe9\x1d\x82\x69\x34\x82\x54\x16\xac\x02\x75\x8f\x7a\xae\xb9\x45\xb0\x2b\x53\xb4\xb4\xa8\xe1\x41\x35\x3d\x83\xdc\xc2\x2d\x16\xb4\x31\x08\x54\x08\x27\xd4\x80\x8c\x5b\x03\x73\xd5\x08\x06\xb7\x08\x42\x19\xfb\x86\x84\x7b\x9f\x7f\x2d\x44\xc3\x70\x52\x63\xe1\xbc\x2d\x1b\x59\x00\x97\xdc\x26\x29\x2c\x08\x80\x8f\x59\x76\xc2\xd8\xa5\xa2\x0c\x75\x52\xce\xac\xc9\x7e\x39\xf9\x78\xf9\x91\xda\x62\x8a\x7a\x00\xab\x95\x33\x55\xa4\xa4\x25\xbd\x34\xf2\xc6\x5c\x0a\x05\x63\x7b\x42\x45\x00\xdc\xfa\x91\x13\xb8\x9b\x6e\xfb\x03\x4b\x68\xdc\xc2\x00\x50\x6b\x38\x1e\x06\xaf\xce\x67\xb7\xc8\x18\xb2\x64\xb1\x80\xec\xe4\x7a\x74\x1d\x92\xb6\x6d\xb3\x49\xb7\xe9\xe7\xc9\xf8\x6a\x00\xbb\xe2\x0b\x41\x6d\x4f\x25\x25\xe0\xce\x77\xc6\xdf\x0c\x41\x72\xe1\xbd\x75\x97\xaf\xb2\x0b\x6a\xa9\x10\x32\x41\xad\x9d\xda\xda\xe1\xe5\x25\x01\xee\xa9\x06\x83\xfa\x1e\x35\xbc\xdd\xe3\x4a\x27\xc9\x73\x98\xad\x62\xea\x00\x06\x6e\xa0\xa0\x42\x20\x23\x24\x72\x19\x97\x7d\x32\x6e\xcb\x10\x1c\x6c\x01\x31\x70\xf0\x66\x17\xb5\xe6\xd2\x26\xca\x64\x13\xcb\x50\xeb\x01\xc4\x5e\xf7\xf8\xb3\x8c\x53\x12\x45\x8f\xe8\x78\xc0\x19\x35\x53\xd4\xfc\x4f\x84\xec\x8a\xce\x9c\x47\x47\xc1\xd7\x5f\xc7\xd7\x37\xa3\xf1\xd5\xe4\xb7\xcf\xd2\xdb\xf1\xc7\x59\x6e\x05\x3a\x88\x43\xac\x46\xb2\x54\xe0\x7b\xc3\xf2\x2b\xbb\xf1\x2a\x7e\xcd\x9f\x59\x42\xfc\xbf\x3f\xe2\x5d\x21\x0a\x83\xeb\xad\x9b\x71\x8d\xe3\xb5\x42\x2f\xc0\x99\xfb\x93\xa4\x3d\x53\xab\x6c\xda\xf8\xe7\x05\x2c\xb7\xed\xa3\x40\x7a\x4c\xfe\x1f\x07\x98\xa2\x88\xa1\x29\x9e\x86\xe8\x0c\x4d\xa1\x79\x6d\xb9\x92\x8f\x01\xb5\xa3\xf2\xdc\x4b\xf5\x0c\xbe\x08\x68\x8f\xdb\x0f\x55\xcc\x4b\xf0\xc8\xbc\x19\x42\x1c\xc3\x82\x44\x7d\x3c\xcb\x3e\xa0\x4e\xad\x87\xe7\x26\xf2\x42\xf6\x55\x7d\x61\x9c\xaa\xd9\x8c\x4a\x76\xc9\x25\xba\xd2\xad\x7c\xf2\x9b\x24\x4d\x89\xdb\x9b\xe7\x50\x53\x6d\xd0\x37\xd2\xd3\xcb\x91\xdf\x63\x42\x4d\x5d\x3b\x49\x92\xf6\xdb\xcc\x76\x8b\x71\x3d\xa6\xab\x88\xe1\x9e\x56\x71\x85\xf3\xae\x82\x13\xc9\x45\xfa\x64\x3f\xf2\x68\x19\xab\xb9\xac\x92\xce\xa2\x5f\x4a\xff\x61\x7b\xa1\x35\xef\xb2\x2b\x0b\x6e\x74\x5e\xb8\x2c\xa2\xa6\xa0\xa2\x5f\xcb\x27\xd7\xa3\xa4\xe7\x50\xba\xba\x4b\x36\x41\xeb\x84\xb4\xe6\xeb\xcb\x87\x08\x13\x02\xd1\xb3\x0e\x71\x90\x57\x68\x97\xb0\xcd\xb9\x9d\x7a\xd0\xe1\x9e\x8a\x06\x3d\x39\x09\x64\xa0\x1a\x4b\xa2\x83\xa0\xdd\xf4\xb2\x6b\xac\x11\xc3\x12\xf5\xea\x3a\xd3\xc6\x32\x35\x97\x49\x4a\x96\x36\xb3\x53\x25\x4b\x5e\x35\x1a\x9d\x83\x29\x89\x02\xc6\xc7\xc3\x35\x06\xfa\x1e\x93\xf4\xfd\x26\xf4\x51\xb4\x03\xbc\x4b\xa3\x35\x6f\xf5\x89\x6a\xe3\x85\xb2\x49\x57\x7b\xa8\xaa\xbb\xeb\xf1\x41\x79\xb4\x19\x92\x6f\x8f\xe7\x9e\x9b\x89\xd1\x61\x68\x84\xd0\x3f\x16\xec\x5d\xb6\xf5\xb5\xee\xcd\xfa\x3a\x77\xa6\x7c\x91\xeb\x50\x73\x83\xb0\x1e\x9e\x68\xe9\x6a\x4b\x36\x99\x2a\x6d\xfb\x7d\xf7\xbb\x64\xb9\x15\x1c\x97\x4a\x56\x87\xa2\xf1\xdd\x11\xda\x01\xef\xd2\xad\x26\xe4\x3b\x84\xcf\xd8\x52\x69\xf8\x32\x00\x55\x5b\xf3\x41\xab\xa6\x76\xb9\xaa\xa9\xac\xd0\x15\x54\x9f\xcc\xc6\xfe\xf0\x4e\xc9\x84\x5a\xfc\xb2\x2a\xfe\x10\xa6\x13\xc6\xbc\x42\xb2\xb2\xb7\x93\xc8\xbd\xb3\xb6\xa3\xda\x17\x85\xe3\xd2\x25\x5b\xef\xf4\x81\xbd\x9d\xa0\x23\xa5\xdd\x77\xaf\x6b\xb7\x3b\xce\x06\xba\xdd\xe9\xb8\x85\x9b\x5c\x8f\x87\xf0\x8e\x44\x6e\x5f\x89\x03\x50\x77\x6e\x01\xb5\xce\x92\xb7\x5d\xc5\x9e\x6b\xad\x74\xfa\xde\x49\xfc\xeb\xc1\x2b\x66\x37\x0f\x35\xc2\x70\x59\xed\xe7\x5a\xff\x84\xa2\xee\x14\x3a\xb3\x43\xf8\xc1\x7d\xb4\xe1\x25\xa1\x4c\x76\xfe\x95\xdb\xc4\xc9\x7c\x67\x7f\xba\x65\xbf\x2c\x9b\xbf\x10\x9d\x1f\xde\x2d\xf7\x53\xe5\xfa\x0a\x7f\x47\x96\x4f\xbc\x53\xf6\x13\xe6\x1e\xa2\xdc\x57\x3f\xdf\x20\xe1\x6d\x81\xf7\x3a\xd7\xfd\x57\x18\xef\x75\xae\xfb\x17\xe7\xba\xed\xf9\x6d\x82\x76\xdc\xd8\xba\xe9\x45\xa2\xeb\x5b\xdd\xb8\xe6\x6c\x86\x97\x9b\x23\xd3\x83\xe7\xbb\xd7\x01\x6f\x63\x9a\x78\x9d\xef\xb6\xe7\xbb\x3e\x5f\xb5\xe4\xaf\x00\x00\x00\xLine truncated
|
||||
var _templatesServerMainGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x57\x5b\x6f\xdb\x36\x14\x7e\x36\x7f\xc5\xa9\x80\x01\x52\xe7\x48\x2b\xf6\x96\xc2\x0f\x41\x2e\x9d\x87\x34\x0e\xe0\xf4\x61\x58\x87\x82\x91\x8e\x64\x2e\x14\xa9\x91\x54\xdc\xcc\xf0\x7f\x1f\x48\xd1\x36\x7d\x6d\x82\x35\xd8\xa5\x79\xb1\x2c\xf2\xe8\xe3\xe1\x77\x2e\x1f\x99\x65\x70\x2a\x0b\x84\x0a\x05\x2a\x6a\xb0\x80\xdb\x07\xa8\xe4\x91\x9e\xd2\xaa\x42\xf5\x16\xce\x46\x70\x35\xba\x81\xf3\xb3\xe1\x4d\x4a\x08\x81\xd9\x0c\x58\x09\xe9\xa9\x6c\x1e\x14\xab\x26\x06\x8e\xe6\xf3\x2c\xb3\xc3\xb9\xac\x6b\x14\x66\x63\x6e\x36\x03\x14\x05\xcc\xe7\x84\x90\x86\xe6\x77\xb4\x42\xa8\x29\x13\x84\xb0\xba\x91\xca\x40\x4c\x00\xa2\xb2\x36\x91\x7d\x72\x59\xb9\xa7\x40\x93\x4d\x8c\x69\xdc\x8b\xd4\x11\xb1\xcf\x8a\x99\x49\x7b\x9b\xe6\xb2\xce\x2a\x79\x24\x1b\x14\xb4\x61\x19\x97\xb4\xd0\xd6\x6e\x36\x3b\x72\xae\x7d\xd0\xf8\x4e\x8e\x8d\x6a\x73\x73\xc1\x69\xa5\xed\xda\x00\xa5\xfb\x1b\x62\xfc\x8e\x5a\xe3\x7d\x71\x67\xc1\xdc\xec\x02\xc4\xfb\xbb\x86\x78\xbd\x01\xb5\x86\xa4\x9b\xf2\xcd\x8f\x59\x63\xc7\x0f\x61\x04\x10\xd1\x0e\x5b\xf7\x06\x1d\x2b\x1a\xd2\x33\x2c\x69\xcb\xcd\xd0\xbf\x7b\xb0\xd5\x7c\x30\x91\x10\x92\x65\x70\x33\x61\x1a\x4a\xc6\x11\xa6\x54\xaf\x07\xd4\x4c\x10\x7c\x44\xc1\x48\xc9\x53\x6b\xff\x9e\xde\x21\xe8\x56\x21\x08\x69\xc0\x48\x90\xf7\xa8\xa6\x8a\x19\x04\xb3\x84\xa2\xa5\x41\x05\x0f\xb2\x0d\x00\x99\x81\x5b\xcc\x69\xab\x11\x28\xe7\x76\x52\x01\x16\xcc\x68\x98\xca\x96\x17\x70\x8b\xc0\xa5\x36\xaf\x88\xcf\x95\xf3\xcf\x39\x6f\x0b\x1c\x37\x98\x5b\x6f\xcb\x56\xe4\xc0\x04\x33\x71\x02\x33\x02\xe0\x02\x98\x9e\x14\xc5\xa5\xa4\x05\xaa\xb8\xac\x8d\x4e\x7f\x39\x79\x7f\xf9\x9e\x9a\x7c\x82\xaa\x0f\xcb\x91\x33\x99\x27\x64\x4e\x82\x9c\x72\x60\x36\x9f\x3c\x98\x5f\x72\x23\x62\xcb\x30\xd8\x9d\x6e\xfa\x03\x0b\x6a\xec\x40\x1f\x50\x29\x38\x1e\x78\xaf\xce\xeb\x5b\x2c\x0a\x2c\xe2\xd9\x0c\xd2\x31\xaa\x7b\x54\xd7\x5d\x12\x9f\x70\x46\x2d\x7a\x3a\xee\x3e\xfe\x79\x3c\xba\xea\xc3\x7e\xb3\x0b\x4e\x4d\x60\x9a\x10\xb0\xfe\xd8\xc5\x5e\x0d\x40\x30\xee\xbc\xb7\x64\x54\xe9\x05\x35\x94\x73\x11\xa3\x52\xd6\x6c\xb5\x81\x55\xa2\xdc\x53\x05\xda\xad\x03\xaf\x0f\xb8\xd6\x59\x64\x19\xd4\xcb\x58\x5b\xe2\x81\x69\xc8\x29\xe7\x58\x10\xd2\xb3\x99\x98\x7e\xd0\xb6\x2e\x07\x60\xe9\xf4\x4c\x82\xa5\x3d\xbd\x68\x14\x13\x26\x96\x3a\x1d\x9b\x02\x95\xea\x43\xe4\x6c\x8f\x3f\x8a\x28\x21\xbd\xde\x1e\x1b\x17\x88\x82\xea\x09\x2a\xf6\x27\x42\x7a\x45\x6b\x84\xf9\xfc\xc8\xfb\xfc\xeb\xe8\xfa\x66\x38\xba\x1a\xff\xf6\x51\x38\x1c\xb7\x9c\x61\x86\xa3\xa5\xde\xc7\x70\x28\x4a\x09\xae\x81\x2c\xde\xd2\x1b\x67\xe2\xc6\xdc\x9a\x25\x44\xdf\xfd\x11\x6d\x4f\x22\xd7\xb8\xfa\x74\x3d\xde\x51\xb4\x32\x08\x02\x9f\xda\x9f\x38\x09\xa0\x96\x59\xb6\xf6\xe7\x19\x90\xe7\xf3\xbd\x44\x3a\x4e\xbe\x8f\x3c\x4d\xbd\x5e\x81\x3a\x3f\x4c\xd1\x19\xea\x5c\xb1\xc6\x30\x29\xf6\x11\xb5\x65\xf2\x77\x37\x15\x00\x3e\x0b\x69\xfb\xf1\x7d\x75\xb3\x12\x1c\x33\xaf\x06\x10\x45\x30\x23\xbd\x90\xcf\x32\x24\xd4\x9a\x05\x7c\xae\x33\xcf\x45\x68\xea\x0a\xe3\x54\xd6\x35\x15\xc5\x25\x13\x68\x4b\xb8\x72\xc9\xaf\xe3\x24\x21\xf6\xdb\x2c\x83\x86\x2a\x8d\xae\xc1\x9e\x5e\x0e\x3b\x95\xf1\x35\x75\x6d\x67\xe2\x24\x6c\x3f\x9b\xad\xc7\xf6\x9e\xae\x22\x06\x07\x5a\xc7\x15\x4e\xbb\x89\x58\x30\x9e\x1c\xec\x57\x8e\x35\x6d\x14\x13\x55\xdc\x21\xbb\xa1\xe4\x89\xed\x86\x36\xac\xcb\xb2\xf4\xe4\x7a\x18\xba\xd3\x79\x63\xb3\x8a\xea\x9c\xf2\xb0\xb6\x4f\xae\x87\x71\xe0\x58\xb2\xdc\x5b\x3a\x46\x63\x27\x69\xc3\x56\x64\xf8\x88\x93\xaf\xb5\x98\x0d\x45\x85\x66\x41\xe7\x94\x99\x49\xa7\xd3\xf7\x94\xb7\xe8\xc4\x8c\x63\x01\xb2\x35\xa4\xf7\x24\xca\xd7\xbd\xee\x1a\x70\xaf\xc0\x12\xd5\x72\x7b\x93\xd6\x14\x72\x2a\xe2\x84\x2c\xb0\xd3\x53\x29\x4a\x56\xb5\x0a\xad\xa3\x09\xe9\x79\xee\x8f\x07\x2b\x4e\xd4\x3d\xc6\xc9\xdb\xf5\x90\xf4\x7a\x5b\x01\xb1\x69\xb6\xd2\xbb\x50\xe0\xd6\x0e\x39\xeb\x32\xb7\x43\xe2\xba\x3d\x1f\x3f\x29\xcf\xd6\x43\xf5\xef\xd7\xc9\xaf\x96\x4c\x4f\x63\xcb\xa7\xc8\xbe\xa4\xd8\x56\x6f\xd7\x33\x1c\xbc\xeb\x17\x16\xca\x35\x0b\xe5\x6b\xb6\xef\xc7\xfd\x11\x30\x59\x7e\x92\x8e\x27\x52\x99\xb0\x7f\x7f\x93\x6a\xb9\xa4\xe3\x52\x8a\xea\xb1\x6c\x7c\x73\xc2\xf8\x88\x73\xef\x46\xb3\x72\x9d\xc4\x65\x6c\x29\x15\x7c\xea\x83\x6c\x8c\x7e\xa7\x64\xdb\xd8\x5c\x55\x54\x54\x68\x0b\x2c\x14\xc5\x91\x5b\xbc\x33\xd2\xbe\x36\x3f\x2d\x9b\x83\x0f\xd3\x49\x51\x38\x83\x78\x89\xb7\x95\xc8\xc1\x5a\x9b\x51\x0d\xa7\xfc\x72\xc9\x42\xf5\xb7\xfa\xc2\xce\xce\xd0\x89\xda\xf6\x39\xda\xb6\xe5\x2d\x67\xbd\x6c\x6f\x75\xe6\xdc\x5e\x93\x8f\x07\xf0\x86\xf4\xec\x77\x25\xf6\x41\xde\xd9\x01\x54\x2a\x8d\x5f\x77\x15\x7b\xae\x94\x54\xc9\x5b\x3b\xe3\x4e\x21\xce\x30\xbd\x79\x68\x10\x06\x8b\x6a\x3f\x57\xea\x27\xe4\x4d\x67\xd0\xc1\x0e\xe0\x07\xfb\x32\xf7\x27\x12\xa9\xd3\xf3\xcf\xcc\xc4\x76\xce\x29\xc0\xe1\xd6\xfe\xbc\xa7\x81\x67\x3e\x0e\x3c\xbe\x6b\xee\x96\xd6\xd5\x56\xbe\x24\xae\x07\xce\x3b\xbb\x05\x76\x87\xb0\xee\xaa\xa3\xff\x80\x30\x6e\x90\xf9\x72\x7f\xfc\xbf\x29\xe2\xcb\xfd\xf1\x1f\xbc\x3f\x6e\xde\x13\xc7\x68\x46\xad\x69\xda\x20\x12\x5d\x3f\xeb\xae\x85\x16\xd3\x9f\xec\xac\xd8\x3e\xfa\x1e\xf9\x72\x91\x3c\x74\x91\x7c\xb9\x47\x7e\xf1\x1e\x19\xea\xdc\x9c\xfc\x15\xLine truncated
|
||||
|
||||
func templatesServerMainGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -682,12 +708,12 @@ func templatesServerMainGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/server/main.gotmpl", size: 5965, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x18, 0x3a, 0x5f, 0x4, 0xcb, 0x2, 0x79, 0xa2, 0x38, 0x87, 0x61, 0x77, 0x5c, 0xac, 0x21, 0x9c, 0xa5, 0x9d, 0x1c, 0xa0, 0xc9, 0x41, 0xba, 0x52, 0xc2, 0x20, 0x9f, 0x9b, 0x64, 0x2c, 0xab, 0x8f}}
|
||||
info := bindataFileInfo{name: "templates/server/main.gotmpl", size: 6138, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x26, 0x57, 0xb3, 0x4, 0x1f, 0x3e, 0x53, 0xdb, 0xd7, 0xe3, 0x4a, 0x9b, 0x13, 0x7c, 0x4d, 0xab, 0x85, 0x9c, 0xd, 0xf9, 0x3c, 0x67, 0x32, 0x9a, 0x90, 0xf7, 0x4d, 0x4e, 0xcf, 0x87, 0xad, 0xa4}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesServerOperationGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xe4\x57\x4d\x6f\xdb\x46\x13\xbe\xf3\x57\xcc\x2b\xbc\x08\x28\x43\x26\xef\x0e\x7c\x48\xed\x14\xf1\xa1\x89\x60\x1b\xed\xb1\x58\x93\x43\x72\x11\x72\x97\x99\x1d\x5a\x56\x08\xfe\xf7\x62\x3f\x48\x53\x2e\x25\x05\x2d\x7a\x28\x7a\x92\xc8\x9d\x9d\x8f\xe7\x99\x2f\xa6\x29\xdc\xe8\x1c\xa1\x44\x85\x24\x18\x73\x78\xda\x43\xa9\x2f\xcd\x4e\x94\x25\xd2\x7b\xb8\xfd\x02\x9f\xbf\x3c\xc2\xc7\xdb\xbb\xc7\x24\x8a\xa2\xbe\x07\x59\x40\x72\xa3\xdb\x3d\xc9\xb2\x62\xb8\x1c\x86\x34\x85\xbe\x87\x4c\x37\x0d\x2a\x7e\x73\xd6\xf7\x80\x2a\x87\x61\x88\xa2\xa8\x15\xd9\x57\x51\xa2\x15\x4e\xb6\xe1\xbf\x3d\x48\x53\x78\xac\xa4\x81\x42\xd6\x08\x3b\x61\x0e\x9d\xe1\x0a\x21\x78\x03\xac\x75\x9d\x58\xf9\x8f\xb9\x64\xa9\x4a\xe0\xe9\x5e\xe3\x2c\xb6\xa4\x9f\x11\x8a\x8e\x9d\xaa\x0a\x15\xec\x75\x07\x84\x97\xd4\x29\xa7\x69\x54\xed\xdc\x15\x2a\x8f\x22\xd9\xb4\x9a\x18\xe2\x08\x60\xa5\x90\xd3\x8a\xb9\x5d\x45\xf6\xa9\x94\x5c\x75\x4f\x49\xa6\x9b\xb4\xd4\x97\xba\x45\x25\x5a\x99\x22\x91\x26\xb3\x3a\x2e\x40\x9d\x62\xd9\x60\xda\xc8\x3c\xaf\x71\x27\x08\x7f\x40\xd8\x60\xd6\x91\xe4\xfd\x09\x51\xc3\x54\x34\x7c\x4a\x60\x27\xca\x13\xc7\xcf\xa2\x96\xb9\x60\x74\xc1\x59\x1e\x5d\xe0\x06\x92\x5b\x2c\x44\x57\xf3\x5d\x78\x1e\x86\x37\xe7\xb3\x83\xb5\x63\xab\xef\xa1\x15\x26\x13\xb5\xfc\x8e\x90\x7c\x16\x8d\xe5\xf1\x93\x50\x79\x8d\xf4\x73\xa7\x32\xe0\x8e\x94\x01\x01\x45\xa7\x32\x96\x5a\xc1\x4e\x72\xe5\xf0\xf7\x89\x61\x64\xa9\x04\x77\x84\x20\x15\x6b\x10\x56\x63\xd5\x35\x42\xcd\x15\x42\xe5\x35\x46\xbc\x6f\xf1\xbc\x4d\x6b\x2b\x5e\x94\xda\x0a\x12\x8d\x09\x99\xfb\xa1\xe3\x4a\x93\xfc\x8e\x36\x29\x37\xe0\xdf\x2a\xcd\x10\x03\x7e\x83\x64\x4b\x52\x65\xb2\x15\x35\xac\xa4\x62\xa4\x42\x64\xd8\x0f\x2b\x58\xc3\x30\x5c\x4c\xc9\xec\x32\x78\x92\x9c\x65\xf9\x3a\x28\xfc\x7f\xf2\xc0\x24\x33\xbe\x47\xd3\x6a\x95\x23\x59\xf4\x96\x63\x98\x44\xa0\xef\xb1\x36\x38\x0c\xf0\x9a\x39\xc9\xc1\xa9\xca\x43\xb9\xf8\xb8\x01\x5f\x30\xeb\x42\x1d\x20\x10\x7e\xeb\xd0\x30\x08\x95\x03\xa1\xa5\xc0\x9e\x08\x20\xa7\xc2\x60\x64\x11\x82\xb8\x50\x67\xb1\x5c\x07\x03\x71\xeb\x90\x5b\x96\x3f\x85\x6a\x3b\x61\xf3\xaf\xc3\x17\xfa\x08\x02\x7c\x50\xa8\x80\xc0\x99\x28\x5f\xdd\x8b\x86\xb3\x05\x02\x53\xdc\x50\x68\x02\xae\x04\x43\x26\x54\xc8\x76\x70\x55\xba\x5c\x0f\xde\x97\xf3\xe5\x30\xb3\x60\x83\x09\x5c\xfe\x07\x4a\xc3\x83\xff\x19\x77\x8b\xda\x20\x23\x14\x8c\xb6\x2f\x29\xdc\x81\xed\xf3\xc9\x88\x98\x67\x02\x97\x71\xd7\xad\x1d\x19\x52\x2b\x5f\x41\xc7\xf4\xc7\x19\xbf\xc0\xc5\xcc\xc1\x1b\xad\x18\x5f\x78\x33\x36\xb2\x93\xa4\xad\xe1\x62\xd9\xeb\x59\x3e\xbe\x5b\x94\xe8\x83\x9d\x2b\xc8\xf8\x65\x13\xe8\xa6\xab\xd1\xaa\x87\xe5\x88\xf2\x30\x58\xaf\x48\x77\xec\x07\xf3\x2f\xc8\x95\xce\x03\x25\xc9\x56\x70\xe5\x49\x24\xa1\x4a\x84\xe4\x51\x94\x23\x5f\xc9\x9c\x5d\xb7\x01\x88\x06\x0f\xd4\x4f\xeb\xc2\x43\xd7\x34\x82\xf6\x21\x3d\x0e\x9e\xec\xf1\x2d\x9a\x8c\x64\xeb\x26\x45\xb8\xf5\x54\xeb\xec\xeb\xb4\x52\x1c\x0a\xcc\x73\xcd\xa6\xc5\x5b\x1d\xee\xe0\x9c\x02\x7b\xcf\xfd\x5b\x82\x7c\x29\x0b\x3e\x6c\xef\x66\xcb\xcc\x45\x7a\xa2\x0e\xc1\x30\x75\x19\x3b\xea\x02\x39\x4b\x89\x31\xd5\xe6\xe9\xcc\xb0\xfc\xf9\xd6\x6d\xc1\xbb\xc7\x0c\xe5\x33\xd2\x68\x6a\x99\xd8\x35\x3c\x20\x3d\xe3\xa7\xc7\xc7\x6d\x4c\x21\xd7\xef\xc3\x1c\xf8\x8d\x24\x23\x6d\x80\xe0\x22\xbc\x77\x73\x63\xed\x33\xcd\x26\xc2\x06\xe8\xc6\xa6\xd2\xef\x70\x75\x0d\x0b\x46\xc7\x00\x92\x7b\x2b\x7d\xa7\x0a\x1d\xd3\x3a\x02\xcb\x83\xbd\x08\xff\xbb\x06\x25\x6b\xa7\x0f\x80\xe0\xda\xbd\x8d\x00\xec\x62\xf1\x2c\x08\x7c\xd7\x81\xeb\xa3\xa5\xe4\x05\xe2\xf5\xb8\xa9\xbc\x6d\x4e\x9d\x6b\xbd\x1b\x10\xce\x4d\x24\x3a\xe7\xe8\x74\x3b\xb6\x81\x5b\xaf\x83\xbf\xf6\xee\x81\xbb\x27\xc3\xf5\x1d\x27\xa6\xdd\x06\x46\x3d\xc9\x96\x74\xde\x65\x68\x36\x23\x76\x48\x0e\x8c\xb1\x6a\x43\xdc\xb2\x70\xde\xfe\x19\x1b\x71\x88\xcd\xe2\xe8\x3c\xd1\x7e\x4f\x77\x5f\x6f\xd8\xc3\x75\x68\xfa\xd5\xce\x75\xb0\x74\xaa\xc7\x8f\x90\xbf\x56\x8e\x7f\x4e\xe2\x8b\xb7\x26\xd7\x90\xa6\x7e\x2f\x97\x06\x08\x45\x5d\xef\xfd\x82\x77\x20\xb5\x81\x3b\xbb\xac\x37\xd2\xe0\x6b\x55\x59\x14\x3c\xe3\xd3\x8b\x40\xd1\x19\x7a\x7f\x92\x2a\xff\xd5\x0e\xce\x90\xcb\x13\xcb\x1b\x78\xe7\x73\x69\xfd\xfe\x80\x6a\xeb\xe3\x93\x54\xf9\x38\x53\xff\x39\xe6\x8f\x64\xb0\x6b\xea\xe6\x58\x5c\xa1\xf2\xc3\x6f\xec\x43\x98\x2d\x1c\x0e\x63\x91\x71\xe7\xd0\x0d\x9b\xc3\x6c\x07\x74\x46\xfd\xc4\xfc\x0b\x86\x7e\x48\xfb\x2b\x45\x7f\x1f\x37\x42\xb3\x8e\x22\xdf\xf8\xc3\x9c\xf9\xf8\xc2\x24\x1e\xb2\x0a\x1b\xe1\x3e\x3c\xfc\x52\x35\xef\xd0\x8c\x4d\x5b\xdb\x2f\xb9\x55\xae\x33\xc3\x24\x55\xb9\x72\x33\x29\x4a\x53\x2b\x3e\x8e\xb6\x46\xe7\x58\xcf\x2f\x3b\x97\x2f\x67\xf7\x8d\x33\x13\x2e\xdb\xa3\x10\xda\x1f\x01\x00\x00\xff\xff\x64\x70\xfa\x14\x1c\x0f\x00\x00")
|
||||
var _templatesServerOperationGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xdc\x57\x4b\x6f\xdb\xc6\x13\xbf\xf3\x53\xcc\x5f\xf8\x23\xa0\x0c\x99\xbc\x3b\xf0\x21\xb5\x53\xc4\x87\x3a\x82\x2d\xb4\xc7\x62\x4d\x0e\xc9\x45\xc8\x5d\x66\x76\x68\x59\x21\xf8\xdd\x8b\x7d\x50\xa2\x1c\x5a\x0a\xfa\x00\x8a\x9e\xec\xe5\xce\xce\xe3\x37\xbf\x79\x28\x4d\xe1\x46\xe7\x08\x25\x2a\x24\xc1\x98\xc3\xd3\x0e\x4a\x7d\x69\xb6\xa2\x2c\x91\xde\xc3\xed\x67\xb8\xff\xbc\x81\x8f\xb7\x77\x9b\x24\x8a\xa2\xbe\x07\x59\x40\x72\xa3\xdb\x1d\xc9\xb2\x62\xb8\x1c\x86\x34\x85\xbe\x87\x4c\x37\x0d\x2a\x7e\x75\xd7\xf7\x80\x2a\x87\x61\x88\xa2\xa8\x15\xd9\x17\x51\xa2\x15\x4e\xd6\xe1\x7f\x7b\x91\xa6\xb0\xa9\xa4\x81\x42\xd6\x08\x5b\x61\x8e\x9d\xe1\x0a\x21\x78\x03\xac\x75\x9d\x58\xf9\x8f\xb9\x64\xa9\x4a\xe0\xfd\xbb\xc6\x59\x6c\x49\x3f\x23\x14\x1d\x3b\x55\x15\x2a\xd8\xe9\x0e\x08\x2f\xa9\x53\x4e\xd3\xa8\xda\xb9\x2b\x54\x1e\x45\xb2\x69\x35\x31\xc4\x11\xc0\x42\x21\xa7\x15\x73\xbb\x88\xec\xa9\x94\x5c\x75\x4f\x49\xa6\x9b\xb4\xd4\x97\xba\x45\x25\x5a\x99\x22\x91\x26\xb3\x78\x5b\x80\x3a\xc5\xb2\xc1\xb4\x91\x79\x5e\xe3\x56\x10\xfe\x80\xb0\xc1\xac\x23\xc9\xbb\x13\xa2\x86\xa9\x68\xf8\x94\xc0\x56\x94\x27\xae\x9f\x45\x2d\x73\xc1\xe8\x82\xb3\x79\x74\x81\x1b\x48\x6e\xb1\x10\x5d\xcd\x77\xe1\x3c\x0c\xaf\xee\x27\x17\x4b\x97\xad\xbe\x87\x56\x98\x4c\xd4\xf2\x1b\x42\x72\x2f\x1a\x9b\xc7\x4f\x42\xe5\x35\xd2\xcf\x9d\xca\x80\x3b\x52\x06\x04\x14\x9d\xca\x58\x6a\x05\x5b\xc9\x95\xc3\xdf\x13\xc3\xc8\x52\x09\xee\x08\x41\x2a\xd6\x20\xac\xc6\xaa\x6b\x84\x9a\x2a\x84\xca\x6b\x8c\x78\xd7\xe2\x79\x9b\xd6\x56\x3c\x2b\xb5\x16\x24\x1a\x13\x98\xfb\xa1\xe3\x4a\x93\xfc\x86\x96\x94\x2b\x08\x5f\xd7\x24\x55\x26\x5b\x51\xdf\x99\xfb\xae\xae\xc5\x53\x6d\x1f\x5e\xec\xd9\xeb\x28\x3b\xca\xc0\x84\xd6\xcb\xa0\xe1\xff\xc9\x23\x93\xcc\xf8\x01\x4d\xab\x55\x8e\x64\xe1\x9a\x77\x7a\x2f\x02\x7d\x8f\xb5\xc1\x61\x80\x03\x55\x92\xa3\x5b\x95\x87\xfa\xf0\x81\x02\xbe\x60\xd6\x05\xe2\x23\x10\x7e\xed\xd0\x30\x08\x95\x03\xa1\xc5\xdc\xde\x08\x20\xa7\xc2\x60\x64\x21\x81\xb8\x50\x67\xc1\x5b\x06\x03\x71\xeb\xa0\x9a\x97\x3f\x05\x63\xbb\xc7\xe6\xdf\x0f\x28\xf4\x11\x04\xbc\xa0\x50\x21\xe4\x33\x61\x1d\xdc\x8b\x86\xb3\x25\x60\x49\x8d\x54\x88\x0c\xa1\xd0\x04\x5c\x09\x86\x4c\xa8\xc0\x67\x70\x75\x38\xcf\x78\xef\xcb\x79\xc2\x4f\x2c\xd8\x60\x42\xf2\xfe\x8b\xe4\xf7\x68\xdf\xe3\x76\x56\x1b\x64\x84\x82\xd1\xb6\x1a\x85\x5b\xb0\xad\x3b\x19\x21\xf2\xd0\xe3\x3c\xd0\xba\xb5\x53\x40\x6a\xe5\x6b\xe4\x2d\xfd\x71\xc6\x2f\x70\x31\x71\xf0\x46\x2b\xc6\x17\x5e\x8d\xbd\xe9\x64\x96\x96\x70\x31\xef\xf5\x84\x80\xef\x66\x25\xfa\x60\xe7\x0a\x32\x7e\x59\x85\xfc\xd2\xd5\x68\xd5\xc3\x72\x31\x6f\x7c\x1c\x96\x57\xa4\x3b\xf6\xc3\xf6\x17\xe4\x4a\xe7\x21\x27\xc9\x5a\x70\xe5\xb3\x48\x42\x95\x08\xc9\x46\x94\x63\xc2\x92\x69\x7a\xdd\x54\x17\x0d\x1e\xa9\xdf\xaf\x00\x8f\x5d\xd3\x08\xda\x05\x7e\x1c\x9d\xec\xf5\x2d\x9a\x8c\x64\xeb\xba\x7f\x78\xf5\x54\xeb\xec\xcb\x7e\x4d\x38\x16\x98\x92\xcd\xf2\xe2\xb5\x0e\x77\x71\x4e\x81\x7d\xe7\xfe\x9b\xc3\x7c\x8e\x06\x1f\xd6\x77\x93\x05\xe5\x22\x3d\x51\x79\x60\x98\xba\x8c\x5d\xee\x42\x76\xe6\x98\xb1\xaf\xc6\xd3\xd4\xb0\x09\xf4\xdd\xd9\x82\xf7\x80\x19\xca\x67\xa4\xd1\xd4\x3c\x6d\x96\xf0\x88\xf4\x8c\x9f\x36\x9b\x75\x4c\x81\xec\x0f\xa1\xd5\xff\x46\x92\x91\x56\x40\x70\x11\xbe\xbb\xd1\xb0\xf4\x54\xb3\x44\x58\x01\xdd\x58\x2e\xfd\x0e\x57\xd7\x30\x63\x74\x0c\x20\x79\xb0\xd2\x77\xaa\xd0\x31\x2d\x23\xb0\x79\xb0\x0f\xe1\x7f\xd7\xa0\x64\xed\xf4\x01\x10\x5c\xbb\xaf\x11\x80\x5d\x16\x9e\x05\x81\xef\x33\x70\xfd\x66\x2d\x79\x81\x78\xe9\xb7\x8f\xcb\xef\xfb\x51\x04\xd0\xb9\x86\xbb\x02\xe1\x5c\x45\xa2\x73\xce\xee\x15\xc4\x36\x78\xeb\x79\xf0\xd9\xbe\x3d\x72\xf9\x64\xc8\xbe\xed\xc4\xb4\x5d\xc1\xa8\x27\x59\x93\xce\xbb\x0c\xcd\x6a\xc4\x0f\xc9\x01\x32\x96\x6e\x88\x5d\x16\xce\xdb\xef\xf1\x11\xc7\xf8\xfc\xe5\x09\xe9\x6d\x79\x84\x8e\xad\x1d\x54\x5f\x07\xe5\xf8\x75\xfa\x76\x21\x55\xe1\xa7\x45\x3f\x2c\x60\x18\xbc\x8e\x43\xc1\xf8\x73\x12\xff\x49\xc7\x96\x90\xa6\x7e\x11\x97\x06\x08\x45\x5d\xef\xfc\x46\x77\x24\xb5\x82\x3b\xbb\x9d\x37\xd2\xe0\xa1\xe4\x3c\x3c\xd3\x73\x48\xdd\x99\xb4\xff\x24\x55\xfe\xab\x1d\xa3\x81\xe7\xfb\xec\xaf\xe0\x9d\xe7\xd9\xf2\xfd\x11\x05\xac\x8b\x4f\x52\xe5\xe3\x84\xfd\xe7\x18\xe1\x5a\xbb\x79\x2b\x80\x50\xfe\xe1\x6f\xfc\x43\x2b\xd5\x64\xdc\xa6\x29\x88\x8c\x3b\x07\x71\xd8\x26\x26\x8b\x60\xf4\x77\xc4\x44\x68\x96\x51\xe4\x1b\x76\x98\x0f\x1f\x5f\x98\xc4\x63\x56\x61\x23\xdc\x8f\x00\xbf\xfe\x4c\x3b\x2b\x63\xd3\xd6\xf6\x57\xd5\x22\xd7\x99\x61\x92\xaa\x5c\xb8\x59\x12\xa5\xa9\x15\x1f\x47\x52\xa3\x73\xac\xa7\x8f\x43\x2f\x38\xbc\x37\xce\x4c\x78\x6c\xaf\x02\x33\xfe\x08\x00\x00\xff\xff\x9c\x28\xa4\x7b\xa8\x0e\x00\x00")
|
||||
|
||||
func templatesServerOperationGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -702,12 +728,12 @@ func templatesServerOperationGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/server/operation.gotmpl", size: 3868, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x93, 0x85, 0xb, 0x19, 0xe8, 0x7d, 0xb, 0xc0, 0x51, 0x86, 0x7d, 0x2d, 0x8b, 0x11, 0xfe, 0x39, 0x17, 0x4f, 0xa3, 0xba, 0xc1, 0x9, 0x51, 0xff, 0x12, 0xcf, 0x4c, 0xde, 0xf5, 0x7d, 0xfb, 0x67}}
|
||||
info := bindataFileInfo{name: "templates/server/operation.gotmpl", size: 3752, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x12, 0x9e, 0xc1, 0x15, 0xfc, 0x9c, 0x4f, 0x16, 0xa3, 0xd7, 0x49, 0xc2, 0xf, 0x43, 0x7d, 0x78, 0xd6, 0x19, 0x4f, 0xd5, 0xb1, 0x2a, 0xd7, 0xee, 0x51, 0xb6, 0xa9, 0xc6, 0x7d, 0xe0, 0x46, 0x5c}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesServerParameterGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x3d\x5b\x73\xdb\x36\xba\xcf\xab\x5f\xf1\xad\xce\xd9\x0c\xe9\x91\xc9\x9e\x3d\x9d\x7d\x70\xeb\xce\x24\xb6\xdb\x78\xda\x5c\x4e\x92\xf6\xe1\x64\x33\x5b\x58\x84\x24\x6c\x48\x82\x01\x20\x3b\x3a\x1a\xfe\xf7\x33\xb8\x91\x00\x09\x52\x54\xec\xa6\xed\xb4\xfb\xb0\xb5\x88\xdb\x77\x01\xbe\x3b\x90\xfd\x1e\x32\xbc\x22\x25\x86\xf9\x0d\x29\xb3\x8a\x91\x82\x08\x72\x8b\x2b\xc4\x50\x31\x87\xba\xde\xef\xd3\x13\x40\x25\xe0\xa2\x12\x3b\x10\x98\x0b\x3d\x80\x08\x42\x4b\x10\x54\x7f\x12\xb8\xa8\x72\x24\x30\x30\x5c\x51\xc8\x70\x85\xcb\x0c\x97\x4b\x82\x39\x30\xcc\x69\xbe\x55\xbd\x4f\xe1\xf2\x05\x3c\x7f\xf1\x06\x2e\x9e\x3e\x7e\xfe\xdd\x15\xbc\x79\x7a\xfd\x1a\x4e\xd2\xba\x9e\xed\xf7\x80\xcb\x0c\xea\x7a\x36\x73\x21\xa2\xd9\xee\x16\xe5\x24\x43\x82\x32\x09\xcc\x0c\x60\xbf\x3f\x05\xb2\x82\xe4\x29\xe2\xcf\x68\x86\xf3\x27\x34\xdb\xbd\x94\xc0\x72\xdd\x9e\xa6\x60\x86\x60\x90\xe3\x81\xde\xfc\x1b\x2f\x85\x42\x23\xc3\x39\x5e\xcb\x06\xd3\xc3\x60\x50\xc8\x79\x4c\x3f\x0d\x0e\xc8\x25\x30\x63\x70\x76\xae\x26\x49\x7e\x32\x53\x46\x8c\x6e\x05\x4e\xbe\xa5\xac\x40\x82\xc7\x5f\xa9\x4e\x7f\x3d\x87\x92\xe4\xb0\x9f\x01\x80\x44\x17\xce\x01\x55\x92\x02\x11\xc3\x7c\x21\xbb\xc4\x33\x80\x7a\xa6\xa7\xcd\x71\x29\xbf\xc7\x70\x7e\x0e\x5f\x98\x41\xfb\x3d\x24\xaf\xf0\x12\x93\x5b\xcc\x9e\xa3\x02\x43\x5d\x27\xfb\x3d\x54\x88\x2f\x51\x4e\xfe\x0f\x43\x62\xbe\xc2\xb9\xec\x4b\x56\x80\xca\x0c\xa2\x92\x0a\x48\x5e\x2f\x37\xb8\x40\xc9\x35\x7f\x82\x38\x7e\xb3\xab\x70\x0c\xc9\x35\x7f\xbe\xcd\x73\x74\x93\xcb\x31\x8f\x1a\xe2\x4a\x54\x14\x24\x9a\x8c\x38\xe7\xd8\xce\x25\xe9\xf9\x9a\x14\x55\x8e\x1d\x82\x7a\x44\xbe\x16\x58\xd3\xd8\x40\xac\xd8\x40\x59\x03\x80\x9c\x20\x27\x4b\xfc\x53\x43\x5b\xde\x02\x27\xc7\xca\x1e\x6e\x63\x8f\x5d\x88\x31\xb4\x03\xba\x72\xf9\xc6\x9b\xd5\xcc\xfe\x70\x16\x1f\x5b\xd9\xf4\xfc\xdc\xa4\x35\x2b\x36\xc7\x61\xce\x25\x60\xea\x30\x39\x1b\x39\x71\x11\xb1\xfb\xde\x41\x4c\x31\x64\x8c\x74\x0a\xbc\xc8\x21\xbe\xee\x75\xcd\xaf\x4b\x81\xd9\x0a\x2d\x71\xaf\xe5\xb5\x60\x18\x15\x71\xac\x97\x5e\x51\xa6\x28\x73\x5d\x66\xf8\xe3\x4f\x88\x49\xfc\xcf\xce\x81\xa1\x72\x6d\x8e\xcd\xbe\xc1\xc6\xa3\xb5\x9d\xce\x21\x82\xea\x48\x34\xd7\xde\x76\x26\x7d\x27\x77\x79\x7b\x38\x06\x27\x7c\x85\x3f\x6c\x09\xc3\x59\xcb\xb7\x81\x93\x44\x59\xdb\x39\x92\x8b\x5d\x6c\x48\x9e\x25\x2f\x91\xd8\x40\x5d\x2f\x24\x52\x15\x23\xa5\x58\xc1\xfc\x6f\x1f\xe6\xb6\xf9\x07\xba\xd4\xa7\x5d\x76\x09\xc2\x19\xc7\xcd\xba\x37\x0c\xa3\xf7\x1e\xb8\xea\xa0\x34\x90\x2d\x69\x29\x48\xb9\xc5\x7e\x97\x76\x77\xd6\xb3\xe0\x67\x5f\xa2\xf4\x00\x38\x42\xc4\x8c\x08\x19\x1f\xfe\xda\x8a\x1d\x87\xee\xee\xc6\x1e\x3c\x38\xbf\x19\x31\x35\x70\xf8\x5b\x86\xa4\x29\x94\xd4\x95\xe7\x72\x67\x13\x25\xaa\x48\x09\x62\x43\x38\xa8\x23\x38\xfb\xfc\x92\xc0\x3f\xdc\xc7\x0b\xdc\x67\xa8\x1a\x13\x0c\x87\x44\xc2\xe3\x2c\x53\x3a\x1a\xe5\x2f\x19\xad\x30\x13\x04\x87\x25\xc4\x40\x47\x5f\x60\xb8\x72\xba\x40\x55\x40\x4a\x5b\x91\xf2\x3d\xde\x1d\x23\x50\x82\xab\x77\xc5\x41\x7b\x76\x2c\x10\x9e\x10\x90\xd3\x79\x72\xa0\x27\x18\x24\x77\xf4\x9e\x99\xcf\x1b\x4e\x4d\x92\x16\x7a\x7a\xb5\x09\xae\xf9\xe3\x92\x96\xbb\x82\x6e\xb9\x59\xc3\xe0\xf0\x1d\x95\x5b\x02\xea\x3a\xf2\x76\xc1\x5b\x8f\x1c\xef\x06\x67\x8a\x9b\x51\x43\xa7\x5d\x6c\x59\x29\x5b\xc6\xe4\x4b\x70\x93\x0c\xf0\xb6\xd9\xb8\x91\x01\xe7\x19\xaa\xe4\xb7\x17\xb7\x98\x31\x92\xe1\x38\x24\xd6\x5b\x4c\x0e\x0a\xf5\x49\x4c\x9d\x2e\xe3\x07\xa5\x7b\x58\xae\xb7\x80\x1e\x21\xd5\xef\x23\xd7\x6f\x51\x0e\x0b\xa0\xef\xe1\xec\x3c\x00\xc4\x57\xb2\xa5\x47\x2a\xc5\xa5\x23\x38\xe1\x2c\xf5\xd7\x10\xf5\xbd\x9d\xd0\x39\x31\x47\xe9\x96\x09\x1a\x26\x44\xd1\xfa\x21\x10\xac\xc7\x68\xff\xdb\x32\xa0\x27\x29\x22\xa5\x7f\x0a\x54\xfd\xba\xda\xc7\x57\x3e\x41\xc5\xe3\x1b\xd6\xed\xca\xd7\xfc\xb1\x34\xca\x63\x97\x7b\xf1\x90\x0a\xea\x29\x0a\x52\xe6\xd2\x8f\x33\x30\x7d\x5e\x0a\xb4\x07\x20\xb4\xae\x05\xd1\x5f\xff\xfa\x12\xea\x5a\x52\xe5\x5e\x6e\x9e\xb7\x37\x2c\x16\x52\x31\x1b\x62\xde\x87\x8c\x86\x30\xcd\x54\x75\xad\x9c\xa6\x56\xbd\x15\xa8\x6a\x7d\xe9\x3f\x28\xcd\x07\x0e\x24\xb3\xfa\x87\x96\xbf\xea\xce\x6c\xce\xa6\x7f\x34\xbb\x6a\xdc\xb3\xd5\xc2\x18\xd1\x12\xd6\xb8\xc4\x8c\x2c\x81\xd8\xae\xbf\x02\x3a\x01\x59\xa3\x7f\xb8\x16\xb0\x13\xd6\x09\xf9\xc4\x3a\x06\x64\x22\x0a\xcf\x48\xa9\xa3\x0d\xc9\x33\xf4\xb1\x89\x3b\x18\x39\xbf\x44\x05\xf6\xb0\x78\x2d\x7f\x9c\x9d\x4b\x12\xfc\xe3\xcb\x48\x6a\x87\x2e\x52\x1d\x29\xf6\x14\xf1\x4b\xc2\x97\x8c\x14\xa4\x94\x8b\xb7\xd2\xad\x21\x78\xfb\xc9\x98\xc1\x1d\x2a\x9c\x34\x54\x68\xd7\xd2\xd6\xa3\x31\xc4\x37\x88\xbf\x64\x78\x45\x3e\x82\x54\xbe\x5b\x7c\xf5\xb1\x62\x98\x73\xc9\xb5\x39\x4d\xe6\xca\xac\x6e\xad\xd4\x6e\x97\xba\xbe\x68\x8f\xb4\xec\xd6\xef\xd0\xda\x8c\xb1\x13\x3d\x33\xe2\xa1\x21\x60\x5d\xcf\xd2\x54\x7b\xfa\xf2\xf7\x25\xae\x94\x25\x55\x98\xf6\x33\xd5\xe4\xf6\x0e\x58\xda\xb6\xf9\x08\x53\x6c\x88\x4d\x8b\xee\x7a\xfd\x63\xee\x18\xbb\x75\x00\x31\x67\x3f\x04\x11\x33\xed\x06\x31\xa7\x77\x08\x31\xd3\xfc\x40\x88\x35\xf3\x1d\x8f\xd6\x8f\x25\xf9\xb0\xc5\xa3\x98\x6d\xdb\x2e\x67\x20\xd8\x16\x87\x30\x72\xe6\x39\x0e\xa9\x5f\xfb\xb8\xc0\x81\xf3\x02\x0f\x79\x60\Line truncated
|
||||
var _templatesServerParameterGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x3d\x6d\x73\xdb\x36\x9a\x9f\x4f\xbf\xe2\xa9\xee\x9a\x21\x7d\x32\x95\xdd\xeb\xec\x07\xb7\xee\x4c\x62\xbb\x8d\xa7\x75\x92\x4b\xd2\xde\xcc\xe5\x32\x5b\x58\x84\x24\xac\x49\x82\x01\x40\xdb\x3a\x8d\xfe\xfb\x0e\xde\x48\x80\x04\x29\x2a\x76\xdb\x74\xb6\xfb\x61\x1b\x91\x20\xf0\xbc\xe1\x79\x07\xbc\xdd\x42\x8a\x97\xa4\xc0\x30\xbd\x26\x45\x5a\x32\x92\x13\x41\x6e\x71\x89\x18\xca\xa7\xb0\xdb\x6d\xb7\xf3\x23\x40\x05\xe0\xbc\x14\x1b\x10\x98\x0b\xfd\x01\x11\x84\x16\x20\xa8\x7e\x24\x70\x5e\x66\x48\x60\x60\xb8\xa4\x90\xe2\x12\x17\x29\x2e\x16\x04\x73\x60\x98\xd3\xac\x52\xa3\x8f\xe1\xfc\x15\xbc\x7c\xf5\x0e\xce\x5e\x3c\x7b\xf9\xfd\x05\xbc\x7b\x71\xf9\x16\x8e\xe6\xbb\xdd\x64\xbb\x05\x5c\xa4\xa0\xff\x55\x03\x44\xd3\xcd\x2d\xca\x48\x8a\x04\x65\x12\x96\x09\xc0\x76\x7b\x0c\x64\x09\xc9\x0b\xc4\xaf\x68\x8a\xb3\xe7\x34\xdd\xbc\x96\xb0\x72\xfd\x7e\x3e\x07\xf3\x09\x06\xf9\x3d\xd0\xeb\x7f\xe0\x85\x50\x58\xa4\x38\xc3\x2b\xf9\xc2\x8c\x30\x08\xe4\x72\x1e\x33\x4e\x43\x03\x72\x09\xcc\x18\x9c\x9c\xaa\x49\x92\x9f\xcd\x94\x11\xa3\x95\xc0\xc9\x77\x94\xe5\x48\xf0\xf8\x6b\x35\xe8\x8b\x53\x28\x48\x06\xdb\x09\x00\x48\x6c\xe1\x14\x50\x29\x09\x10\x31\xcc\x67\x72\x48\x3c\x01\xd8\x4d\x26\x00\x0b\x71\x2f\xe7\xb4\x10\x26\xff\x43\xc4\xfa\x55\x89\x99\x82\xe5\x0d\xfe\x58\x61\x2e\xa2\x05\x2d\x04\xbe\x17\xc9\x73\xb4\xb8\x59\x31\x5a\x15\x69\x14\xc7\x5d\x98\xce\xf4\xb0\x1a\xb4\x85\xb8\x9f\xc1\x03\xe1\x23\x4b\xc8\x70\x21\x9f\xc7\x70\x7a\x0a\x4f\xcd\x47\xdb\x2d\x24\x6f\xf0\x02\x93\x5b\xcc\x5e\xa2\x1c\xc3\x6e\x97\x6c\xb7\x50\x22\xbe\x40\x19\xf9\x7f\x0c\x89\x79\x0a\xa7\x72\x2c\x59\x02\x2a\x52\x88\x0a\x2a\x20\x79\xbb\x58\xe3\x1c\x25\x97\xfc\x39\xe2\xf8\xdd\xa6\xc4\x31\x24\x97\xfc\x65\x95\x65\xe8\x3a\x93\xdf\x3c\xa9\x79\x2f\xd1\x52\x90\x68\x36\xe3\x8c\x63\x3b\x97\xe4\xf7\x5b\x92\x97\x19\x76\x18\xee\x09\xc1\xa5\xc0\x5a\x06\x0c\xc4\x4a\x4c\x28\xab\x01\x90\x13\x64\x64\x81\x7f\xae\x79\xcf\x1b\xe0\xe4\xb7\x72\x84\xfb\x52\x4f\xe5\xca\x13\x62\x0c\x6d\x80\x2e\x5d\xc1\xe2\xf5\x72\x46\x7e\xdd\xe5\x87\xd6\x56\x62\xf6\xdb\x13\xd7\xac\x58\xef\xd7\x29\x97\x80\xa9\xdd\xee\x6c\xb5\xc4\x82\xd7\x83\x98\x62\xc9\x10\xf1\x14\x78\x91\x43\x7e\x3d\xea\x92\x5f\x16\x02\xb3\x25\x5a\xe0\xce\x9b\xb7\x82\x61\x94\xc7\xb1\x5e\x7a\x49\x99\xa2\xcc\x65\x91\xe2\xfb\x9f\x11\x93\xf8\x9f\x9c\x02\x43\xc5\xca\x6c\xec\x6d\x8d\x8d\x47\x6b\x3b\x9d\x43\x04\x35\x90\x68\xb6\xbd\x6f\x4d\xfa\x41\xca\x79\xb3\x3d\x7a\x27\x94\x9b\x93\x30\x9c\x36\x7c\xeb\xd9\x4b\x94\x35\x83\x23\xb9\xd8\xd9\x9a\x64\x69\xf2\x1a\x89\x35\xec\x76\x33\x89\x54\xc9\x48\x21\x96\x30\xfd\xf2\xe3\xd4\xbe\xfe\x91\x2e\xb4\x3e\x92\x43\x82\x70\x2a\x15\xa0\xff\x77\xcd\x30\xba\xf1\xc0\x55\x5b\xa5\x86\x4c\x2a\x10\x52\x54\xd8\x1f\x52\xd4\xb0\xef\x26\xc1\xc7\xbe\x7e\xe9\x00\x70\x80\x12\x1c\x50\x33\x3e\xfc\x3b\xab\x78\x1c\xba\xbb\x82\xdd\xb3\x71\x3e\x27\x4d\x15\x20\xa4\xcf\x91\xf9\x1c\x0a\xea\x9a\x1c\x29\xda\x44\x69\x2b\x52\x80\x58\x13\x0e\x6a\x0f\x4e\x7e\x7b\x55\xe0\xef\xee\xc3\x75\xee\x15\x2a\x87\x34\xc3\x3e\x9d\xf0\x2c\x4d\x95\x17\x81\xb2\xd7\x8c\x96\x98\x09\x82\xc3\x2a\xa2\x67\xa0\xaf\x31\x5c\x4d\x9d\xa3\x32\xa0\xa7\xad\x4e\xf9\x01\x6f\x0e\xd1\x28\xc1\xd5\xdb\xfa\xa0\xd9\x3c\xb5\x71\x77\xb5\x80\x9c\xce\x53\x04\x1d\xcd\x20\xb9\xa3\x65\x66\x3a\xad\x39\x35\x4a\x5d\xe8\xe9\x95\x10\x5c\xf2\x67\x05\x2d\x36\x39\xad\xb8\x59\xc3\xe0\xf0\x3d\x95\x22\x01\xbb\x5d\xe4\x49\xc1\x7b\x8f\x1c\x1f\x7a\x67\x8a\xeb\xaf\xfa\xb6\xbb\xa8\x58\x21\xdf\x0c\x29\x98\xa0\x90\xf4\xf0\xb6\x16\xdc\xc8\x80\x73\x85\x4a\xf9\xec\xd5\x2d\x66\x8c\xa4\x38\x0e\xe9\xf5\x06\x93\xbd\x5a\x7d\x14\x53\xc7\x2b\xf9\x5e\xf5\x1e\x56\xec\x0d\xa0\x07\xa8\xf5\x87\x28\xf6\x5b\x94\xc1\x0c\xe8\x0d\x9c\x9c\x06\x80\xf8\x5a\xbe\xe9\x90\x4a\x71\xe9\x00\x4e\x38\x4b\x7d\x11\xa2\xbe\x27\x09\xad\x1d\x73\x90\x71\x19\x61\x62\x42\x14\xdd\x3d\x06\x82\xbb\x21\xda\x7f\x6e\x96\x69\x84\x21\x52\xf6\x27\x47\xe5\xef\x6b\x7d\x7c\xe3\x13\x34\x3c\x8e\x6d\xf5\x56\xbe\xe4\xcf\xa4\x5b\x1e\xbb\xdc\x8b\xfb\x4c\x50\xc7\x50\x90\x22\x93\xa1\xa6\x81\xe9\xb7\xa5\x40\xb3\x01\x42\xeb\x5a\x10\xfd\xf5\x2f\xcf\x61\xb7\x93\x54\x79\x50\x24\xea\xc9\x86\xc5\x42\x1a\x66\x43\xcc\x87\x90\xd1\x10\xa6\x9e\x6a\xb7\x53\x61\x53\x63\xde\x72\x54\x36\xd1\xfe\xbf\x28\xcd\x7b\x36\x24\xb3\xf6\x87\x16\xbf\xab\x64\xd6\x7b\xd3\xdf\x9a\xfe\x16\xf4\x3c\xb5\x30\x3e\xb4\x80\x15\x2e\x30\x23\x0b\x20\x76\xe8\x67\xa1\x68\x6c\xaa\xa9\x71\x7f\x9d\xb4\x53\x28\x22\x76\x73\x4f\x72\xa3\x5c\x91\x42\x27\x1c\x92\x2b\x74\xdf\x4e\x3d\xc0\x02\xe5\xd8\x43\xe4\xad\xfc\x71\x72\x2a\xa9\xf0\xb7\xaf\x22\x69\x1e\xda\x78\xb5\xd4\xd8\x0b\xc4\xcf\x09\x5f\x30\x92\x93\x42\x02\xd0\xa8\xb7\x9a\xe6\xcd\x23\xe3\x07\xb7\x08\x71\x54\x13\xa2\x59\x4b\xbb\x8f\xc6\x13\x5f\x23\xfe\x9a\xe1\x25\xb9\x07\x69\x7d\x2b\x7c\x71\x5f\x32\xcc\xb9\x64\xdc\x94\x26\x53\xe5\x57\x37\x6e\x6a\x7b\xc8\x6e\x77\xd6\xec\x69\x39\xac\x3b\xa0\x71\x1a\xe3\x49\x80\x0b\x52\x86\x6a\x3a\x4a\xea\xcd\xe7\x3a\xe4\x97\x0f\xce\x71\xa9\x3c\xaa\xdc\x0c\x38\x51\xaf\xdc\xe1\x01\x8f\xdb\xbe\x3e\xc0\x25\xeb\xe3\xd6\xac\xbd\x5e\x77\xbb\x3b\x4e\xef\xae\x17\x3f\x57\Line truncated
|
||||
|
||||
func templatesServerParameterGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -722,12 +748,12 @@ func templatesServerParameterGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/server/parameter.gotmpl", size: 28728, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x4b, 0x53, 0xb9, 0xa3, 0xe8, 0xc6, 0x71, 0x82, 0x7a, 0xd6, 0x71, 0xb9, 0x4e, 0x13, 0x9f, 0xe, 0x59, 0x1c, 0x98, 0xc, 0x37, 0x19, 0xbf, 0xc4, 0x84, 0x11, 0x3c, 0x3e, 0x24, 0x20, 0x65, 0x31}}
|
||||
info := bindataFileInfo{name: "templates/server/parameter.gotmpl", size: 29440, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xed, 0x43, 0xd4, 0x63, 0x5e, 0xa4, 0x12, 0x99, 0x24, 0x71, 0xa6, 0xc0, 0xf, 0x42, 0xd, 0x2c, 0x8f, 0xfb, 0x25, 0x2e, 0x46, 0x82, 0xc1, 0x74, 0xee, 0xc7, 0x6, 0xfc, 0x74, 0x77, 0x90, 0xcc}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesServerResponsesGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x5a\xdf\x73\xdb\x36\xf2\x7f\xd7\x5f\xb1\xd5\x37\xed\x88\x1e\x89\xcc\xf7\xe1\x5e\xdc\xba\x33\xd7\x38\x77\x75\xe7\x1a\x7b\x62\xf7\x6e\xe6\x72\x99\x06\x26\x57\x12\x5a\x12\x64\x00\x50\x8e\x4e\xc3\xff\xfd\x06\xbf\x48\x80\x3f\x64\xd9\x6d\xf3\xd4\x3c\xc4\x22\x80\x5d\xec\x2e\x3e\xfb\x03\x4b\x1e\x0e\x90\xe1\x9a\x32\x84\xb9\x40\xbe\x43\xbe\x45\x92\x21\xbf\xaf\x69\x9e\x21\x9f\x43\xd3\xcc\x0e\x07\xa0\x6b\x60\xa5\x84\xf8\x4a\xfc\x95\x73\xb2\x87\xa6\x39\x1c\x40\x62\x51\xe5\x44\x2a\x4a\x5a\x54\x39\x8e\xd2\xc7\x66\x2d\xe6\x02\x07\x54\x39\x4d\x8f\x13\xb1\xcc\xec\xbf\xea\x7e\x76\xd2\x4e\xef\xd9\xca\x1c\x5f\x89\x37\x75\x9e\x93\xfb\x1c\x61\xd5\x34\xb3\x1d\xe1\x70\x38\xc0\x8e\x70\x46\x0a\x84\xf8\xea\x12\x9a\x06\x84\xe4\x94\x6d\x66\x74\xad\xe6\xe2\xb7\x98\x22\xdd\x21\x7f\xa3\x56\x34\x4d\x7c\x38\x40\x45\x44\x4a\x72\xfa\xdf\x96\xe2\x8b\x0b\x60\x34\x87\xc3\x0c\x46\xd8\x5d\x80\xdd\xfc\x6f\x25\x2f\x88\x94\xc8\x8d\x36\xc1\xf3\xe2\xec\xc4\xbd\xa2\xc0\x78\xdd\x39\xbc\xaa\x85\x2c\x0b\x9f\xe5\x59\x6b\xb1\x13\x59\xb7\x36\x1a\xf2\x8a\x6f\xb5\x4d\x16\xd1\xe1\x80\x2c\x53\x4b\xf5\x9f\x99\x36\x6c\x27\x4e\x4f\xf3\xf3\xd3\x54\x7f\x96\xe6\x7f\x90\x42\xd6\x66\x0a\x1c\xe6\xfc\x7b\x2a\x7d\x71\x01\xf3\xb9\x3e\x68\xfe\x10\x7f\xaf\x61\xb6\x88\xe2\x5b\x94\x4a\x8b\x8a\x53\x26\xd7\x30\xff\xf2\xe3\x1c\x62\x2b\xd7\x72\xc8\x24\x9a\xb5\xfb\xf4\x20\xac\x1c\x80\x4a\x2c\x9e\x85\xe2\xf8\x9f\x24\xaf\xf1\xf5\xa7\x8a\xa3\x10\xb4\x64\xd0\x34\xb7\x3d\x2c\x0f\x57\xf4\xa0\x3b\xca\xe3\x09\x00\x1e\x92\x7b\xa7\x36\xb1\xe2\x37\xc1\x6e\x65\xac\x32\x2a\xf7\x13\xe0\x77\x54\xee\xdf\x4d\xec\x01\xb8\x46\xc5\xee\x20\x36\xbe\xe2\x2d\x5c\x00\xa9\x2a\x64\xd9\x84\xe8\x6f\x97\x53\xbc\xfb\xc8\x0b\x80\x37\x05\xba\x7e\x90\x7c\xb5\xa5\x79\x36\x2a\xd7\xbb\xf7\x16\x6e\xeb\x92\xc3\xcf\xcb\x93\xa8\xd4\x29\x71\xc2\x36\x38\x05\x50\x63\x88\x55\x1b\xea\x0c\xa3\xa9\xc4\x73\xd4\x83\x0c\xed\xb3\x12\x90\x4f\x69\x8f\x30\x48\x84\x46\xaa\x1b\xc2\x91\x49\x07\xca\x61\x34\x14\x0f\x64\x13\xff\x50\x52\xf6\xdd\xde\xe0\x65\x71\x92\x61\xb5\x25\x83\xe0\xf2\xaa\xcc\x73\x4c\x25\x2d\x99\xe1\xa3\xa3\x0a\x5d\x43\x8e\x6c\x31\x8c\x37\xf0\x2d\xbc\xd4\x76\xdc\xee\xac\x53\x84\x0b\xde\xbd\x7c\x3f\x03\xa5\xca\x76\xe7\xa1\xef\x09\x21\x6e\xbb\x8b\x66\x00\x4f\xf0\xcb\xcf\x65\x88\x51\x27\x68\xcd\x31\xb1\x40\x58\x23\x8d\xcd\xb5\xa6\x9a\xa4\xf5\x0d\xf8\xbb\x3b\xb0\xf0\xed\x6c\x71\x18\xfe\x0c\x8b\x37\x8e\xa2\x2a\x99\x40\xbf\x6e\x53\x06\x2e\x33\x84\xd5\xff\x43\xd3\x24\x09\x1c\x0e\x5e\xde\x54\x47\xda\x34\x7a\x9e\x0a\x90\x5b\x84\xef\xef\xee\x6e\x20\x55\x03\x1c\x65\xcd\x19\x66\xa0\xdc\x5b\xee\x2b\xed\xb2\x03\xda\x59\x5a\x32\x21\x47\xa7\x0c\x5b\x26\x4d\x46\x31\x52\xf8\x85\xdd\x2c\x39\xb3\x51\xf5\x12\x45\xca\x69\x25\xdb\x50\xdb\xe3\xa5\x03\xc3\x01\xee\xf3\x32\xfd\x35\x2d\x8b\x42\x79\xdd\x80\x48\x01\xf1\x08\xf1\xb6\x2e\x08\xf3\x07\x5d\x98\x9e\x29\x74\x6e\x90\x9f\x3b\xeb\xa9\xd5\x29\x29\x30\x60\x31\x3b\x4b\x66\x13\x46\xb0\x45\x64\x9d\x4a\x07\x33\xba\x06\xfc\xe8\xdb\x7d\x06\xf0\xb3\x90\x44\xd6\xc2\x19\xc5\x2c\x6c\x0b\x36\x13\x13\xad\xff\x09\x75\x52\x67\x87\xc3\xa8\x69\x8e\x1b\xc1\xd9\xd6\x89\x11\xff\x48\x3e\xd1\xa2\x2e\xcc\x98\x7d\x38\x77\x93\xaf\x3f\xa5\x79\x2d\xe8\x0e\xbb\x55\xdf\x04\x62\x79\xe4\xfe\xb0\x66\x4c\x99\xc7\xd8\x3c\x8c\x30\x6e\x57\x7d\xdb\x63\xdc\x4e\x0c\x18\xd7\xb9\xa4\x55\x8e\xd7\x6b\xcb\xdb\x3e\xc3\xf5\x5a\xf3\x0f\x17\x0c\xa8\xc9\xa7\x7f\x20\xdb\xc8\x6d\xab\x31\x98\x67\x4b\xeb\x4d\x8f\x68\x14\x90\x52\x16\x92\x7a\xd3\x7d\xd2\x1b\x5d\x0b\x30\x43\x68\x1f\x0c\x55\x37\x33\x22\xe9\x95\x4a\x5d\x9d\xa0\xfa\xb1\x95\xd3\x4d\x8e\x88\xe9\xd3\x51\x16\xd0\x75\x93\x7d\xba\x9f\x18\xfd\x58\xa3\x47\x6a\x06\xce\x41\xf2\x1a\xfb\x8b\xbf\x27\xe2\x12\xd7\xa4\xce\xa5\x59\x6b\x1f\xce\x83\x88\xfc\x7f\xbb\xb9\x42\xa0\x5b\xe6\xa3\xef\x2c\x31\x10\x1c\xf7\xc5\xf8\xef\xe5\x9d\xf2\xa5\xa6\x81\x0f\xbf\x88\x92\x9d\xcf\x0f\x07\x1b\x34\xbc\x24\xfb\x16\x3f\xd6\x94\xa3\xe2\xb8\x2c\x0b\x95\xe6\x2b\xb9\xef\x0b\x7a\x25\x7e\xb8\xbd\x7e\x63\x2a\x30\xb5\xd0\x94\x24\xed\xaa\xf9\x07\xdf\xd1\x3a\xb7\xb8\x4d\xb7\x58\x10\xc3\xe6\x81\xca\xad\x37\x32\x03\xf8\x6d\xce\xf7\xa7\xe7\xfd\xe9\x79\xcf\xf0\xbc\x19\xc0\x15\x3b\x87\xef\xca\x6c\xaf\x1d\xc8\x9f\xb8\x21\xfb\xbc\x24\x99\x3d\x64\xc2\x32\x58\x68\x17\x31\xa0\x8d\xaf\xc4\x77\x44\xa0\x72\xa9\xc8\x1b\x7b\x55\x16\x55\x8e\x9f\xae\xef\x7f\xc1\x54\x0e\x3a\x04\x76\xd9\xc0\x13\xef\xcb\x6c\xdf\xb9\x5b\xcf\x7f\x54\xd2\x4e\xe0\x0d\x3e\x8c\xbb\x76\xca\x91\x48\x14\x13\x8e\xaf\xfd\x2c\xb3\xe1\x62\x6b\x33\xdd\x4e\x55\x3d\x62\xb6\xae\x59\x3a\xc9\x77\x31\x96\x52\x53\x9b\x48\x5b\xe1\x22\x38\x9b\x08\x38\xe3\x29\x99\xae\x4d\x9d\xf3\xcd\x85\xad\x0f\xc1\x3c\x5f\xc0\x5f\x5e\xbe\xd4\x75\x57\x70\x6b\xd7\x51\xd1\x08\xad\xa2\xe3\x6d\x59\xa0\x0d\x7d\xf6\x50\xd5\xc5\x69\xa1\x82\x47\x02\x94\x51\x49\x8d\x14\x4e\xcf\x40\x79\xab\xb4\xb6\xec\x20\xf3\x6b\x49\xda\x40\xe5\x05\xe2\x55\x3b\x67\xe7\xbd\xb2\xbe\x69\xdc\xaa\x0b\x6f\x8d\x59\xb7\x72\x98\x89\xaf\xc4\x0d\xa7\x05\x95\x74\x87\x63\x57\x59\x8d\xa9\x85\x89\xa0\xaf\x4a\x26\x09\x65\x02\xe2\x7f\x23\x2f\x61\xbe\xf8\xcf\x7c\Line truncated
|
||||
var _templatesServerResponsesGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x5a\xdf\x73\xdb\x36\xf2\x7f\xd7\x5f\xb1\xd5\x37\xed\x88\x1e\x89\xcc\xf7\xe1\x5e\xdc\xba\x33\xd7\x38\x77\x75\xe7\x1a\x7b\x62\xf7\x6e\xe6\x72\x99\x06\x26\x57\x12\x5a\x12\x64\x00\x50\x8e\x4e\xc3\xff\xfd\x06\xbf\x48\x80\x3f\x64\xd9\x6d\xf3\xd4\x3c\xc4\x22\x80\x5d\xec\x2e\x3e\xfb\x03\x4b\x1e\x0e\x90\xe1\x9a\x32\x84\xb9\x40\xbe\x43\xbe\x45\x92\x21\xbf\xaf\x69\x9e\x21\x9f\x43\xd3\xcc\x0e\x07\xa0\x6b\x60\xa5\x84\xf8\x4a\xfc\x95\x73\xb2\x87\xa6\x39\x1c\x40\x62\x51\xe5\x44\x2a\x4a\x5a\x54\x39\x8e\xd2\xc7\x66\x2d\xe6\x02\x07\x54\x39\x4d\x8f\x13\xb1\xcc\xec\xbf\xea\x7e\x76\xd2\x4e\xef\xd9\xca\x1c\x5f\x89\x37\x75\x9e\x93\xfb\x1c\x61\xd5\x34\xb3\x1d\xe1\x70\x38\xc0\x8e\x70\x46\x0a\x84\xf8\xea\x12\x9a\x06\x84\xe4\x94\x6d\x66\x74\xad\xe6\xe2\xb7\x98\x22\xdd\x21\x7f\xa3\x56\x34\x4d\x7c\x38\x40\x45\x44\x4a\x72\xfa\xdf\x96\xe2\x8b\x0b\x60\x34\x87\xc3\x0c\x46\xd8\x5d\x80\xdd\xfc\x6f\x25\x2f\x88\x94\xc8\x8d\x36\xc1\xf3\xe2\xec\xc4\xbd\xa2\xc0\x78\xdd\x39\xbc\xaa\x85\x2c\x0b\x9f\xe5\x59\x6b\xb1\x13\x59\xb7\x36\x1a\xf2\x8a\x6f\xb5\x4d\x16\xd1\xe1\x80\x2c\x53\x4b\xf5\x9f\x99\x36\x6c\x27\x4e\x4f\xf3\xf3\xd3\x54\x7f\x96\xe6\x7f\x90\x42\xd6\x66\x0a\x1c\xe6\xfc\x7b\x2a\x7d\x71\x01\xf3\xb9\x3e\x68\xfe\x10\x7f\xaf\x61\xb6\x88\xe2\x5b\x94\x4a\x8b\x8a\x53\x26\xd7\x30\xff\xf2\xe3\x1c\x62\x2b\xd7\x72\xc8\x24\x9a\xb5\xfb\xf4\x20\xac\x1c\x80\x4a\x2c\x9e\x85\xe2\xf8\x9f\x24\xaf\xf1\xf5\xa7\x8a\xa3\x10\xb4\x64\xd0\x34\xb7\x3d\x2c\x0f\x57\xf4\xa0\x3b\xca\xe3\x09\x00\x1e\x92\x7b\xa7\x36\xb1\xe2\x37\xc1\x6e\x65\xac\x32\x2a\xf7\x13\xe0\x77\x54\xee\xdf\x4d\xec\x01\xb8\x46\xc5\xee\x20\x36\xbe\xe2\x2d\x5c\x00\xa9\x2a\x64\xd9\x84\xe8\x6f\x97\x53\xbc\xfb\xc8\x0b\x80\x37\x05\xba\x7e\x90\x7c\xb5\xa5\x79\x36\x2a\xd7\xbb\xf7\x16\x6e\xeb\x92\xc3\xcf\xcb\x93\xa8\xd4\x29\x71\xc2\x36\x38\x05\x50\x63\x88\x55\x1b\xea\x0c\xa3\xa9\xc4\x73\xd4\x83\x0c\xed\xb3\x12\x90\x4f\x69\x8f\x30\x48\x84\x46\xaa\x1b\xc2\x91\x49\x07\xca\x61\x34\x14\x0f\x64\x13\xff\x50\x52\xf6\xdd\xde\xe0\x65\x71\x92\x61\xb5\x25\x83\xe0\xf2\xaa\xcc\x73\x4c\x25\x2d\x99\xe1\xa3\xa3\x0a\x5d\x43\x8e\x6c\x31\x8c\x37\xf0\x2d\xbc\xd4\x76\xdc\xee\xac\x53\x84\x0b\xde\xbd\x7c\x3f\x03\xa5\xca\x76\xe7\xa1\xef\x09\x21\x6e\xbb\x8b\x66\x00\x4f\xf0\xcb\xcf\x65\x88\x51\x27\x68\xcd\x31\xb1\x40\x58\x23\x8d\xcd\xb5\xa6\x9a\xa4\xf5\x0d\xf8\xbb\x3b\xb0\xf0\xed\x6c\x71\x18\xfe\x0c\x8b\x37\x8e\xa2\x2a\x99\x40\xbf\x6e\x53\x06\x2e\x33\x84\xd5\xff\x43\xd3\x24\x09\x1c\x0e\x5e\xde\x54\x47\xda\x34\x7a\x9e\x0a\x90\x5b\x84\xef\xef\xee\x6e\x20\x55\x03\x1c\x65\xcd\x19\x66\xa0\xdc\x5b\xee\x2b\xed\xb2\x03\xda\x59\x5a\x32\x21\x47\xa7\x0c\x5b\x26\x4d\x46\x31\x52\xf8\x85\xdd\x2c\x39\xb3\x51\xf5\x12\x45\xca\x69\x25\xdb\x50\xdb\xe3\xa5\x03\xc3\x01\xee\xf3\x32\xfd\x35\x2d\x8b\x42\x79\xdd\x80\x48\x01\xf1\x08\xf1\xb6\x2e\x08\xf3\x07\x5d\x98\x9e\x29\x74\x6e\x90\x9f\x3b\xeb\xa9\xd5\x29\x29\x30\x60\x31\x3b\x4b\x66\x13\x46\xb0\x45\x64\x9d\x4a\x07\x33\xba\x06\xfc\xe8\xdb\x7d\x06\xf0\xb3\x90\x44\xd6\xc2\x19\xc5\x2c\x6c\x0b\x36\x13\x13\xad\xff\x09\x75\x52\x67\x87\xc3\xa8\x69\x8e\x1b\xc1\xd9\xd6\x89\x11\xff\x48\x3e\xd1\xa2\x2e\xcc\x98\x7d\x38\x77\x93\xaf\x3f\xa5\x79\x2d\xe8\x0e\xbb\x55\xdf\x04\x62\x79\xe4\xfe\xb0\x66\x4c\x99\xc7\xd8\x3c\x8c\x30\x6e\x57\x7d\xdb\x63\xdc\x4e\x0c\x18\xd7\xb9\xa4\x55\x8e\xd7\x6b\xcb\xdb\x3e\xc3\xf5\x5a\xf3\x0f\x17\x0c\xa8\xc9\xa7\x7f\x20\xdb\xc8\x6d\xab\x31\x98\x67\x4b\xeb\x4d\x8f\x68\x14\x90\x52\x16\x92\x7a\xd3\x7d\xd2\x1b\x5d\x0b\x30\x43\x68\x1f\x0c\x55\x37\x33\x22\xe9\x95\x4a\x5d\x9d\xa0\xfa\xb1\x95\xd3\x4d\x8e\x88\xe9\xd3\x51\x16\xd0\x75\x93\x7d\xba\x9f\x18\xfd\x58\xa3\x47\x6a\x06\xce\x41\xf2\x1a\xfb\x8b\xbf\x27\xe2\x12\xd7\xa4\xce\xa5\x59\x6b\x1f\xce\x83\x88\xfc\x7f\xbb\xb9\x42\xa0\x5b\xe6\xa3\xef\x2c\x31\x10\x1c\xf7\xc5\xf8\xef\xe5\x9d\xf2\xa5\xa6\x81\x0f\xbf\x88\x92\x9d\xcf\x0f\x07\x1b\x34\xbc\x24\xfb\x16\x3f\xd6\x94\xa3\xe2\xb8\x2c\x0b\x95\xe6\x2b\xb9\xef\x0b\x7a\x25\x7e\xb8\xbd\x7e\x63\x2a\x30\xb5\xd0\x94\x24\xed\xaa\xf9\x07\xdf\xd1\x3a\xb7\xb8\x4d\xb7\x58\x10\xc3\xe6\x81\xca\xad\x37\x32\x03\xf8\x6d\xce\xf7\xa7\xe7\xfd\xe9\x79\xcf\xf0\xbc\x19\xc0\x15\x3b\x87\xef\xca\x6c\xaf\x1d\xc8\x9f\xb8\x21\xfb\xbc\x24\x99\x3d\x64\xc2\x32\x58\x68\x17\x31\xa0\x8d\xaf\xc4\x77\x44\xa0\x72\xa9\xc8\x1b\x7b\x55\x16\x55\x8e\x9f\xae\xef\x7f\xc1\x54\x0e\x3a\x04\x76\xd9\xc0\x13\xef\xcb\x6c\xdf\xb9\x5b\xcf\x7f\x54\xd2\x4e\xe0\x0d\x3e\x8c\xbb\x76\xca\x91\x48\x14\x13\x8e\xaf\xfd\x2c\xb3\xe1\x62\x6b\x33\xdd\x4e\x55\x3d\x62\xb6\xae\x59\x3a\xc9\x77\x31\x96\x52\x53\x9b\x48\x5b\xe1\x22\x38\x9b\x08\x38\xe3\x29\x99\xae\x4d\x9d\xf3\xcd\x85\xad\x0f\xc1\x3c\x5f\xc0\x5f\x5e\xbe\xd4\x75\x57\x70\x6b\xd7\x51\xd1\x08\xad\xa2\xe3\x6d\x59\xa0\x0d\x7d\xf6\x50\xd5\xc5\x69\xa1\x82\x47\x02\x94\x51\x49\x8d\x14\x4e\xcf\x40\x79\xab\xb4\xb6\xec\x20\xf3\x6b\x49\xda\x40\xe5\x05\xe2\x55\x3b\x67\xe7\xbd\xb2\xbe\x69\xdc\xaa\x0b\x6f\x8d\x59\xb7\x72\x98\x89\xaf\xc4\x0d\xa7\x05\x95\x74\x87\x63\x57\x59\x8d\xa9\x85\x89\xa0\xaf\x4a\x26\x09\x65\x02\xe2\x7f\x23\x2f\x61\xbe\xf8\xcf\x7c\Line truncated
|
||||
|
||||
func templatesServerResponsesGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -742,12 +768,12 @@ func templatesServerResponsesGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/server/responses.gotmpl", size: 12037, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xb5, 0x1d, 0x82, 0x1f, 0x70, 0xed, 0x78, 0x0, 0x19, 0xe2, 0xd, 0xe5, 0x9b, 0xa9, 0x6, 0x88, 0xd9, 0x2, 0x7a, 0xca, 0x1, 0x6c, 0x8c, 0xb3, 0x34, 0xf1, 0xd3, 0x69, 0xd6, 0x1a, 0x43, 0x81}}
|
||||
info := bindataFileInfo{name: "templates/server/responses.gotmpl", size: 12038, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x4f, 0x3e, 0xa6, 0x40, 0x1a, 0x63, 0xc, 0xe8, 0x7f, 0xd9, 0x98, 0xaf, 0x4f, 0x4f, 0xd3, 0x5f, 0xde, 0xe, 0xa, 0x75, 0x5f, 0x6a, 0x13, 0xd9, 0xfc, 0xd9, 0x64, 0xd4, 0xd4, 0x15, 0x17, 0xd7}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesServerServerGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xd4\x5c\x7d\x6f\xdb\x38\xd2\xff\xdb\xfe\x14\xb3\x3e\x5c\x56\x2e\x6c\xa9\x2f\xd7\xc5\x5d\x6e\xf3\x00\xd9\x34\x6d\x73\x4d\x5b\xa3\xf6\xee\x3e\x87\xc5\x22\x65\x24\xda\xe6\x13\x99\xd4\x91\x54\x1c\x6f\xe0\xef\xfe\x60\xf8\x22\x51\xb2\x9c\xa4\xb9\xee\xbd\x04\x68\x6d\x51\x43\xf2\x37\x43\xce\x70\x38\x1c\x3a\x49\xe0\x44\x64\x14\x16\x94\x53\x49\x34\xcd\xe0\x72\x03\x0b\x31\x56\x6b\xb2\x58\x50\xf9\x57\x78\xf5\x11\x3e\x7c\x9c\xc1\xe9\xab\xb3\x59\xdc\xef\xf7\x6f\x6f\x81\xcd\x21\x3e\x11\xc5\x46\xb2\xc5\x52\xc3\x78\xbb\x4d\x12\xb8\xbd\x85\x54\xac\x56\x94\xeb\xd6\xbb\xdb\x5b\xa0\x3c\x83\xed\xb6\xdf\xef\x17\x24\xbd\x22\x0b\x8a\xc4\xf1\xf1\xe4\x6c\xe2\x1e\xf1\x1d\x5b\x15\x42\x6a\x88\xfa\xbd\x41\x2a\xb8\xa6\x37\x7a\x80\x5f\xe5\xa6\xd0\x22\xd1\xb9\xc2\x27\x2a\xa5\x90\xe6\x5b\x2e\x16\xf8\xc1\xa9\x76\x1f\xc9\x52\xeb\x02\xbf\x0b\x65\xff\x4f\x14\x5b\x70\x92\xe3\x83\xd2\x32\x15\xfc\xda\x7c\xdd\xf0\xd4\x7f\x26\x44\x8b\x15\x73\x8f\x2a\x25\xb9\x21\xd6\x6c\x45\x07\xfd\x3e\xc0\x60\xc1\xf4\xb2\xbc\x8c\x53\xb1\x4a\x16\x62\x2c\x0a\xca\x49\xc1\x12\x14\xcb\xa0\x0f\xe0\xc4\xf0\xa3\xa2\x6f\xc4\x54\xcb\x32\xd5\xaf\x73\xb2\x50\xb0\xdd\xce\xcd\x67\x58\xfd\xff\xa8\x52\xf4\x3a\xbb\xc2\x76\xcc\x5b\xd7\x00\xca\x65\xbc\xdd\xee\xef\x4c\x96\x1c\xf1\x24\x58\xc9\x48\x24\xec\x77\x12\x76\xd8\x68\x41\x15\xf3\x67\x2f\x92\x02\xcb\x77\x7a\xaa\xeb\xfb\xea\x03\x4f\x87\x82\x62\xbc\x13\x9d\xc8\x09\x5f\xc4\x42\x2e\x92\x9b\x04\xa5\xcd\xa9\x2e\x35\xcb\x8d\xa0\xb0\x45\x33\x78\x0a\xe2\x57\x74\x4e\xca\x5c\x9f\xb9\xe7\xaa\x47\xff\x3e\x78\x31\xec\xf7\x53\xc1\x95\x19\x72\x95\x2e\xe9\x8a\xbe\x9d\xcd\x26\x00\x47\x30\x70\x63\x59\x97\x4e\x7d\xa9\xaa\x8a\x7f\xe4\xec\xc6\x10\x97\x9c\xdd\x0c\xb0\xb5\x6b\x22\x21\xb3\xfd\x4f\x0d\x89\x82\x5f\x7e\xb5\x2c\xf5\xfb\xf3\x92\xa7\xc0\x38\xd3\xd1\x10\x6e\xfb\xbd\x16\xdd\x51\x45\x79\xeb\x04\x14\x2d\x89\x3a\xe3\x8a\xa6\xa5\xa4\x10\x3b\xba\x21\xe2\xee\x05\xb8\x46\x56\x4c\x66\x92\xbb\x4a\xd3\x7b\xaa\x4c\x47\x95\x42\xb8\x4a\x38\xdd\x09\xe3\x0a\xe2\xd3\x1b\x2d\x89\xc7\x64\x19\x6b\xd4\x47\x9e\xeb\xea\xfd\xde\xb6\xbf\xf5\xfa\xc8\x85\xde\x9d\x8c\xdb\xad\x11\x4a\xe4\xc6\xfc\xf4\x26\xcd\xcb\x8c\x4e\x0b\x9a\xda\x91\x51\x05\x4d\x5f\xb3\x9c\x82\xff\x73\xd2\xaa\x86\x7f\xbb\xa5\x9c\x5c\xe6\x34\x3b\x67\x4a\xa3\x7d\x08\x44\x0a\x90\xe6\x94\xf0\xb2\x98\xb1\x15\x15\xa5\x06\x00\x9c\xab\xf1\xab\x52\x12\xcd\x04\xef\x03\x2c\x24\x49\xe9\xbc\xcc\x2b\x8a\x36\xc1\x8a\xdc\xbc\xa5\x24\xa3\x72\xca\x7e\x33\x28\xdc\x44\x8f\x7f\xd8\x68\x8a\x65\x38\xbf\x94\x48\xaf\xa8\x9e\x10\xbd\xf4\xf8\xfa\x00\x4b\xa1\xf4\x2e\x6c\x63\x42\xfc\x1f\xe3\xba\x0f\x90\x1b\xe4\xe7\x6c\xc5\xb4\x2f\xba\xa2\xb4\x38\xce\xd9\xb5\xe9\xb1\x0d\x49\x52\x92\xed\xc5\xbb\x96\x4c\x53\xff\xb6\xf9\xb2\x0f\xa0\x73\xf5\x36\x84\x15\x00\xd3\xb9\x9a\x84\xd8\x3c\x14\x9d\xab\xf3\x10\x60\x50\xfe\x2e\x44\xb9\x0b\x45\xe7\xea\x53\x08\xb5\x93\xe2\xe7\x10\x6f\x27\xc5\x09\x95\x9a\xcd\x59\x4a\x34\x6d\x03\x0e\x5e\xbd\xa3\x9b\xe6\xab\xe3\x46\x3d\xf7\x6a\x58\x2d\x0e\xde\xba\x6c\xb7\xfd\x24\x81\xa9\x79\x3d\xcd\x59\x4a\x7f\x22\x12\x54\x59\x98\x71\x9a\x0b\x69\xc6\xbb\xaf\x37\x05\x05\x65\x5f\xe7\x25\x6d\x6b\x2d\xa7\xeb\x69\xf5\x32\xba\x26\x79\x3d\x09\x47\x50\xc0\x13\xff\x30\x84\x27\x41\x23\xb7\xfd\xde\x93\x02\x8e\x00\xe9\xfb\x3d\x49\x75\x29\x39\x44\x01\xc5\x30\x2a\x86\xa8\x3f\xa6\x8f\x48\x85\x95\x87\x30\xa5\x1a\x7b\x02\xdf\xb2\x59\x79\x4c\x9b\x68\x2c\x6a\xca\xc8\x99\xcc\x78\x5a\xe4\xcc\x54\x19\xc1\x60\x34\x18\x0e\xab\x2e\x39\xcb\xf7\xf6\xf2\x86\xa2\x39\x62\x5c\x53\x39\x27\x29\xbd\xdd\xc2\x2d\xb8\x6a\x9e\xa9\xe8\x09\x9a\x90\x7d\x28\x2d\xc9\xd0\xc1\xac\x6b\x7b\x54\x7f\x13\x8c\x47\x61\x53\x16\x1d\x98\x61\x41\x05\xbf\x6f\x68\x82\xc5\xbb\x69\x41\xdb\xba\x7b\xb4\xa3\xba\xd1\xb3\xa7\xe6\x6f\xb8\xcf\xfa\x60\x85\xd8\x02\xf8\x89\xc8\x49\x74\xe0\xcd\xd1\x08\x06\xf8\x75\x30\x82\x81\xff\xa7\x97\x14\x9c\x43\x62\xac\x96\x9d\x7a\x4c\x70\xd0\x02\x14\x95\xd7\x74\x30\x0c\xcd\x56\xe7\x42\xd7\xef\x99\x2e\x7f\x22\x32\x6a\xce\xa9\xe6\x6a\x30\x82\x83\xb6\xd5\x43\xb9\x19\x13\x4c\x3c\x98\xbc\x32\x88\x5a\x80\x25\x1f\x81\x5e\x32\x05\x29\xe1\x70\x49\x41\xd2\x82\x1a\x6f\x8a\xf0\xcc\x2f\x4b\x86\xd8\xb0\xe2\x6c\x3c\xe3\xd0\xe6\x6c\x30\xec\xf7\x02\x13\xdf\xb1\xdc\x3b\x36\x9a\x43\x17\xed\x60\xf6\x90\xe9\x60\x04\x6d\x06\xff\xa5\x2c\x18\xb4\xde\xea\x18\xa8\xcd\x85\x63\x04\x03\x57\x30\xd6\xb6\x64\x30\x82\x67\x4f\x9f\x18\x6b\x35\xa5\xa9\xe0\xd9\x08\x06\x66\x2d\x81\x82\x4a\x26\x32\x33\x3f\xd7\x4b\x96\x2e\x11\xcd\x9a\x30\x0d\x97\x74\x2e\x24\x85\x2b\x96\xe7\xa8\x09\x2c\xcb\x29\xa4\x82\x73\x9a\x62\xaf\x0a\x21\xed\xe2\x68\xad\x4f\xbe\x97\x79\x99\x87\x48\x5e\x3e\x0a\x89\x5a\x96\x5a\x23\x94\x4c\xac\x9d\x88\x70\x9a\xca\x0a\x89\x41\xd0\x50\xa2\x11\x0c\x56\xe4\x66\xbc\x34\x05\x63\xc5\x7e\xc3\xa1\x33\xde\xb0\x14\xb9\x32\x6d\xac\xc8\x0d\x5b\x95\x2b\xe0\xe5\xea\x92\x4a\x10\x73\xb8\xdc\x68\xaa\x82\xf6\x61\xcd\xf2\xdc\xac\x62\x50\x10\xa9\x10\x01\xbe\x94\xf4\x1f\x25\x55\x1a\x6c\xe3\xdf\x2a\xb8\xa2\x1b\x65\x06\xf6\x1a\x55\x40\x8d\x80\x71\xd4\xcf\x36\x7d\xce\x38\x8d\xe1\x4c\x43\x26\xa8\x32\x5e\x46\x6e\x56\x2aLine truncated
|
||||
var _templatesServerServerGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xd4\x5c\x7d\x6f\xdb\x38\xd2\xff\xdb\xfe\x14\xb3\x3e\x5c\x56\x2e\x6c\xa9\x2f\xd7\xc5\x5d\x6e\xf3\x00\xd9\x34\x6d\x73\x4d\x5b\xa3\xf6\xee\x3e\x87\xc5\x22\x65\x24\xda\xe6\x13\x99\xd4\x91\x54\x1c\x6f\xe0\xef\xfe\x60\xf8\x22\x51\xb2\x9c\xa4\xb9\xee\xbd\x04\x68\x6d\x51\x43\xf2\x37\x43\xce\x70\x38\x1c\x3a\x49\xe0\x44\x64\x14\x16\x94\x53\x49\x34\xcd\xe0\x72\x03\x0b\x31\x56\x6b\xb2\x58\x50\xf9\x57\x78\xf5\x11\x3e\x7c\x9c\xc1\xe9\xab\xb3\x59\xdc\xef\xf7\x6f\x6f\x81\xcd\x21\x3e\x11\xc5\x46\xb2\xc5\x52\xc3\x78\xbb\x4d\x12\xb8\xbd\x85\x54\xac\x56\x94\xeb\xd6\xbb\xdb\x5b\xa0\x3c\x83\xed\xb6\xdf\xef\x17\x24\xbd\x22\x0b\x8a\xc4\xf1\xf1\xe4\x6c\xe2\x1e\xf1\x1d\x5b\x15\x42\x6a\x88\xfa\xbd\x41\x2a\xb8\xa6\x37\x7a\x80\x5f\xe5\xa6\xd0\x22\xd1\xb9\xc2\x27\x2a\xa5\x90\xe6\x5b\x2e\x16\xf8\xc1\xa9\x76\x1f\xc9\x52\xeb\x02\xbf\x0b\x65\xff\x4f\x14\x5b\x70\x92\xe3\x83\xd2\x32\x15\xfc\xda\x7c\xdd\xf0\xd4\x7f\x26\x44\x8b\x15\x73\x8f\x2a\x25\xb9\x21\xd6\x6c\x45\x07\xfd\x3e\xc0\x60\xc1\xf4\xb2\xbc\x8c\x53\xb1\x4a\x16\x62\x2c\x0a\xca\x49\xc1\x12\x14\xcb\xa0\x0f\xe0\xc4\xf0\xa3\xa2\x6f\xc4\x54\xcb\x32\xd5\xaf\x73\xb2\x50\xb0\xdd\xce\xcd\x67\x58\xfd\xff\xa8\x52\xf4\x3a\xbb\xc2\x76\xcc\x5b\xd7\x00\xca\x65\xbc\xdd\xee\xef\x4c\x96\x1c\xf1\x24\x58\xc9\x48\x24\xec\x77\x12\x76\xd8\x68\x41\x15\xf3\x67\x2f\x92\x02\xcb\x77\x7a\xaa\xeb\xfb\xea\x03\x4f\x87\x82\x62\xbc\x13\x9d\xc8\x09\x5f\xc4\x42\x2e\x92\x9b\x04\xa5\xcd\xa9\x2e\x35\xcb\x8d\xa0\xb0\x45\x33\x78\x0a\xe2\x57\x74\x4e\xca\x5c\x9f\xb9\xe7\xaa\x47\xff\x3e\x78\x31\xec\xf7\x53\xc1\x95\x19\x72\x95\x2e\xe9\x8a\xbe\x9d\xcd\x26\x00\x47\x30\x70\x63\x59\x97\x4e\x7d\xa9\xaa\x8a\x7f\xe4\xec\xc6\x10\x97\x9c\xdd\x0c\xb0\xb5\x6b\x22\x21\xb3\xfd\x4f\x0d\x89\x82\x5f\x7e\xb5\x2c\xf5\xfb\xf3\x92\xa7\xc0\x38\xd3\xd1\x10\x6e\xfb\xbd\x16\xdd\x51\x45\x79\xeb\x04\x14\x2d\x89\x3a\xe3\x8a\xa6\xa5\xa4\x10\x3b\xba\x21\xe2\xee\x05\xb8\x46\x56\x4c\x66\x92\xbb\x4a\xd3\x7b\xaa\x4c\x47\x95\x42\xb8\x4a\x38\xdd\x09\xe3\x0a\xe2\xd3\x1b\x2d\x89\xc7\x64\x19\x6b\xd4\x47\x9e\xeb\xea\xfd\xde\xb6\xbf\xf5\xfa\xc8\x85\xde\x9d\x8c\xdb\xad\x11\x4a\xe4\xc6\xfc\xf4\x26\xcd\xcb\x8c\x4e\x0b\x9a\xda\x91\x51\x05\x4d\x5f\xb3\x9c\x82\xff\x73\xd2\xaa\x86\x7f\xbb\xa5\x9c\x5c\xe6\x34\x3b\x67\x4a\xa3\x7d\x08\x44\x0a\x90\xe6\x94\xf0\xb2\x98\xb1\x15\x15\xa5\x06\x00\x9c\xab\xf1\xab\x52\x12\xcd\x04\xef\x03\x2c\x24\x49\xe9\xbc\xcc\x2b\x8a\x36\xc1\x8a\xdc\xbc\xa5\x24\xa3\x72\xca\x7e\x33\x28\xdc\x44\x8f\x7f\xd8\x68\x8a\x65\x38\xbf\x94\x48\xaf\xa8\x9e\x10\xbd\xf4\xf8\xfa\x00\x4b\xa1\xf4\x2e\x6c\x63\x42\xfc\x1f\xe3\xba\x0f\x90\x1b\xe4\xe7\x6c\xc5\xb4\x2f\xba\xa2\xb4\x38\xce\xd9\xb5\xe9\xb1\x0d\x49\x52\x92\xed\xc5\xbb\x96\x4c\x53\xff\xb6\xf9\xb2\x0f\xa0\x73\xf5\x36\x84\x15\x00\xd3\xb9\x9a\x84\xd8\x3c\x14\x9d\xab\xf3\x10\x60\x50\xfe\x2e\x44\xb9\x0b\x45\xe7\xea\x53\x08\xb5\x93\xe2\xe7\x10\x6f\x27\xc5\x09\x95\x9a\xcd\x59\x4a\x34\x6d\x03\x0e\x5e\xbd\xa3\x9b\xe6\xab\xe3\x46\x3d\xf7\x6a\x58\x2d\x0e\xde\xba\x6c\xb7\xfd\x24\x81\xa9\x79\x3d\xcd\x59\x4a\x7f\x22\x12\x54\x59\x98\x71\x9a\x0b\x69\xc6\xbb\xaf\x37\x05\x05\x65\x5f\xe7\x25\x6d\x6b\x2d\xa7\xeb\x69\xf5\x32\xba\x26\x79\x3d\x09\x47\x50\xc0\x13\xff\x30\x84\x27\x41\x23\xb7\xfd\xde\x93\x02\x8e\x00\xe9\xfb\x3d\x49\x75\x29\x39\x44\x01\xc5\x30\x2a\x86\xa8\x3f\xa6\x8f\x48\x85\x95\x87\x30\xa5\x1a\x7b\x02\xdf\xb2\x59\x79\x4c\x9b\x68\x2c\x6a\xca\xc8\x99\xcc\x78\x5a\xe4\xcc\x54\x19\xc1\x60\x34\x18\x0e\xab\x2e\x39\xcb\xf7\xf6\xf2\x86\xa2\x39\x62\x5c\x53\x39\x27\x29\xbd\xdd\xc2\x2d\xb8\x6a\x9e\xa9\xe8\x09\x9a\x90\x7d\x28\x2d\xc9\xd0\xc1\xac\x6b\x7b\x54\x7f\x13\x8c\x47\x61\x53\x16\x1d\x98\x61\x41\x05\xbf\x6f\x68\x82\xc5\xbb\x69\x41\xdb\xba\x7b\xb4\xa3\xba\xd1\xb3\xa7\xe6\x6f\xb8\xcf\xfa\x60\x85\xd8\x02\xf8\x89\xc8\x49\x74\xe0\xcd\xd1\x08\x06\xf8\x75\x30\x82\x81\xff\xa7\x97\x14\x9c\x43\x62\xac\x96\x9d\x7a\x4c\x70\xd0\x02\x14\x95\xd7\x74\x30\x0c\xcd\x56\xe7\x42\xd7\xef\x99\x2e\x7f\x22\x32\x6a\xce\xa9\xe6\x6a\x30\x82\x83\xb6\xd5\x43\xb9\x19\x13\x4c\x3c\x98\xbc\x32\x88\x5a\x80\x25\x1f\x81\x5e\x32\x05\x29\xe1\x70\x49\x41\xd2\x82\x1a\x6f\x8a\xf0\xcc\x2f\x4b\x86\xd8\xb0\xe2\x6c\x3c\xe3\xd0\xe6\x6c\x30\xec\xf7\x02\x13\xdf\xb1\xdc\x3b\x36\x9a\x43\x17\xed\x60\xf6\x90\xe9\x60\x04\x6d\x06\xff\xa5\x2c\x18\xb4\xde\xea\x18\xa8\xcd\x85\x63\x04\x03\x57\x30\xd6\xb6\x64\x30\x82\x67\x4f\x9f\x18\x6b\x35\xa5\xa9\xe0\xd9\x08\x06\x66\x2d\x81\x82\x4a\x26\x32\x33\x3f\xd7\x4b\x96\x2e\x11\xcd\x9a\x30\x0d\x97\x74\x2e\x24\x85\x2b\x96\xe7\xa8\x09\x2c\xcb\x29\xa4\x82\x73\x9a\x62\xaf\x0a\x21\xed\xe2\x68\xad\x4f\xbe\x97\x79\x99\x87\x48\x5e\x3e\x0a\x89\x5a\x96\x5a\x23\x94\x4c\xac\x9d\x88\x70\x9a\xca\x0a\x89\x41\xd0\x50\xa2\x11\x0c\x56\xe4\x66\xbc\x34\x05\x63\xc5\x7e\xc3\xa1\x33\xde\xb0\x14\xb9\x32\x6d\xac\xc8\x0d\x5b\x95\x2b\xe0\xe5\xea\x92\x4a\x10\x73\xb8\xdc\x68\xaa\x82\xf6\x61\xcd\xf2\xdc\xac\x62\x50\x10\xa9\x10\x01\xbe\x94\xf4\x1f\x25\x55\x1a\x6c\xe3\xdf\x2a\xb8\xa2\x1b\x65\x06\xf6\x1a\x55\x40\x8d\x80\x71\xd4\xcf\x36\x7d\xce\x38\x8d\xe1\x4c\x43\x26\xa8\x32\x5e\x46\x6e\x56\x2aLine truncated
|
||||
|
||||
func templatesServerServerGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -762,8 +788,8 @@ func templatesServerServerGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/server/server.gotmpl", size: 23049, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x72, 0x85, 0x28, 0x2d, 0x49, 0x40, 0x62, 0x64, 0x9, 0xda, 0x68, 0x50, 0x3a, 0xa3, 0x17, 0x89, 0x3a, 0x99, 0x62, 0x59, 0xb3, 0x94, 0x22, 0x67, 0x40, 0x12, 0xa2, 0x85, 0xf1, 0x47, 0x63, 0x1d}}
|
||||
info := bindataFileInfo{name: "templates/server/server.gotmpl", size: 23073, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xdc, 0x34, 0xbc, 0xd0, 0x2f, 0x20, 0x15, 0x85, 0x71, 0xdc, 0x8b, 0xf9, 0x3d, 0x41, 0x19, 0x50, 0xb7, 0x48, 0xd1, 0x28, 0xac, 0x66, 0x89, 0x17, 0x42, 0x9e, 0xa9, 0xd6, 0x71, 0x34, 0x49, 0xd8}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
@@ -787,7 +813,47 @@ func templatesServerUrlbuilderGotmpl() (*asset, error) {
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesStructfieldGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xcc\x55\x4d\x8f\xd3\x30\x10\xbd\xe7\x57\x8c\xac\x1c\x76\xa5\x6d\x96\x73\x25\x2e\x7c\x89\x22\xd8\x4a\x64\x85\x38\xae\x65\x4f\xc2\xa0\xd8\x09\xb6\x8b\x28\x56\xfe\x3b\x72\x9c\x4f\x48\xbb\xaa\x10\x5a\x6e\x8d\x3d\x6f\xde\x9b\xe7\x67\xd7\x7b\x90\x58\x90\x46\x60\xd6\x99\x83\x70\x05\x61\x25\x19\xb4\x6d\x02\xe0\xfd\x06\xa8\x00\x5d\x3b\x48\xb3\x9d\x7d\xc1\x2d\xde\x1f\x1b\x84\x4d\xb7\x0b\x70\x7b\x0b\xde\x83\x43\xd5\x54\xdc\x21\x30\x59\x0b\xeb\x0c\xe9\x92\x41\x06\x7d\x4d\xe8\x31\x55\x34\xa6\x6e\xd0\xb8\xe3\x27\x5e\x91\xe4\x8e\x6a\xfd\xaa\x16\xf9\x80\x19\x49\x51\xcb\xb6\x4d\xbc\x87\x86\x5b\xc1\x2b\xfa\x89\x90\xdd\x71\x85\x6d\xbb\x24\xb4\xe2\x0b\x2a\x1e\x34\x45\x46\x78\xe8\x1b\xa4\x81\x08\xb6\xcf\x07\x1d\x61\xcd\x70\x5d\x22\xa4\x74\x03\x69\x1c\xf5\x9e\x97\xa1\x24\xcd\xf2\xe1\xd3\xce\x55\x53\x01\xa5\x83\x94\xe0\x19\x44\x5e\xd4\x72\x7d\xaa\xb1\x1d\x03\x49\xc2\x01\xeb\x7e\xce\x58\x58\xde\x09\x65\xbd\xae\x69\xce\xca\xe2\x25\x2d\xd9\x57\x5b\x6b\x76\xba\xdd\x20\xb0\x97\x9f\x7d\xfe\xf0\x3e\xd8\x16\xf4\xff\x50\xd5\x96\x79\x3f\x5f\x63\xf3\x99\x06\xc8\xcb\x83\x75\xb5\x0a\xa2\xe3\xd0\x8b\x85\x11\xf0\x90\x4c\xd8\x24\x40\x97\x21\xea\xc4\x8e\x6d\xb3\x08\xde\xb2\x89\x26\xcd\xde\xf2\x3f\xf3\xb4\x39\x61\x4b\x16\xe7\xcd\xf6\x86\x4a\xd2\xbc\xea\xf5\xcf\x4f\x8a\x6b\x09\x57\x21\xa8\x43\xed\x47\xfc\x76\x20\x83\xf2\x7a\x5c\xd9\xd9\xd7\xaa\x71\xc7\xbd\x22\xe7\x30\x28\xbf\xa9\x15\x05\xc7\xdd\x71\x1c\xc6\xfb\xce\x84\x11\xf1\x2e\xdf\xdf\xc5\x78\x86\xfa\x18\xee\xdf\x5d\x8b\x1f\x2c\x99\x9d\xc0\xdc\x11\x77\x68\x2a\x7c\xe2\x5b\x35\x49\x0e\xc0\x8b\x2f\x55\x48\xdd\x96\x6d\xe2\x88\x17\x84\x24\x8c\x22\xba\x1d\xb0\x68\xa8\xe3\x34\xe7\x93\xd3\x19\xb5\x2b\xb8\xc0\xff\xe0\x0d\x82\x13\x8f\xd0\xd5\xf5\x79\xc7\x92\x1c\xdd\x2a\xee\x2c\xea\x7a\x71\x4c\x2b\xf9\x79\x4a\x5b\xe0\xf1\x14\xfd\x7b\x57\x16\x79\x69\x0c\x7d\x5f\xff\xcb\x12\x5c\xe1\x9c\xe0\x4d\xd8\x7f\x44\xdb\x19\x92\xd5\x0b\xfc\x77\x1c\xbf\x02\x00\x00\xff\xff\x19\x4c\x16\x4a\x76\x07\x00\x00")
|
||||
var _templatesSimpleschemaDefaultsinitGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\xd2\x4f\x8f\xd3\x3c\x10\x06\xf0\x7b\x3f\xc5\xf3\x46\xda\x17\x7b\xb5\xa4\xf7\xa2\x3d\xa0\xae\x90\xf6\x86\x04\x5c\xf8\x23\xad\x69\x9c\x74\x90\x63\x97\xf1\x24\x62\x65\xf9\xbb\x23\x27\xe9\xb6\x74\x2f\x1c\x91\xe0\xe8\xcc\xf8\x19\xe7\xa7\x49\xe9\x25\xa8\x85\xf1\x0d\xea\xfb\xf8\x96\xa9\x27\xa1\xd1\x96\xc3\x76\x88\x12\xfa\x37\x81\x7b\x23\x62\x19\xca\x07\x81\x8a\xc2\xe4\xbb\x6d\xf0\x62\xc8\x47\xd4\x1f\x2d\x07\x54\xea\x73\x55\x69\x8d\x9c\x57\x28\x71\x96\x19\x9b\x5b\xa4\x84\xd1\xb0\x37\x7d\xc9\xbb\xcb\xf9\xce\xb6\x66\x70\x52\x7f\xf0\xbd\xe1\xb8\x37\xee\xbd\xfd\x21\xea\xd3\x97\xaf\x8f\x62\x55\x4a\x38\x30\x79\x69\x51\x5d\x7d\xaf\x50\x2f\xcd\xc8\x59\x6b\xbc\x9a\x22\xff\xbb\x85\x27\x87\xb4\x02\x80\x3e\x76\x65\x46\xdb\x4b\xfd\x6e\xbe\xa8\x2a\xf2\xa3\x71\xd4\xa0\x59\xee\x8e\xc6\x0d\x16\x6d\xe0\x8b\xa7\x20\xe7\x0d\xae\xc6\xea\xc6\x32\xeb\x29\xed\x60\x3c\xed\x54\x1f\x3b\x8d\xf5\x7a\x3e\xc5\xf2\x27\xb2\xb7\x88\x07\xbb\xa3\x96\x76\x46\x28\x78\x50\xc4\x32\x66\x05\xe4\x55\x01\xb4\x2e\xda\xd2\x5c\xdf\xc7\xd7\xcc\xe6\x71\x76\x58\x68\x03\x43\xcd\xbe\xdb\x3d\xb9\xe6\x57\xe5\xe3\xa7\x4b\x6b\x7d\x2a\x9d\x25\x9e\x64\xbf\xc5\xe0\x4f\x8c\x47\xc2\x87\x94\x9e\x08\x63\x05\x55\xba\x9e\x20\x75\xce\x0f\xfa\x06\xff\x3f\x93\x38\xd6\xff\x5c\xe3\xd9\xf2\xa8\x5c\x2c\xa7\x5d\x7c\x0e\xaa\x2f\x0a\x93\x5d\x59\x4b\xa4\xb4\xbe\x46\xdc\x87\xc1\x35\xfe\x85\xa0\xb3\x52\xc6\xb2\xdd\xa0\x1b\x0c\x37\xb8\x5e\xff\x13\x86\xf5\x4d\x59\xb4\x73\xec\x89\xf3\x7c\x65\x7f\xc3\x52\x2d\x0f\x8f\x90\x00\x67\x45\xc8\x77\x93\x27\x5a\xea\x06\xb6\x08\x83\xe8\xbf\x5d\xfc\xcc\xfb\x67\x00\x00\x00\xff\xff\xd4\x61\x99\x8a\x84\x05\x00\x00")
|
||||
|
||||
func templatesSimpleschemaDefaultsinitGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
_templatesSimpleschemaDefaultsinitGotmpl,
|
||||
"templates/simpleschema/defaultsinit.gotmpl",
|
||||
)
|
||||
}
|
||||
|
||||
func templatesSimpleschemaDefaultsinitGotmpl() (*asset, error) {
|
||||
bytes, err := templatesSimpleschemaDefaultsinitGotmplBytes()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/simpleschema/defaultsinit.gotmpl", size: 1412, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xa1, 0x40, 0xf1, 0x21, 0x40, 0xcf, 0xe0, 0xa4, 0xc3, 0x2d, 0x68, 0x7b, 0xa0, 0x7, 0xb2, 0xfa, 0xf3, 0x74, 0xa9, 0xbf, 0xce, 0x4b, 0x8d, 0x60, 0x2e, 0xbd, 0x1f, 0xe6, 0xd7, 0xb2, 0x52, 0x32}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesSimpleschemaDefaultsvarGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xb4\x94\x4f\x6f\xd3\x40\x10\xc5\xef\xfd\x14\x23\x23\x44\x5a\x15\xf7\x8e\xc4\x01\x25\x02\xe5\xc6\xa1\x5c\x10\x97\xa1\x1e\xdb\x03\xfb\x27\xcc\x8e\x03\x61\xb5\xdf\x1d\x6d\xed\x24\xdb\x24\x2d\xe9\xa1\x97\x28\xd1\x8e\xe7\xbd\xfd\xbd\x17\xc7\xf8\x16\xd6\x28\x0e\x2d\x41\xbd\x5c\xa4\xb4\xa0\x16\x07\xa3\x17\xf9\x80\x5b\xa8\x97\xe1\xb3\xb0\x65\xe5\x35\x41\x4a\x17\x00\xf9\x60\x25\xec\x14\x2a\xa8\x20\xa5\xf7\x31\x3e\xf8\x3d\x8d\x8c\xcf\xce\x87\xa0\xde\x7e\xf4\x62\x51\x95\x64\x3c\xde\x0d\x04\x15\x76\xdd\xdc\x3b\x45\x76\x01\xea\xaf\x24\x1e\xaa\xd9\xb7\xaa\xda\x0e\x8e\xa3\xf5\x27\x7f\xbb\x59\x65\xfd\xd9\x56\xac\x85\xea\xf5\xab\x75\x05\xf5\xe4\x17\x52\xba\x8c\xf1\xe6\x2a\xef\x6c\xad\x82\xe6\x79\x76\xac\x8c\x86\xff\x92\x80\xf6\xa8\xa0\xf8\x93\xc2\x24\x0b\x57\x37\x85\x1b\x32\x81\x0e\x44\xef\xdd\xa4\xf4\xff\xad\x42\xbf\x06\x16\x0a\xf0\xc5\x59\x94\xd0\xa3\xb9\xa5\x3f\x3a\xbb\xbc\x06\xaa\xbb\x1a\x16\xa8\x74\x7d\xff\xa9\x6c\xf3\xb7\x41\x50\xd9\xbb\x03\x03\xae\xd9\xc3\x2b\xdd\x3c\x17\x80\x50\x37\x18\x14\xe8\x7c\x1e\x9c\x92\x3b\x32\x3e\x69\x17\xca\x3b\xdd\x31\xb9\x0f\x22\xb8\xd9\x5e\xbf\xf1\xe0\xbc\x16\x0b\xa0\x15\x6f\x61\xe5\x43\xe0\xef\x86\xa0\x19\x3d\x04\x60\x07\x8e\x82\x52\x03\x98\x9f\x0f\xa5\x4e\xde\x3b\xef\xd9\x34\xc7\x9d\x3a\xab\x55\xc7\x5b\x1e\x69\xd7\x89\xfc\x76\xce\x47\xf2\x41\x05\x95\xba\x0d\xfc\x66\xed\x0f\x63\x7b\xaa\x18\x07\x69\xc4\x38\xde\x73\x59\x90\x2d\x02\x39\x3f\x8f\x77\x10\xd8\xae\x0c\x41\x30\x7c\x77\x32\xa9\xc7\x5a\x52\xf2\xd8\x66\xf6\x3c\xa2\xe7\x83\xfa\x11\xbc\xab\x77\xb4\xf6\xa4\x4e\x55\xb6\x94\x8a\xf1\x01\xb3\xfc\x7f\xea\xfd\x60\x1a\xf7\x46\xa1\xc7\x8c\xa3\x47\xdd\x23\xb8\xeb\xc9\x22\x70\x00\x62\xed\x49\x0a\x6c\x5e\x46\xde\x4f\xd5\xf7\xe4\x4b\xea\x85\x1c\x14\xfa\xff\x02\x00\x00\xff\xff\xe5\xf4\x97\x06\x49\x05\x00\x00")
|
||||
|
||||
func templatesSimpleschemaDefaultsvarGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
_templatesSimpleschemaDefaultsvarGotmpl,
|
||||
"templates/simpleschema/defaultsvar.gotmpl",
|
||||
)
|
||||
}
|
||||
|
||||
func templatesSimpleschemaDefaultsvarGotmpl() (*asset, error) {
|
||||
bytes, err := templatesSimpleschemaDefaultsvarGotmplBytes()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/simpleschema/defaultsvar.gotmpl", size: 1353, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xe2, 0xe2, 0x60, 0x51, 0xf9, 0x3, 0xda, 0x54, 0xe, 0xff, 0x69, 0x27, 0xe6, 0x28, 0xdc, 0xd4, 0xbc, 0x4f, 0xac, 0xdf, 0xe8, 0xdc, 0x1, 0xdb, 0xe4, 0x2f, 0x62, 0xa0, 0xbb, 0x71, 0x22, 0x35}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesStructfieldGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xcc\x94\x31\x6b\xfb\x30\x10\xc5\x77\x7f\x8a\x43\xfc\x87\x7f\x86\x38\x7b\xc7\xb6\x14\xb2\x94\x42\x42\xe7\x1c\xd2\x39\x55\xb1\x25\x21\x5d\x0a\xa9\xd0\x77\x2f\x72\xe2\xc4\x06\xc7\xa1\x94\x92\x6e\xc6\xa7\xbb\xdf\xbd\xe7\x67\xc5\x08\x8a\x2a\x6d\x08\x44\x60\xbf\x93\x5c\x69\xaa\x95\x80\x94\x0a\x80\x18\xe7\xa0\x2b\x30\x96\xe1\x5f\xb9\x0c\xf7\x18\x68\xbd\x77\x04\xf3\xb6\x0a\xb0\x58\x40\x8c\xc0\xd4\xb8\x1a\x99\x40\x28\x2b\x03\x7b\x6d\xb6\x02\x4a\x38\x9e\xc9\x33\xce\x27\x9c\xb7\x8e\x3c\xef\x5f\xb1\xd6\x0a\x59\x5b\xf3\x68\xe5\xaa\xeb\x39\x41\xc9\xa8\x94\x8a\x18\xc1\x61\x90\x58\xeb\x4f\x82\xf2\x19\x1b\x4a\x69\x08\x0c\xf2\x8d\x1a\xcc\x3b\x1d\x88\xb9\x5a\xbe\x78\x6d\x78\x8d\xdb\x00\x87\x19\x64\x54\x7e\x2a\xf2\xe0\x4e\x2b\xef\x5c\x4d\x37\x96\x7a\x5e\x2d\x37\x7e\x57\xe9\xe6\x3d\x58\x73\x27\xe6\xa2\x38\xae\x5e\x3e\xec\x02\xdb\x66\x8d\xdb\xce\x88\xfe\x8b\x13\x6c\x93\xa5\xc8\xb6\x02\x81\xbc\x6e\x99\xfe\x92\x4f\xbd\x4c\x2c\x2b\x94\xf4\x07\x82\x01\x17\x92\xf1\x7f\x36\xed\x58\xb1\x22\x1e\xed\x9b\xec\x9a\x0d\x3e\xd3\x48\x7e\x6e\x69\x0b\x5c\x4f\xd1\xef\xbb\x32\xc8\x8b\xf3\xfa\x63\xfc\x1e\x91\xd8\x50\x1f\xf0\x94\xeb\x57\x76\x9b\x80\x8c\xfe\xc0\x3f\x63\x7c\x05\x00\x00\xff\xff\xaa\xad\x95\xa9\x0b\x05\x00\x00")
|
||||
|
||||
func templatesStructfieldGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -802,8 +868,8 @@ func templatesStructfieldGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/structfield.gotmpl", size: 1910, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x52, 0x92, 0x5, 0x7b, 0xfd, 0x5c, 0x15, 0xc8, 0x62, 0x64, 0x3a, 0xd1, 0xd4, 0x9, 0xca, 0xfd, 0x38, 0x1d, 0xa9, 0x4c, 0xdc, 0x5b, 0x30, 0xb9, 0x5a, 0xc6, 0xd8, 0x22, 0xa8, 0xd6, 0xb8, 0x6f}}
|
||||
info := bindataFileInfo{name: "templates/structfield.gotmpl", size: 1291, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x7f, 0xa1, 0x92, 0x88, 0xe4, 0xd, 0x48, 0xd6, 0x1e, 0xcf, 0x48, 0xdd, 0x6f, 0x8, 0xce, 0x2, 0x63, 0x13, 0x23, 0x1d, 0x37, 0x21, 0x88, 0xb4, 0x66, 0xd8, 0x1f, 0x70, 0x3f, 0x27, 0x88, 0xc9}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
@@ -827,7 +893,7 @@ func templatesSwagger_json_embedGotmpl() (*asset, error) {
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesValidationCustomformatGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xcc\x91\xcd\x4a\x04\x31\x10\x84\xef\x79\x8a\x32\x20\xcc\xc0\x9a\x07\x50\xf6\xe0\x41\x41\x10\x14\x56\xbc\x37\x6e\x67\x0c\xc4\xcc\xd8\xc9\xfa\x43\x93\x77\x97\xcc\x8e\xe0\x61\x0e\x1e\xf7\x56\x24\x55\x95\xfa\x88\xea\x05\x82\x87\xbb\xcb\xd7\x31\x50\xe6\x3d\x6a\x35\x68\x47\x2c\x82\xcb\x2d\x3e\x28\x86\x3d\x15\x76\xb7\xa3\xbc\x51\x79\xf0\x9d\xea\x9c\x78\xa4\xf2\x8a\x5a\x55\xff\x4a\x8e\x99\x51\xab\xb5\x4d\xa7\x56\xb6\x81\x2a\x26\x09\xa9\x78\xd8\xf3\x77\x0b\x77\x3f\xbe\x50\x09\x63\x5a\xbd\xdc\x7d\xd2\x30\xb0\x1c\x1f\xfb\x75\xb8\x65\xdb\xd3\xf7\xd4\xda\x3b\x55\xf7\x4c\xf1\xc0\x37\x5f\x93\x70\xce\xc7\xae\xde\xed\x8a\x84\x34\x74\xfd\x06\x7e\x8e\xe7\xfe\x6a\xa6\x38\xdb\x22\x85\x08\x35\x0d\x76\x59\x78\x6a\x8c\x2b\x40\xff\xe4\x49\xcb\x97\x09\x97\x83\xa4\x66\x30\x40\x35\x3f\x01\x00\x00\xff\xff\x01\xdb\x67\xc9\xd9\x01\x00\x00")
|
||||
var _templatesValidationCustomformatGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x6c\x8e\x41\xca\xc2\x30\x10\x46\xf7\x3d\xc5\xf7\x07\x7e\x50\x90\x1c\x40\xe9\xd6\x95\xa0\x50\x2f\x10\x6c\x52\x07\x6a\xa2\xd3\x51\x17\xc3\xdc\x5d\x1a\x11\x5c\xb8\x7b\xbc\x37\x30\x1f\x25\x44\x66\xac\x5b\x3c\xc2\x48\x7d\x90\xe8\xb7\x85\x2f\x41\xf6\x69\xa1\x0a\x4a\xf0\x87\x20\x67\x98\xa9\x7e\x63\x1c\xa7\x08\x33\xe7\x66\xce\x3d\xcc\x56\x50\xc5\x95\x29\x4b\x82\xfb\xbf\x39\xf8\x5d\x39\x05\xa1\x92\x7f\xc6\xee\x19\x86\x21\xf2\xfb\xd9\xe7\xc2\x1f\x4b\x27\x4c\x79\xa8\x22\xd5\x36\x2d\x37\x75\xe2\x5f\x8b\x4c\x23\xb4\x01\x38\xca\x9d\xf3\x6c\x1b\x6b\x5e\x01\x00\x00\xff\xff\x86\x82\x64\xad\xc2\x00\x00\x00")
|
||||
|
||||
func templatesValidationCustomformatGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -842,12 +908,72 @@ func templatesValidationCustomformatGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/validation/customformat.gotmpl", size: 473, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x21, 0x62, 0x2d, 0xb8, 0x17, 0x7, 0xcb, 0xa3, 0xb, 0xe0, 0xa4, 0xc4, 0xc7, 0x3c, 0xc4, 0x11, 0x74, 0x28, 0x61, 0x83, 0x41, 0x6f, 0xe1, 0x5, 0x73, 0xcb, 0x2f, 0x47, 0xe0, 0xa3, 0x22, 0xeb}}
|
||||
info := bindataFileInfo{name: "templates/validation/customformat.gotmpl", size: 194, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xb9, 0x99, 0xde, 0x16, 0x1f, 0x38, 0xaf, 0xe8, 0x4d, 0xe9, 0x62, 0xf1, 0x21, 0xc7, 0xc4, 0x36, 0x27, 0xe2, 0xb7, 0xa0, 0x6b, 0x57, 0x5c, 0x6c, 0xb9, 0x3a, 0x30, 0x57, 0x56, 0x4e, 0x97, 0xe7}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesValidationPrimitiveGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xe4\x95\xcf\x6e\xd3\x40\x10\xc6\xef\x79\x8a\xc1\x08\xc9\x46\xc8\x27\xc4\x01\xd4\x03\x2a\x41\x44\x2a\x50\xa9\x88\x73\x97\x64\xec\x8e\xb4\x1e\xa7\xb3\xe3\x90\x6a\xb5\xef\x8e\xd6\xf1\x3f\x41\x13\x61\x91\x53\xb9\x79\xf7\xdb\x9d\x99\xef\xe7\x19\xdb\x7b\x2a\x20\xff\x4c\x7c\x85\x5c\xea\x5d\x08\x0b\x2a\x00\x45\xe0\xed\x05\xec\x8c\xa5\x8d\x51\x1c\xe5\xd4\x7b\x88\xe7\xaf\x8d\xde\x41\x08\xde\x4f\x1e\xd1\x3a\x0c\x21\x49\xbc\x47\xde\x84\xf0\x0a\xbc\x87\xad\x10\x6b\x01\xc9\x8b\xfb\x04\xf2\xab\x7a\x6d\x94\x6a\x86\x4e\x8c\x81\x56\xee\x4b\x63\xad\xf9\x61\x11\x42\x48\x5f\x7a\x0f\xc8\x9b\x36\x5c\xfe\xdd\xd8\x06\x97\xfb\xad\xa0\x73\x54\x73\x9b\xed\x8f\x2b\xd9\xe4\x46\xa7\x5e\x36\x4e\xeb\xea\x63\x2d\x95\x51\x45\x81\x10\xf2\x1b\x15\xe2\x32\x1d\x0f\xc7\xfc\x53\xd3\xd9\xbb\xd6\xf3\xb3\x0b\x60\xb2\xe0\x17\x00\x82\xda\x08\xc7\xdd\x45\x58\x74\x96\x16\x1d\x2c\xb3\x3f\x09\xab\x97\x9f\x16\xac\xd1\xf4\x2c\x58\xd7\x6d\x5c\x7e\x1c\x55\x27\x3e\x1d\x50\xb7\xde\x8f\x8e\x6f\xe7\x75\x15\x31\x55\x4d\x75\x74\x00\xa3\x78\xa8\x06\xef\x21\xbf\xf9\x69\xca\x12\xe5\xdb\xc3\x16\x21\x21\x56\x2c\x51\x12\x08\x61\xc5\x3a\x94\x73\x6e\xac\xa7\xf2\xd2\x21\xaf\x75\x11\x5f\x61\x6b\x33\x96\xf1\xe6\x75\xfa\x18\xe3\xd3\x6f\x25\xeb\x27\xf4\xc0\xa4\x5d\x2d\xf7\x6b\xdb\x38\xda\xe1\xb0\x3d\x77\x6c\x4f\x00\x3e\x88\xff\x1d\xe0\x9e\xc9\x6f\x80\xfb\xed\x79\x80\x1b\xab\xb4\xb5\xf8\xb5\x38\xc2\x78\xd0\xcf\x07\xae\x25\xf1\x2f\x00\x26\x35\xcf\x32\xbb\xe4\x63\xad\x14\x95\x4b\xe3\xf0\xdc\xdd\x61\x78\x03\x29\xd7\x1a\x5d\xbe\x17\x31\x0f\x59\xb7\xfc\x64\xdc\x07\x72\x6b\xa1\x8a\xd8\x68\x2d\xd9\x70\x6c\xc5\x8a\x52\x98\x35\x66\xb3\xd0\xcc\xfe\x3b\x8c\xb5\x3f\xdf\x25\x3d\x9b\xc9\xd7\xb8\x45\xb2\x8a\x8d\x6b\xac\xc3\xb1\x8f\x55\x1a\x1c\x02\xfd\x25\xfe\x5f\x01\x00\x00\xff\xff\xaa\xd3\x6b\x2e\xb1\x08\x00\x00")
|
||||
var _templatesValidationMaximumGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xdc\x94\x4f\x4b\xf3\x40\x10\xc6\xef\xf9\x14\xf3\x2e\xbc\x90\x88\xee\x49\x3c\x28\x3d\x78\xe8\xa1\xa0\xd2\x83\xf5\xbe\x36\x13\x3b\xb0\xdd\xa4\xfb\xa7\xa4\x2c\xfb\xdd\x65\x63\xd2\xa6\x0a\x5a\x62\xb1\xe8\x6d\xb3\xc9\xf3\x30\xbf\xe1\x47\xbc\xbf\x00\x2a\xa0\xd4\x90\x2e\x84\x99\x6a\x2c\xa8\x06\x3e\x53\x39\x6a\xb9\x21\xf5\xf2\xb8\xa9\x10\x18\x29\xcb\x32\x08\x21\x01\x68\x03\x42\xe5\x5f\x25\xae\x2e\x59\x06\xa9\x2a\x2d\xf0\x89\xb9\x95\x24\x0c\xe6\x4d\x09\x15\x80\x5a\xc3\xf5\x08\xd6\x42\x52\x2e\x2c\xf2\x7b\x51\xd3\xd2\x2d\x27\xca\xa6\xde\xc7\x7e\x3e\x15\x76\x01\x21\x78\xdf\x3f\xa2\x34\x08\x21\x30\x16\xcf\x2a\x87\x10\xce\xc1\x7b\xa8\x34\x29\x5b\x00\xfb\xbf\x62\xc0\xef\xca\xb9\xb0\x54\xaa\xee\x65\x2c\x9b\x98\x07\x27\xa5\x78\x96\x31\x7d\xb6\x0d\x7b\xcf\x9f\x84\x74\x38\xae\x2b\x8d\xc6\xec\x42\xdd\x3c\xdd\xe3\xb8\x9e\x4b\x67\x68\x8d\xbb\xfb\xec\xa6\x81\xf8\x37\x02\x45\x12\x7c\xbb\x99\x76\xc0\x9f\x44\x6c\x36\x9d\x0e\x00\xcd\xbe\x47\xda\x14\x27\x7d\xe8\xad\x1c\x9f\x78\xe1\xa2\x4a\x6f\x1f\x1f\xec\x92\x1b\x26\xd3\x8c\x7e\xb3\x4d\x87\xfa\x74\x7c\x4a\x77\x02\xa3\xf6\x9c\xda\x47\x7f\x2f\x0a\xae\x3e\x1a\x52\xc8\x52\x0c\x51\xe4\xef\xeb\x71\x5c\xc2\x76\xcf\xa7\x77\xa3\xf7\xf3\xe9\xee\x35\x5a\xa7\x55\x0c\x27\x21\x79\x0d\x00\x00\xff\xff\x8e\xc3\xec\x31\xd7\x06\x00\x00")
|
||||
|
||||
func templatesValidationMaximumGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
_templatesValidationMaximumGotmpl,
|
||||
"templates/validation/maximum.gotmpl",
|
||||
)
|
||||
}
|
||||
|
||||
func templatesValidationMaximumGotmpl() (*asset, error) {
|
||||
bytes, err := templatesValidationMaximumGotmplBytes()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/validation/maximum.gotmpl", size: 1751, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xaf, 0x39, 0xcc, 0x19, 0xf5, 0x15, 0xf6, 0x52, 0xcb, 0x71, 0x12, 0x92, 0x7c, 0xf9, 0x55, 0x7c, 0xf8, 0x86, 0x5d, 0x37, 0xcc, 0x70, 0x31, 0x51, 0x8d, 0x32, 0x64, 0x73, 0x82, 0xfc, 0xd7, 0xd1}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesValidationMinimumGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xdc\x94\x4d\x4b\xc3\x40\x10\x86\xef\xf9\x15\xe3\x82\x90\x88\xee\x49\x3c\x28\x3d\x78\xe8\xa1\xa0\xd2\x83\xf5\xbe\x36\x13\x3b\xb0\x9d\xb4\xfb\x51\x5a\x96\xfd\xef\xb2\x25\xe9\x87\x42\x29\xb1\x58\xf4\xb6\xd9\xe4\x7d\x99\x67\x78\x48\x08\x37\x40\x15\x4c\x94\x1d\x1a\xac\x68\x09\x72\xc4\x25\x1a\xbd\x22\xfe\x78\x5d\xcd\x10\x04\xb1\x13\x10\x63\x06\xd0\x7c\xab\xb8\x84\xfc\x70\xe0\xee\x56\x14\x90\x73\xed\x40\x0e\xec\xa3\x26\x65\xb1\x2c\x52\x09\x55\x80\xc6\xc0\x7d\x0f\x16\x4a\x53\xa9\x1c\xca\x67\x62\x9a\xfa\xe9\x80\x5d\x1e\x42\xea\x97\x43\xe5\x26\x10\x63\x08\xbb\x47\xd4\x16\x21\x46\x21\xd2\x99\x4b\x88\xf1\x1a\x42\x80\x99\x21\x76\x15\x88\xcb\xb9\x00\xf9\x54\x8f\x95\xa3\x9a\xdb\x97\xa9\x6c\x60\x5f\xbc\xd6\xea\x5d\xa7\xf4\xd5\x26\x1c\x82\x7c\x53\xda\x63\x7f\x39\x33\x68\xed\x36\xd4\xce\xd3\x3e\xf6\x97\x63\xed\x2d\x2d\x70\x7b\x5f\x3c\xac\x21\x2e\x7a\xc0\xa4\x21\x34\x9b\x69\x06\xfc\x4d\xc4\xf5\xa6\xf3\x0e\xa0\xc5\xcf\x48\xd7\xc5\xd9\x2e\xf4\x46\x8e\x03\x5e\xf8\xad\x49\x47\xbb\xe4\xbb\xc9\x34\xa2\xbf\x6c\xd3\xb1\x3e\x9d\x9e\xd2\x9f\xc1\xa8\x3d\xa7\xf6\xd1\xbf\x8a\x82\xf3\xef\x86\x54\xba\x56\x5d\x14\xf9\xff\x7a\x9c\x96\xb0\xd9\xf3\xf9\xdd\xd8\xf9\xf9\xb4\xf7\x06\x9d\x37\x9c\xc2\x59\xcc\x3e\x03\x00\x00\xff\xff\x40\xcf\x39\x3c\xd2\x06\x00\x00")
|
||||
|
||||
func templatesValidationMinimumGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
_templatesValidationMinimumGotmpl,
|
||||
"templates/validation/minimum.gotmpl",
|
||||
)
|
||||
}
|
||||
|
||||
func templatesValidationMinimumGotmpl() (*asset, error) {
|
||||
bytes, err := templatesValidationMinimumGotmplBytes()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/validation/minimum.gotmpl", size: 1746, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x8c, 0xef, 0x7c, 0x4e, 0xab, 0x95, 0x1, 0x48, 0x54, 0x55, 0xcc, 0xfa, 0xe5, 0xfb, 0x31, 0x50, 0x75, 0x8e, 0xe5, 0x63, 0xfc, 0x5, 0xd9, 0xa0, 0x8f, 0x2f, 0x49, 0x25, 0x8, 0x1d, 0x8c, 0xc5}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesValidationMultipleofGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xdc\x94\x3f\xaf\xd3\x30\x14\xc5\xf7\x7c\x8a\x43\x24\xa4\xa4\x2a\x79\xcb\xd3\x1b\x40\x6f\x60\x60\x88\xc4\x9f\x0e\x94\xdd\x6d\xae\x5b\x0b\x63\xa7\xf6\x4d\xd5\xca\xf2\x77\x47\x4e\x53\x48\x61\xa0\xad\x4a\x25\xd8\xac\xf8\x9e\x93\xfb\xbb\xf7\xc8\x21\xbc\x82\x92\x10\xa6\x41\xb1\x16\x7e\xe6\x48\xaa\x1d\xaa\xb9\x69\xc8\xe9\xbd\x32\xab\xcf\xfb\x96\x90\x2b\xc3\x79\x89\x42\xf9\xda\x30\xad\xc8\xa1\xfa\xd0\x69\x56\xad\xa6\x4f\xb2\x44\x8c\x21\x3c\x4c\x92\x0f\xaf\x09\x9c\x14\xca\x43\x18\xa8\x43\xf5\x14\x8b\x8e\xfb\xbb\x6f\x83\x0a\x52\x2c\xd9\xba\x54\x66\x2c\x4f\x21\x85\xd6\x58\x88\xe5\x57\xb0\xed\x0b\xa5\xb6\x82\x9f\x1e\xb1\x25\xe7\x95\x35\xb0\x07\xef\xad\xd0\xaa\x11\x49\x39\x79\x88\x31\x03\xce\xef\xff\xe9\x31\x11\x18\xcb\xa8\x6a\xff\x56\x2b\xe1\xa9\x49\xad\x67\x4a\x82\x9c\xc3\xeb\xe7\xa3\x3b\x8d\xe0\x6a\xc3\x45\x08\xe9\x17\xd5\x4c\xf0\xba\x47\x1d\x1f\x49\x7b\x42\x8c\x79\x9e\xce\xa6\x41\x8c\x53\x84\x80\xd6\x29\xc3\x12\xf9\xcb\x4d\x8e\xea\xbd\x5d\x0a\x4e\x10\xc3\x65\x32\xab\xfd\xc7\x4e\x6b\xb1\xd0\x49\x3d\xf9\x21\x0e\xa1\xfa\x22\x74\x47\xef\x76\xad\x23\xef\x7f\x8a\x46\x2d\x21\xc6\xf2\x4d\xdf\xf2\x8b\x67\x18\xa5\x11\x86\x39\x0c\xbd\xdc\x19\xa8\x1f\x6d\x71\x05\x56\x79\x36\x57\xef\x91\x8d\x11\xcf\x5e\x7c\xf7\xa7\xe4\x66\xc0\x45\x66\xd7\xc5\x68\xae\xfe\x91\x1c\x5d\x90\xa4\xdb\x33\x75\x7f\x37\x4b\x27\x69\x3a\x05\xfd\x35\x04\xb4\xf9\x7d\xfb\xc3\x93\x74\xcd\xfa\xff\xb7\xd5\xdf\x96\x67\x18\xec\x5d\xf7\x3e\x7a\x52\x8e\xdf\x1d\x71\xe7\x4c\x12\x67\x31\xfb\x1e\x00\x00\xff\xff\xfe\x0a\xb4\x3e\x18\x07\x00\x00")
|
||||
|
||||
func templatesValidationMultipleofGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
_templatesValidationMultipleofGotmpl,
|
||||
"templates/validation/multipleOf.gotmpl",
|
||||
)
|
||||
}
|
||||
|
||||
func templatesValidationMultipleofGotmpl() (*asset, error) {
|
||||
bytes, err := templatesValidationMultipleofGotmplBytes()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/validation/multipleOf.gotmpl", size: 1816, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xde, 0xc2, 0xb4, 0xea, 0x79, 0x1, 0xdf, 0x9a, 0x76, 0xea, 0x7a, 0xbe, 0x8a, 0x8c, 0x4, 0xa9, 0x1a, 0x0, 0x9e, 0xf4, 0x1, 0x39, 0x31, 0xe, 0x7d, 0x48, 0x94, 0x63, 0x3, 0xbf, 0xd0, 0xa4}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesValidationPrimitiveGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xb4\x92\x51\x6b\xd5\x40\x10\x85\xdf\xf3\x2b\xc6\x88\x70\x23\x92\x1f\xa0\xf4\x41\x6b\xc5\x40\xd5\x82\xe2\x73\xc7\xdc\x49\x3b\x74\x33\x1b\x77\x27\xa5\xb2\xcc\x7f\x97\x4d\xf7\xde\x5e\x21\x54\x0b\xde\xb7\xec\x9e\x33\x67\xbf\xec\xd9\x94\x78\x80\xf6\x13\xcb\x39\xc9\x95\x5e\x9b\x55\x3c\x00\x85\x00\xaf\x4f\xe0\x16\x1d\x6f\x51\xe9\x41\xde\xa4\x04\xd9\x7f\x81\x7a\x0d\x66\x29\x1d\x7c\x92\x8b\x64\x56\xd7\x29\x91\x6c\xcd\x5e\x41\x4a\x30\x05\x16\x1d\xa0\x7e\xf1\xb3\x86\xf6\xdc\xf7\xa8\xec\x05\x8a\xd8\x7e\xf3\x5f\x35\xb0\x5c\x95\x8d\x43\x8a\xe6\xcd\x02\xf1\xec\x04\x84\x1d\xa4\x0a\x20\x90\xce\x41\xf2\x6e\x65\x55\x39\xa3\x2a\xf4\x78\xf7\x28\xfd\x4e\x3e\x32\xfd\x03\xc5\x93\xe8\x2f\x50\x95\x82\xac\xb3\x17\xf1\x88\xe4\x97\x29\x51\xec\x71\xa2\x77\xd8\xdf\x28\xf7\x37\xf1\x00\xe9\xf2\x69\x3d\xb0\xf0\x38\x8f\x66\x15\xe4\x73\x94\xc6\xc9\xa1\x12\xd4\xe5\x77\xd8\x4b\xb1\xd4\xd0\x82\xad\xd4\xf8\xd7\xf1\x7b\xcb\xfa\xf8\xec\x94\x27\x47\x5f\x86\x47\x13\xf6\xae\xd5\x90\x33\x59\x00\x56\x9a\xc8\xca\x29\x46\xfa\xaf\x55\xf0\x00\x28\x5b\xd8\x88\x57\x68\xbb\xf8\x36\x04\xfc\xd5\x94\xe5\x47\x8c\xef\x39\xf6\x81\x47\x16\x54\x1f\x9a\xbd\xad\x13\xa5\x30\x60\x4f\x4d\x5e\x7d\x9e\x9d\xc3\x1f\x8e\xc0\xec\x65\x4a\x40\xb2\x5d\x58\xda\xef\xe8\x66\x3a\xbb\x9b\x02\xc5\xc8\x5e\x16\xd4\x0c\xde\xc5\xd3\x39\xaa\x1f\x3f\xf8\x30\x2e\x3d\x83\x59\x7b\xff\x20\x36\xcd\x3e\xe0\x4f\xf6\xe7\xb7\xf5\xee\x6e\x76\xdc\x6d\x17\x97\x2b\xe9\xc0\x6c\x40\x17\x29\x8f\xba\x98\x31\x34\xcc\xb4\x0f\xfa\xc7\x17\xf4\x3b\x00\x00\xff\xff\x64\x29\xc0\xde\x88\x04\x00\x00")
|
||||
|
||||
func templatesValidationPrimitiveGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -862,12 +988,12 @@ func templatesValidationPrimitiveGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/validation/primitive.gotmpl", size: 2225, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xa5, 0xc1, 0x1f, 0x2b, 0x1c, 0x3c, 0xf9, 0xf1, 0x51, 0xcb, 0xc2, 0xbe, 0xbc, 0x41, 0xca, 0x4d, 0x31, 0x2f, 0x60, 0xf, 0x71, 0x54, 0xaa, 0x40, 0x1b, 0x71, 0xc4, 0xa8, 0xaa, 0xdb, 0xfc, 0x22}}
|
||||
info := bindataFileInfo{name: "templates/validation/primitive.gotmpl", size: 1160, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x35, 0x51, 0x4f, 0x1b, 0x47, 0xcc, 0x6e, 0x7b, 0x5, 0xd4, 0x8f, 0xb4, 0x2c, 0x3f, 0x55, 0xd2, 0xab, 0xda, 0xe3, 0xdf, 0x9c, 0x14, 0x22, 0xa2, 0xb5, 0x9b, 0xe2, 0x76, 0xa5, 0x82, 0xb2, 0x1e}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
var _templatesValidationStructfieldGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x7c\x92\x41\x6b\xfb\x30\x0c\xc5\xef\xf9\x14\x22\xf0\x3f\xfe\xd7\x7b\x19\xbb\x6c\x1d\x14\x36\x32\x56\xb6\xbb\xa9\x95\x4c\x90\x28\xa9\x63\x77\x2d\x26\xdf\x7d\xc4\x76\x13\x27\x24\xbd\xf9\xe9\xe9\xf7\x24\x1b\x5b\x0b\x12\x73\x62\x84\xb4\x51\x75\x83\x4a\x5f\xbf\x45\x49\x52\x68\xaa\xf9\xa5\x3e\x1e\xb4\x22\x2e\x52\xe8\xba\x24\xb1\xf6\x3f\x50\x0e\x0f\x9f\x78\x32\xa4\x50\xf6\xc5\xcd\x06\x6e\x72\x0b\x5a\x19\x74\x5d\xc8\x72\x46\x08\x99\x71\x79\x1d\x08\x21\xa1\xd7\x77\x90\x77\x71\xa1\xca\x54\x81\x08\x6a\x0b\xd6\x3a\x77\x77\x39\x96\xa6\xa5\x33\x8e\x6d\x8f\xbd\xe7\x53\xac\x9d\xf0\x8b\xf1\xc4\x71\xbc\x57\x0b\xf1\x43\xdb\xd3\x2c\x7e\xe4\x17\xe3\x4d\xa9\xa9\x29\x31\xcb\x6f\x13\x42\x01\xb2\xdc\x4d\x99\x75\xac\xbc\xc0\x1b\x72\xa1\x7f\xc6\x37\x00\x5f\x08\x09\xb1\xbf\x72\xc7\x69\x00\xf1\x34\x20\xf6\x97\x02\x3e\x84\xd6\xa8\x38\xe0\x41\x79\x36\xb2\x56\x76\xdf\x6b\xac\xda\x68\x75\xa7\x87\xcd\x07\x77\x65\xf1\x09\x4d\x3c\xa1\x23\x77\x89\xfe\x62\x3a\x19\x8c\x03\x7c\xe5\xce\x67\xdb\xb7\xcf\xa6\xd5\x75\xf5\x5a\xab\xca\x5d\x2c\x80\x5e\xfb\xb1\x87\x5f\x51\x14\xa8\x7c\x69\x6d\xf6\x8e\x87\x3f\xd5\x1f\x1d\xd9\x28\x62\x9d\x43\xfa\xef\x9c\x8e\x0d\x11\x1c\x8e\x5d\x97\xfc\x05\x00\x00\xff\xff\xa2\xaa\xcd\x0b\x8d\x03\x00\x00")
|
||||
var _templatesValidationStructfieldGotmpl = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x7c\x93\x5f\x6b\x83\x30\x10\xc0\xdf\xfb\x29\x0e\x61\x8f\x5b\xdf\xcb\xd8\xcb\xd6\x41\x61\xa3\x65\x65\x7b\x0f\xf5\x74\x07\x7a\xda\x98\x74\x2d\xc1\xef\x3e\x34\xa9\x26\xd6\xf4\xcd\xfb\xf3\xfb\xdd\x25\x44\x63\x20\xc5\x8c\x18\x21\xa9\x65\x55\xa3\x54\x97\x1f\x51\x50\x2a\x14\x55\xfc\x56\x1d\xf6\x4a\x12\xe7\x09\xb4\xed\x62\x61\xcc\x23\x50\x06\x4f\x5f\x78\xd4\x24\x31\xed\x92\xcb\x25\x5c\xc3\x15\x28\xa9\xb1\xef\x42\x4e\x27\x84\x48\xb7\x5c\x5c\x06\x42\xa4\xd0\xc5\x77\x90\x4f\x71\xa6\x52\x97\x8e\x70\xd1\x0a\x8c\xe9\xab\xeb\xf3\xa1\xd0\x0d\x9d\x70\x6c\x7b\xee\x6a\xd6\x62\x4c\xc0\xcf\xea\x89\x7d\xbd\x8d\x66\xf4\x43\xdb\xcb\x44\x3f\xf2\xb3\x7a\x5d\x28\xaa\x0b\xdc\x66\xd7\x09\x2e\x01\xdb\xac\x9f\x32\xe9\x88\xdc\xc0\x07\x72\xae\x7e\xc7\x3b\x00\x9b\x70\x06\xbf\x1e\x39\x63\x28\x20\x0e\x05\x7e\x7d\x4e\xb0\x13\x4a\xa1\x64\x87\xbb\xc8\xb2\x5e\x29\xb2\xfb\x46\x61\xd9\x78\xab\xf7\xf1\xb0\xf9\x50\x8d\x2c\x1e\xd0\xc4\x01\xed\x55\x23\xf4\xce\x3e\x65\x42\x5f\x31\x26\x07\x4f\xd8\x17\x39\xc8\xad\x4c\x9c\x6f\x65\xd3\xbe\x39\xd9\x37\xd3\x51\xa3\x7f\x34\x9b\xb9\xf3\x1b\x6c\x9a\x57\xdd\xa8\xaa\x7c\xaf\x64\xd9\x5f\xb9\x03\x6d\x6c\x67\xef\xff\x44\x9e\xa3\xb4\xa9\xd8\xec\x35\x0f\xaf\xbd\xfb\xec\xc9\x5a\x12\xab\x0c\x92\x87\x53\x32\x36\x78\xb0\xfb\x6c\xdb\xc5\x7f\x00\x00\x00\xff\xff\x51\x78\x39\xe4\x27\x04\x00\x00")
|
||||
|
||||
func templatesValidationStructfieldGotmplBytes() ([]byte, error) {
|
||||
return bindataRead(
|
||||
@@ -882,8 +1008,8 @@ func templatesValidationStructfieldGotmpl() (*asset, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
info := bindataFileInfo{name: "templates/validation/structfield.gotmpl", size: 909, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xf6, 0x13, 0x95, 0x70, 0x16, 0x59, 0x7, 0x37, 0x93, 0xb, 0x23, 0xc4, 0x1f, 0xd2, 0xb4, 0x7, 0x7, 0x84, 0xf7, 0xb2, 0x67, 0x1b, 0x9d, 0x7f, 0x24, 0x5b, 0x50, 0x51, 0x88, 0x64, 0xb0, 0xaa}}
|
||||
info := bindataFileInfo{name: "templates/validation/structfield.gotmpl", size: 1063, mode: os.FileMode(0644), modTime: time.Unix(1482416923, 0)}
|
||||
a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x1b, 0x49, 0x4f, 0x3d, 0xe9, 0x1a, 0xb7, 0x39, 0x75, 0x84, 0x6, 0xd8, 0x9, 0xa, 0x6c, 0x86, 0xb7, 0xef, 0x10, 0x2e, 0x1e, 0xfc, 0xab, 0xe9, 0xbf, 0xb9, 0xf0, 0x64, 0x65, 0xda, 0xe5, 0x7d}}
|
||||
return a, nil
|
||||
}
|
||||
|
||||
@@ -988,6 +1114,7 @@ var _bindata = map[string]func() (*asset, error){
|
||||
"templates/contrib/stratoscale/server/server.gotmpl": templatesContribStratoscaleServerServerGotmpl,
|
||||
"templates/docstring.gotmpl": templatesDocstringGotmpl,
|
||||
"templates/header.gotmpl": templatesHeaderGotmpl,
|
||||
"templates/markdown/docs.gotmpl": templatesMarkdownDocsGotmpl,
|
||||
"templates/model.gotmpl": templatesModelGotmpl,
|
||||
"templates/schema.gotmpl": templatesSchemaGotmpl,
|
||||
"templates/schemabody.gotmpl": templatesSchemabodyGotmpl,
|
||||
@@ -1012,9 +1139,14 @@ var _bindata = map[string]func() (*asset, error){
|
||||
"templates/server/responses.gotmpl": templatesServerResponsesGotmpl,
|
||||
"templates/server/server.gotmpl": templatesServerServerGotmpl,
|
||||
"templates/server/urlbuilder.gotmpl": templatesServerUrlbuilderGotmpl,
|
||||
"templates/simpleschema/defaultsinit.gotmpl": templatesSimpleschemaDefaultsinitGotmpl,
|
||||
"templates/simpleschema/defaultsvar.gotmpl": templatesSimpleschemaDefaultsvarGotmpl,
|
||||
"templates/structfield.gotmpl": templatesStructfieldGotmpl,
|
||||
"templates/swagger_json_embed.gotmpl": templatesSwagger_json_embedGotmpl,
|
||||
"templates/validation/customformat.gotmpl": templatesValidationCustomformatGotmpl,
|
||||
"templates/validation/maximum.gotmpl": templatesValidationMaximumGotmpl,
|
||||
"templates/validation/minimum.gotmpl": templatesValidationMinimumGotmpl,
|
||||
"templates/validation/multipleOf.gotmpl": templatesValidationMultipleofGotmpl,
|
||||
"templates/validation/primitive.gotmpl": templatesValidationPrimitiveGotmpl,
|
||||
"templates/validation/structfield.gotmpl": templatesValidationStructfieldGotmpl,
|
||||
}
|
||||
@@ -1082,8 +1214,11 @@ var _bintree = &bintree{nil, map[string]*bintree{
|
||||
}},
|
||||
}},
|
||||
}},
|
||||
"docstring.gotmpl": &bintree{templatesDocstringGotmpl, map[string]*bintree{}},
|
||||
"header.gotmpl": &bintree{templatesHeaderGotmpl, map[string]*bintree{}},
|
||||
"docstring.gotmpl": &bintree{templatesDocstringGotmpl, map[string]*bintree{}},
|
||||
"header.gotmpl": &bintree{templatesHeaderGotmpl, map[string]*bintree{}},
|
||||
"markdown": &bintree{nil, map[string]*bintree{
|
||||
"docs.gotmpl": &bintree{templatesMarkdownDocsGotmpl, map[string]*bintree{}},
|
||||
}},
|
||||
"model.gotmpl": &bintree{templatesModelGotmpl, map[string]*bintree{}},
|
||||
"schema.gotmpl": &bintree{templatesSchemaGotmpl, map[string]*bintree{}},
|
||||
"schemabody.gotmpl": &bintree{templatesSchemabodyGotmpl, map[string]*bintree{}},
|
||||
@@ -1112,10 +1247,17 @@ var _bintree = &bintree{nil, map[string]*bintree{
|
||||
"server.gotmpl": &bintree{templatesServerServerGotmpl, map[string]*bintree{}},
|
||||
"urlbuilder.gotmpl": &bintree{templatesServerUrlbuilderGotmpl, map[string]*bintree{}},
|
||||
}},
|
||||
"simpleschema": &bintree{nil, map[string]*bintree{
|
||||
"defaultsinit.gotmpl": &bintree{templatesSimpleschemaDefaultsinitGotmpl, map[string]*bintree{}},
|
||||
"defaultsvar.gotmpl": &bintree{templatesSimpleschemaDefaultsvarGotmpl, map[string]*bintree{}},
|
||||
}},
|
||||
"structfield.gotmpl": &bintree{templatesStructfieldGotmpl, map[string]*bintree{}},
|
||||
"swagger_json_embed.gotmpl": &bintree{templatesSwagger_json_embedGotmpl, map[string]*bintree{}},
|
||||
"validation": &bintree{nil, map[string]*bintree{
|
||||
"customformat.gotmpl": &bintree{templatesValidationCustomformatGotmpl, map[string]*bintree{}},
|
||||
"maximum.gotmpl": &bintree{templatesValidationMaximumGotmpl, map[string]*bintree{}},
|
||||
"minimum.gotmpl": &bintree{templatesValidationMinimumGotmpl, map[string]*bintree{}},
|
||||
"multipleOf.gotmpl": &bintree{templatesValidationMultipleofGotmpl, map[string]*bintree{}},
|
||||
"primitive.gotmpl": &bintree{templatesValidationPrimitiveGotmpl, map[string]*bintree{}},
|
||||
"structfield.gotmpl": &bintree{templatesValidationStructfieldGotmpl, map[string]*bintree{}},
|
||||
}},
|
||||
|
||||
+7
-4
@@ -84,10 +84,11 @@ func (c *clientGenerator) Generate() error {
|
||||
}
|
||||
|
||||
if c.GenOpts.IncludeModel {
|
||||
for _, mod := range app.Models {
|
||||
if mod.IsStream {
|
||||
for _, m := range app.Models {
|
||||
if m.IsStream {
|
||||
continue
|
||||
}
|
||||
mod := m
|
||||
if err := c.GenOpts.renderDefinition(&mod); err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -95,8 +96,10 @@ func (c *clientGenerator) Generate() error {
|
||||
}
|
||||
|
||||
if c.GenOpts.IncludeHandler {
|
||||
for _, opg := range app.OperationGroups {
|
||||
for _, op := range opg.Operations {
|
||||
for _, g := range app.OperationGroups {
|
||||
opg := g
|
||||
for _, o := range opg.Operations {
|
||||
op := o
|
||||
if err := c.GenOpts.renderOperation(&op); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
+1
-1
@@ -57,7 +57,7 @@ var zeroes = map[string]string{
|
||||
"strfmt.UUID3": "strfmt.UUID3(\"\")",
|
||||
"strfmt.UUID4": "strfmt.UUID4(\"\")",
|
||||
"strfmt.UUID5": "strfmt.UUID5(\"\")",
|
||||
//"file": "runtime.File",
|
||||
// "file": "runtime.File",
|
||||
}
|
||||
|
||||
// conversion functions from string representation to a numerical or boolean
|
||||
|
||||
+1
-1
@@ -262,7 +262,7 @@ func GoLangOpts() *LanguageOpts {
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
return strings.Replace(strings.Replace(strings.Replace(string(b), "}", ",}", -1), "[", "{", -1), "]", ",}", -1), nil
|
||||
return strings.ReplaceAll(strings.ReplaceAll(strings.ReplaceAll(string(b), "}", ",}"), "[", "{"), "]", ",}"), nil
|
||||
}
|
||||
|
||||
opts.BaseImportFunc = func(tgt string) string {
|
||||
|
||||
+146
-74
@@ -186,7 +186,7 @@ func shallowValidationLookup(sch GenSchema) bool {
|
||||
if sch.Required || hasFormatValidation(sch.resolvedType) {
|
||||
return true
|
||||
}
|
||||
if sch.MaxLength != nil || sch.MinLength != nil || sch.Pattern != "" || sch.MultipleOf != nil || sch.Minimum != nil || sch.Maximum != nil || len(sch.Enum) > 0 || len(sch.ItemsEnum) > 0 {
|
||||
if sch.HasStringValidations() || sch.HasNumberValidations() || sch.HasEnum() || len(sch.ItemsEnum) > 0 || sch.HasObjectValidations() {
|
||||
return true
|
||||
}
|
||||
for _, a := range sch.AllOf {
|
||||
@@ -230,7 +230,7 @@ func makeGenDefinitionHierarchy(name, pkg, container string, schema spec.Schema,
|
||||
// Check if model is imported from external package using x-go-type
|
||||
receiver := "m"
|
||||
// models are resolved in the current package
|
||||
resolver := newTypeResolver("", specDoc)
|
||||
resolver := newTypeResolver("", "", specDoc)
|
||||
resolver.ModelName = name
|
||||
analyzed := analysis.New(specDoc.Spec())
|
||||
|
||||
@@ -375,7 +375,7 @@ func makeGenDefinitionHierarchy(name, pkg, container string, schema spec.Schema,
|
||||
}
|
||||
|
||||
func findImports(sch *GenSchema) map[string]string {
|
||||
imp := map[string]string{}
|
||||
imp := make(map[string]string, 20)
|
||||
t := sch.resolvedType
|
||||
if t.Pkg != "" && t.PkgAlias != "" {
|
||||
imp[t.PkgAlias] = t.Pkg
|
||||
@@ -404,7 +404,8 @@ func findImports(sch *GenSchema) map[string]string {
|
||||
}
|
||||
}
|
||||
if sch.Properties != nil {
|
||||
for _, p := range sch.Properties {
|
||||
for _, props := range sch.Properties {
|
||||
p := props
|
||||
sub := findImports(&p)
|
||||
for k, v := range sub {
|
||||
imp[k] = v
|
||||
@@ -418,7 +419,8 @@ func findImports(sch *GenSchema) map[string]string {
|
||||
}
|
||||
}
|
||||
if sch.AllOf != nil {
|
||||
for _, p := range sch.AllOf {
|
||||
for _, props := range sch.AllOf {
|
||||
p := props
|
||||
sub := findImports(&p)
|
||||
for k, v := range sub {
|
||||
imp[k] = v
|
||||
@@ -426,8 +428,11 @@ func findImports(sch *GenSchema) map[string]string {
|
||||
}
|
||||
}
|
||||
for k, v := range sch.ExtraImports {
|
||||
imp[k] = v
|
||||
if k != "" && v != "" {
|
||||
imp[k] = v
|
||||
}
|
||||
}
|
||||
|
||||
return imp
|
||||
}
|
||||
|
||||
@@ -621,33 +626,39 @@ func (sg *schemaGenContext) NewAdditionalProperty(schema spec.Schema) *schemaGen
|
||||
return pg
|
||||
}
|
||||
|
||||
func hasSliceValidations(model *spec.Schema) (hasSliceValidations bool) {
|
||||
hasSliceValidations = model.MaxItems != nil || model.MinItems != nil || model.UniqueItems || len(model.Enum) > 0
|
||||
return
|
||||
func hasContextValidations(model *spec.Schema) bool {
|
||||
// always assume ref needs context validate
|
||||
// TODO: find away to determine ref needs context validate or not
|
||||
if model.ReadOnly || model.Ref.String() != "" {
|
||||
return true
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func hasValidations(model *spec.Schema, isRequired bool) (hasValidation bool) {
|
||||
// NOTE: needsValidation has gone deprecated and is replaced by top-level's shallowValidationLookup()
|
||||
hasNumberValidation := model.Maximum != nil || model.Minimum != nil || model.MultipleOf != nil
|
||||
hasStringValidation := model.MaxLength != nil || model.MinLength != nil || model.Pattern != ""
|
||||
hasEnum := len(model.Enum) > 0
|
||||
func hasValidations(model *spec.Schema, isRequired bool) bool {
|
||||
if isRequired {
|
||||
return true
|
||||
}
|
||||
|
||||
v := model.Validations()
|
||||
if v.HasNumberValidations() || v.HasStringValidations() || v.HasArrayValidations() || v.HasEnum() || v.HasObjectValidations() {
|
||||
return true
|
||||
}
|
||||
|
||||
// since this was added to deal with discriminator, we'll fix this when testing discriminated types
|
||||
simpleObject := len(model.Properties) > 0 && model.Discriminator == ""
|
||||
if len(model.Properties) > 0 && model.Discriminator == "" {
|
||||
return true
|
||||
}
|
||||
|
||||
// lift validations from allOf branches
|
||||
hasAllOfValidation := false
|
||||
for _, s := range model.AllOf {
|
||||
hasAllOfValidation = hasValidations(&s, false)
|
||||
hasAllOfValidation = s.Ref.String() != "" || hasAllOfValidation
|
||||
if hasAllOfValidation {
|
||||
break
|
||||
schema := s
|
||||
if s.Ref.String() != "" || hasValidations(&schema, false) {
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
||||
hasValidation = hasNumberValidation || hasStringValidation || hasSliceValidations(model) || hasEnum || simpleObject || hasAllOfValidation || isRequired
|
||||
|
||||
return
|
||||
return false
|
||||
}
|
||||
|
||||
func hasFormatValidation(tpe resolvedType) bool {
|
||||
@@ -660,34 +671,25 @@ func hasFormatValidation(tpe resolvedType) bool {
|
||||
return false
|
||||
}
|
||||
|
||||
// handleFormatConflicts handles all conflicting model properties when a format is set
|
||||
func handleFormatConflicts(model *spec.Schema) {
|
||||
switch model.Format {
|
||||
case "date", "datetime", "uuid", "bsonobjectid", "base64", "duration":
|
||||
model.MinLength = nil
|
||||
model.MaxLength = nil
|
||||
model.Pattern = ""
|
||||
// more cases should be inserted here if they arise
|
||||
}
|
||||
}
|
||||
|
||||
func (sg *schemaGenContext) schemaValidations() sharedValidations {
|
||||
model := sg.Schema
|
||||
// resolve any conflicting properties if the model has a format
|
||||
handleFormatConflicts(&model)
|
||||
|
||||
isRequired := sg.Required
|
||||
if model.Default != nil || model.ReadOnly {
|
||||
// when readOnly or default is specified, this disables Required validation (Swagger-specific)
|
||||
isRequired = false
|
||||
if sg.Required {
|
||||
log.Printf("warn: properties with a default value or readOnly should not be required [%s]", sg.Name)
|
||||
}
|
||||
}
|
||||
hasSliceValidations := model.MaxItems != nil || model.MinItems != nil || model.UniqueItems || len(model.Enum) > 0
|
||||
hasValidations := hasValidations(&model, isRequired)
|
||||
|
||||
s := sharedValidationsFromSchema(model, sg.Required)
|
||||
s.HasValidations = hasValidations
|
||||
s.HasSliceValidations = hasSliceValidations
|
||||
return s
|
||||
v := model.Validations()
|
||||
return sharedValidations{
|
||||
Required: sg.Required, /* TODO(fred): guard for cases with discriminator field, default and readOnly*/
|
||||
SchemaValidations: v,
|
||||
HasSliceValidations: v.HasArrayValidations() || v.HasEnum(),
|
||||
HasValidations: hasValidations(&model, isRequired),
|
||||
}
|
||||
}
|
||||
|
||||
func mergeValidation(other *schemaGenContext) bool {
|
||||
@@ -708,6 +710,7 @@ func mergeValidation(other *schemaGenContext) bool {
|
||||
|
||||
func (sg *schemaGenContext) MergeResult(other *schemaGenContext, liftsRequired bool) {
|
||||
sg.GenSchema.HasValidations = sg.GenSchema.HasValidations || mergeValidation(other)
|
||||
sg.GenSchema.HasContextValidations = sg.GenSchema.HasContextValidations || other.GenSchema.HasContextValidations
|
||||
|
||||
if liftsRequired && other.GenSchema.AdditionalProperties != nil && other.GenSchema.AdditionalProperties.Required {
|
||||
sg.GenSchema.Required = true
|
||||
@@ -743,21 +746,20 @@ func (sg *schemaGenContext) buildProperties() error {
|
||||
debugLog("building properties %s (parent: %s)", sg.Name, sg.Container)
|
||||
|
||||
for k, v := range sg.Schema.Properties {
|
||||
debugLogAsJSON("building property %s[%q] (tup: %t) (BaseType: %t)",
|
||||
sg.Name, k, sg.IsTuple, sg.GenSchema.IsBaseType, sg.Schema)
|
||||
debugLog("property %s[%q] (tup: %t) HasValidations: %t)",
|
||||
sg.Name, k, sg.IsTuple, sg.GenSchema.HasValidations)
|
||||
debugLogAsJSON("building property %s[%q] (IsTuple: %t) (IsBaseType: %t) (HasValidations: %t)",
|
||||
sg.Name, k, sg.IsTuple, sg.GenSchema.IsBaseType, sg.GenSchema.HasValidations, v)
|
||||
|
||||
vv := v
|
||||
|
||||
// check if this requires de-anonymizing, if so lift this as a new struct and extra schema
|
||||
tpe, err := sg.TypeResolver.ResolveSchema(&v, true, sg.IsTuple || swag.ContainsStrings(sg.Schema.Required, k))
|
||||
if sg.Schema.Discriminator == k {
|
||||
tpe.IsNullable = false
|
||||
}
|
||||
tpe, err := sg.TypeResolver.ResolveSchema(&vv, true, sg.IsTuple || swag.ContainsStrings(sg.Schema.Required, k))
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if sg.Schema.Discriminator == k {
|
||||
tpe.IsNullable = false
|
||||
}
|
||||
|
||||
vv := v
|
||||
var hasValidation bool
|
||||
if tpe.IsComplexObject && tpe.IsAnonymous && len(v.Properties) > 0 {
|
||||
// this is an anonymous complex construct: build a new new type for it
|
||||
@@ -904,8 +906,13 @@ func (sg *schemaGenContext) buildProperties() error {
|
||||
emprop.GenSchema.Extensions = emprop.Schema.Extensions
|
||||
|
||||
// set custom serializer tag
|
||||
if customTag, found := emprop.Schema.Extensions[xGoCustomTag]; found {
|
||||
emprop.GenSchema.CustomTag = customTag.(string)
|
||||
if customTag, found := tpe.Extensions[xGoCustomTag]; found {
|
||||
tagAsStr, ok := customTag.(string)
|
||||
if ok {
|
||||
emprop.GenSchema.CustomTag = tagAsStr
|
||||
} else {
|
||||
log.Printf("warning: expect %s extension to be a string, got: %v. Skipped", xGoCustomTag, customTag)
|
||||
}
|
||||
}
|
||||
sg.GenSchema.Properties = append(sg.GenSchema.Properties, emprop.GenSchema)
|
||||
}
|
||||
@@ -926,7 +933,8 @@ func (sg *schemaGenContext) buildAllOf() error {
|
||||
sg.Container = sg.Name
|
||||
}
|
||||
debugLogAsJSON("building all of for %d entries", len(sg.Schema.AllOf), sg.Schema)
|
||||
for i, sch := range sg.Schema.AllOf {
|
||||
for i, schema := range sg.Schema.AllOf {
|
||||
sch := schema
|
||||
tpe, ert := sg.TypeResolver.ResolveSchema(&sch, sch.Ref.String() == "", false)
|
||||
if ert != nil {
|
||||
return ert
|
||||
@@ -1006,7 +1014,12 @@ func (sg *schemaGenContext) buildAllOf() error {
|
||||
log.Printf("warning: cannot generate serializable allOf with conflicting array definitions in %s", sg.Container)
|
||||
}
|
||||
|
||||
sg.GenSchema.IsNullable = true
|
||||
// AllOf types are always considered nullable, except when an extension says otherwise
|
||||
if override, ok := sg.TypeResolver.isNullableOverride(&sg.Schema); ok {
|
||||
sg.GenSchema.IsNullable = override
|
||||
} else {
|
||||
sg.GenSchema.IsNullable = true
|
||||
}
|
||||
|
||||
// prevent IsAliased to bubble up (e.g. when a single branch is itself aliased)
|
||||
sg.GenSchema.IsAliased = sg.GenSchema.IsAliased && len(sg.GenSchema.AllOf) < 2
|
||||
@@ -1037,7 +1050,7 @@ func newMapStack(context *schemaGenContext) (first, last *mapStack, err error) {
|
||||
}
|
||||
|
||||
if !tpe.IsMap {
|
||||
//reached the end of the rabbit hole
|
||||
// reached the end of the rabbit hole
|
||||
if tpe.IsComplexObject && tpe.IsAnonymous {
|
||||
// found an anonymous object: create the struct from a newly created definition
|
||||
nw := l.Context.makeNewStruct(l.Context.makeRefName()+" Anon", *l.Type.AdditionalProperties.Schema)
|
||||
@@ -1047,6 +1060,7 @@ func newMapStack(context *schemaGenContext) (first, last *mapStack, err error) {
|
||||
l.Type.AdditionalProperties.Schema = sch
|
||||
l.ValueRef = l.Context.NewAdditionalProperty(*sch)
|
||||
}
|
||||
|
||||
// other cases where to stop are: a $ref or a simple object
|
||||
break
|
||||
}
|
||||
@@ -1060,7 +1074,7 @@ func newMapStack(context *schemaGenContext) (first, last *mapStack, err error) {
|
||||
l = l.Next
|
||||
}
|
||||
|
||||
//return top and bottom entries of this stack of AdditionalProperties
|
||||
// return top and bottom entries of this stack of AdditionalProperties
|
||||
return ms, l, nil
|
||||
}
|
||||
|
||||
@@ -1442,7 +1456,7 @@ func (sg *schemaGenContext) buildArray() error {
|
||||
// items from maps of aliased or nullable type remain required
|
||||
|
||||
// NOTE(fredbi): since this is reset below, this Required = true serves the obscure purpose
|
||||
// of indirectly lifting validations from the slice. This is carried on differently now.
|
||||
// of indirectly lifting validations from the slice. This is carried out differently now.
|
||||
// elProp.Required = true
|
||||
|
||||
if err := elProp.makeGenSchema(); err != nil {
|
||||
@@ -1484,7 +1498,7 @@ func (sg *schemaGenContext) buildArray() error {
|
||||
|
||||
// lift validations
|
||||
sg.GenSchema.HasValidations = sg.GenSchema.HasValidations || schemaCopy.HasValidations
|
||||
sg.GenSchema.HasSliceValidations = hasSliceValidations(&sg.Schema)
|
||||
sg.GenSchema.HasSliceValidations = sg.Schema.Validations().HasArrayValidations() || sg.Schema.Validations().HasEnum()
|
||||
|
||||
// prevents bubbling custom formatter flag
|
||||
sg.GenSchema.IsCustomFormatter = false
|
||||
@@ -1516,7 +1530,8 @@ func (sg *schemaGenContext) buildItems() error {
|
||||
if sg.Named {
|
||||
sg.GenSchema.Name = sg.Name
|
||||
sg.GenSchema.GoType = sg.TypeResolver.goTypeName(sg.Name)
|
||||
for i, s := range sg.Schema.Items.Schemas {
|
||||
for i, sch := range sg.Schema.Items.Schemas {
|
||||
s := sch
|
||||
elProp := sg.NewTupleElement(&s, i)
|
||||
|
||||
if s.Ref.String() == "" {
|
||||
@@ -1630,7 +1645,11 @@ func (sg *schemaGenContext) buildAdditionalItems() error {
|
||||
}
|
||||
|
||||
func (sg *schemaGenContext) buildXMLNameWithTags() error {
|
||||
if sg.WithXML || sg.Schema.XML != nil {
|
||||
// render some "xml" struct tag under one the following conditions:
|
||||
// - consumes/produces in spec contains xml
|
||||
// - struct tags CLI option contains xml
|
||||
// - XML object present in spec for this schema
|
||||
if sg.WithXML || swag.ContainsStrings(sg.StructTags, "xml") || sg.Schema.XML != nil {
|
||||
sg.GenSchema.XMLName = sg.Name
|
||||
|
||||
if sg.Schema.XML != nil {
|
||||
@@ -1641,10 +1660,6 @@ func (sg *schemaGenContext) buildXMLNameWithTags() error {
|
||||
sg.GenSchema.XMLName += ",attr"
|
||||
}
|
||||
}
|
||||
|
||||
if !sg.GenSchema.Required && sg.GenSchema.IsEmptyOmitted {
|
||||
sg.GenSchema.XMLName += ",omitempty"
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
@@ -1730,7 +1745,7 @@ func (sg *schemaGenContext) shortCircuitNamedRef() (bool, error) {
|
||||
tpe.IsMap = false
|
||||
tpe.IsArray = false
|
||||
tpe.IsAnonymous = false
|
||||
tpe.IsNullable = sg.TypeResolver.IsNullable(&sg.Schema)
|
||||
tpe.IsNullable = sg.TypeResolver.isNullable(&sg.Schema)
|
||||
|
||||
item := sg.NewCompositionBranch(sg.Schema, 0)
|
||||
if err := item.makeGenSchema(); err != nil {
|
||||
@@ -1759,13 +1774,13 @@ func (sg *schemaGenContext) liftSpecialAllOf() error {
|
||||
var seenNullable bool
|
||||
var schemaToLift spec.Schema
|
||||
|
||||
for _, sch := range sg.Schema.AllOf {
|
||||
|
||||
for _, schema := range sg.Schema.AllOf {
|
||||
sch := schema
|
||||
tpe, err := sg.TypeResolver.ResolveSchema(&sch, true, true)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if sg.TypeResolver.IsNullable(&sch) {
|
||||
if sg.TypeResolver.isNullable(&sch) {
|
||||
seenNullable = true
|
||||
}
|
||||
if len(sch.Type) > 0 || len(sch.Properties) > 0 || sch.Ref.GetURL() != nil || len(sch.AllOf) > 0 {
|
||||
@@ -1839,6 +1854,21 @@ func goName(sch *spec.Schema, orig string) string {
|
||||
return orig
|
||||
}
|
||||
|
||||
func (sg *schemaGenContext) derefMapElement(outer *GenSchema, sch *GenSchema, elem *GenSchema) {
|
||||
derefType := strings.TrimPrefix(elem.GoType, "*")
|
||||
|
||||
if outer.IsAliased {
|
||||
nesting := strings.TrimSuffix(strings.TrimSuffix(outer.AliasedType, elem.GoType), "*")
|
||||
outer.AliasedType = nesting + derefType
|
||||
outer.GoType = derefType
|
||||
} else {
|
||||
nesting := strings.TrimSuffix(strings.TrimSuffix(outer.GoType, elem.GoType), "*")
|
||||
outer.GoType = nesting + derefType
|
||||
}
|
||||
|
||||
elem.GoType = derefType
|
||||
}
|
||||
|
||||
func (sg *schemaGenContext) checkNeedsPointer(outer *GenSchema, sch *GenSchema, elem *GenSchema) {
|
||||
derefType := strings.TrimPrefix(elem.GoType, "*")
|
||||
switch {
|
||||
@@ -1876,10 +1906,21 @@ func (sg *schemaGenContext) buildMapOfNullable(sch *GenSchema) {
|
||||
// render element of aliased or anonyous map as a pointer
|
||||
it := elem.Items
|
||||
for it != nil {
|
||||
if it.IsPrimitive && it.IsNullable {
|
||||
switch {
|
||||
case it.IsPrimitive && it.IsNullable:
|
||||
sg.checkNeedsPointer(outer, sch, it)
|
||||
} else if it.IsMap {
|
||||
case it.IsMap:
|
||||
sg.buildMapOfNullable(it)
|
||||
case !it.IsPrimitive && !it.IsArray && it.IsComplexObject && it.IsNullable:
|
||||
// structs in map are not rendered as pointer by default
|
||||
// unless some x-nullable overrides says so
|
||||
_, forced := it.Extensions[xNullable]
|
||||
if !forced {
|
||||
_, forced = it.Extensions[xIsNullable]
|
||||
}
|
||||
if !forced {
|
||||
sg.derefMapElement(outer, sch, it)
|
||||
}
|
||||
}
|
||||
it = it.Items
|
||||
}
|
||||
@@ -1893,12 +1934,18 @@ func (sg *schemaGenContext) makeGenSchema() error {
|
||||
debugLogAsJSON("making gen schema (anon: %t, req: %t, tuple: %t) %s\n",
|
||||
!sg.Named, sg.Required, sg.IsTuple, sg.Name, sg.Schema)
|
||||
|
||||
ex := ""
|
||||
sg.GenSchema.Example = ""
|
||||
if sg.Schema.Example != nil {
|
||||
ex = fmt.Sprintf("%#v", sg.Schema.Example)
|
||||
data, err := asJSON(sg.Schema.Example)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
// Deleting the unnecessary double quotes for string types
|
||||
// otherwise the generate spec will generate as "\"foo\""
|
||||
sg.GenSchema.Example = strings.Trim(data, "\"")
|
||||
}
|
||||
sg.GenSchema.ExternalDocs = trimExternalDoc(sg.Schema.ExternalDocs)
|
||||
sg.GenSchema.IsExported = true
|
||||
sg.GenSchema.Example = ex
|
||||
sg.GenSchema.Path = sg.Path
|
||||
sg.GenSchema.IndexVar = sg.IndexVar
|
||||
sg.GenSchema.Location = body
|
||||
@@ -1960,12 +2007,37 @@ func (sg *schemaGenContext) makeGenSchema() error {
|
||||
// include format validations, excluding binary
|
||||
sg.GenSchema.HasValidations = sg.GenSchema.HasValidations || hasFormatValidation(tpe)
|
||||
|
||||
// include context validations
|
||||
sg.GenSchema.HasContextValidations = sg.GenSchema.HasContextValidations || hasContextValidations(&sg.Schema) && !tpe.IsInterface && !tpe.IsStream && !tpe.SkipExternalValidation
|
||||
|
||||
// usage of a polymorphic base type is rendered with getter funcs on private properties.
|
||||
// In the case of aliased types, the value expression remains unchanged to the receiver.
|
||||
if tpe.IsArray && tpe.ElemType != nil && tpe.ElemType.IsBaseType && sg.GenSchema.ValueExpression != sg.GenSchema.ReceiverName {
|
||||
sg.GenSchema.ValueExpression += asMethod
|
||||
}
|
||||
|
||||
if tpe.IsExternal { // anonymous external types
|
||||
extType, pkg, alias := sg.TypeResolver.knownDefGoType(sg.GenSchema.Name, sg.Schema, sg.TypeResolver.goTypeName)
|
||||
if pkg != "" && alias != "" {
|
||||
sg.GenSchema.ExtraImports[alias] = pkg
|
||||
}
|
||||
|
||||
if !tpe.IsEmbedded {
|
||||
sg.GenSchema.resolvedType = tpe
|
||||
sg.GenSchema.Required = sg.Required
|
||||
// assume we validate everything but interface and io.Reader - validation may be disabled by using the noValidation hint
|
||||
sg.GenSchema.HasValidations = !(tpe.IsInterface || tpe.IsStream || tpe.SkipExternalValidation)
|
||||
sg.GenSchema.IsAliased = sg.GenSchema.HasValidations
|
||||
|
||||
log.Printf("INFO: type %s is external, with inferred spec type %s, referred to as %s", sg.GenSchema.Name, sg.GenSchema.GoType, extType)
|
||||
sg.GenSchema.GoType = extType
|
||||
sg.GenSchema.AliasedType = extType
|
||||
return nil
|
||||
}
|
||||
// TODO: case for embedded types as anonymous definitions
|
||||
return fmt.Errorf("ERROR: inline definitions embedded types are not supported")
|
||||
}
|
||||
|
||||
debugLog("gschema nullable: %t", sg.GenSchema.IsNullable)
|
||||
if e := sg.buildAdditionalProperties(); e != nil {
|
||||
return e
|
||||
|
||||
+105
-79
@@ -193,7 +193,8 @@ func (o *operationGenerator) Generate() error {
|
||||
operations = append(operations, op)
|
||||
sort.Sort(operations)
|
||||
|
||||
for _, op := range operations {
|
||||
for _, pp := range operations {
|
||||
op := pp
|
||||
if o.GenOpts.DumpData {
|
||||
_ = dumpData(swag.ToDynamicJSON(op))
|
||||
continue
|
||||
@@ -312,7 +313,7 @@ func (b *codeGenOpBuilder) MakeOperation() (GenOperation, error) {
|
||||
//
|
||||
// In all cases, resetting definitions to the _original_ (untransformed) spec is not an option:
|
||||
// we take from there the spec possibly already transformed by the GenDefinitions stage.
|
||||
resolver := newTypeResolver(b.GenOpts.LanguageOpts.ManglePackageName(b.ModelsPackage, defaultModelsTarget), b.Doc)
|
||||
resolver := newTypeResolver(b.GenOpts.LanguageOpts.ManglePackageName(b.ModelsPackage, defaultModelsTarget), b.DefaultImports[b.ModelsPackage], b.Doc)
|
||||
receiver := "o"
|
||||
|
||||
operation := b.Operation
|
||||
@@ -399,6 +400,7 @@ func (b *codeGenOpBuilder) MakeOperation() (GenOperation, error) {
|
||||
defaultResponse = &gr
|
||||
}
|
||||
}
|
||||
|
||||
// Always render a default response, even when no responses were defined
|
||||
if operation.Responses == nil || (operation.Responses.Default == nil && len(srs) == 0) {
|
||||
gr, err := b.MakeResponse(receiver, b.Name+" default", false, resolver, -1, spec.Response{})
|
||||
@@ -408,44 +410,41 @@ func (b *codeGenOpBuilder) MakeOperation() (GenOperation, error) {
|
||||
defaultResponse = &gr
|
||||
}
|
||||
|
||||
if b.Principal == "" {
|
||||
b.Principal = iface
|
||||
}
|
||||
|
||||
swsp := resolver.Doc.Spec()
|
||||
var extraSchemes []string
|
||||
if ess, ok := operation.Extensions.GetStringSlice(xSchemes); ok {
|
||||
extraSchemes = append(extraSchemes, ess...)
|
||||
}
|
||||
|
||||
if ess1, ok := swsp.Extensions.GetStringSlice(xSchemes); ok {
|
||||
extraSchemes = concatUnique(ess1, extraSchemes)
|
||||
}
|
||||
sort.Strings(extraSchemes)
|
||||
schemes := concatUnique(swsp.Schemes, operation.Schemes)
|
||||
sort.Strings(schemes)
|
||||
schemes, extraSchemes := gatherURISchemes(swsp, operation)
|
||||
originalSchemes := operation.Schemes
|
||||
originalExtraSchemes := getExtraSchemes(operation.Extensions)
|
||||
|
||||
produces := producesOrDefault(operation.Produces, swsp.Produces, b.DefaultProduces)
|
||||
sort.Strings(produces)
|
||||
|
||||
consumes := producesOrDefault(operation.Consumes, swsp.Consumes, b.DefaultConsumes)
|
||||
sort.Strings(consumes)
|
||||
|
||||
var hasStreamingResponse bool
|
||||
if defaultResponse != nil && defaultResponse.Schema != nil && defaultResponse.Schema.IsStream {
|
||||
hasStreamingResponse = true
|
||||
}
|
||||
var successResponse *GenResponse
|
||||
for _, sr := range successResponses {
|
||||
for _, resp := range successResponses {
|
||||
sr := resp
|
||||
if sr.IsSuccess {
|
||||
successResponse = &sr
|
||||
break
|
||||
}
|
||||
}
|
||||
for _, sr := range successResponses {
|
||||
if !hasStreamingResponse && sr.Schema != nil && sr.Schema.IsStream {
|
||||
hasStreamingResponse = true
|
||||
break
|
||||
|
||||
var hasStreamingResponse bool
|
||||
if defaultResponse != nil && defaultResponse.Schema != nil && defaultResponse.Schema.IsStream {
|
||||
hasStreamingResponse = true
|
||||
}
|
||||
|
||||
if !hasStreamingResponse {
|
||||
for _, sr := range successResponses {
|
||||
if !hasStreamingResponse && sr.Schema != nil && sr.Schema.IsStream {
|
||||
hasStreamingResponse = true
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if !hasStreamingResponse {
|
||||
for _, r := range responses {
|
||||
if r.Schema != nil && r.Schema.IsStream {
|
||||
@@ -488,8 +487,9 @@ func (b *codeGenOpBuilder) MakeOperation() (GenOperation, error) {
|
||||
HasBodyParams: hasBodyParams,
|
||||
HasStreamingResponse: hasStreamingResponse,
|
||||
Authorized: b.Authed,
|
||||
Security: b.makeSecurityRequirements(receiver),
|
||||
Security: b.makeSecurityRequirements(receiver), // resolved security requirements, for codegen
|
||||
SecurityDefinitions: b.makeSecuritySchemes(receiver),
|
||||
SecurityRequirements: securityRequirements(operation.Security), // raw security requirements, for doc
|
||||
Principal: b.Principal,
|
||||
Responses: responses,
|
||||
DefaultResponse: defaultResponse,
|
||||
@@ -497,12 +497,19 @@ func (b *codeGenOpBuilder) MakeOperation() (GenOperation, error) {
|
||||
SuccessResponses: successResponses,
|
||||
ExtraSchemas: gatherExtraSchemas(b.ExtraSchemas),
|
||||
Schemes: schemeOrDefault(schemes, b.DefaultScheme),
|
||||
ProducesMediaTypes: produces,
|
||||
ConsumesMediaTypes: consumes,
|
||||
ExtraSchemes: extraSchemes,
|
||||
SchemeOverrides: originalSchemes, // raw operation schemes, for doc
|
||||
ProducesMediaTypes: produces, // resolved produces, for codegen
|
||||
ConsumesMediaTypes: consumes, // resolved consumes, for codegen
|
||||
Produces: operation.Produces, // for doc
|
||||
Consumes: operation.Consumes, // for doc
|
||||
ExtraSchemes: extraSchemes, // resolved schemes, for codegen
|
||||
ExtraSchemeOverrides: originalExtraSchemes, // raw operation extra schemes, for doc
|
||||
TimeoutName: timeoutName,
|
||||
Extensions: operation.Extensions,
|
||||
StrictResponders: b.GenOpts.StrictResponders,
|
||||
|
||||
PrincipalIsNullable: b.GenOpts.PrincipalIsNullable(),
|
||||
ExternalDocs: trimExternalDoc(operation.ExternalDocs),
|
||||
}, nil
|
||||
}
|
||||
|
||||
@@ -523,26 +530,15 @@ func schemeOrDefault(schemes []string, defaultScheme string) []string {
|
||||
return schemes
|
||||
}
|
||||
|
||||
func concatUnique(collections ...[]string) []string {
|
||||
resultSet := make(map[string]struct{})
|
||||
for _, c := range collections {
|
||||
for _, i := range c {
|
||||
if _, ok := resultSet[i]; !ok {
|
||||
resultSet[i] = struct{}{}
|
||||
}
|
||||
}
|
||||
}
|
||||
var result []string
|
||||
for k := range resultSet {
|
||||
result = append(result, k)
|
||||
}
|
||||
return result
|
||||
}
|
||||
|
||||
func (b *codeGenOpBuilder) MakeResponse(receiver, name string, isSuccess bool, resolver *typeResolver, code int, resp spec.Response) (GenResponse, error) {
|
||||
debugLog("[%s %s] making id %q", b.Method, b.Path, b.Operation.ID)
|
||||
|
||||
// assume minimal flattening has been carried on, so there is not $ref in response (but some may remain in response schema)
|
||||
examples := make(GenResponseExamples, 0, len(resp.Examples))
|
||||
for k, v := range resp.Examples {
|
||||
examples = append(examples, GenResponseExample{MediaType: k, Example: v})
|
||||
}
|
||||
sort.Sort(examples)
|
||||
|
||||
res := GenResponse{
|
||||
Package: b.GenOpts.LanguageOpts.ManglePackageName(b.APIPackage, defaultOperationsTarget),
|
||||
@@ -559,6 +555,7 @@ func (b *codeGenOpBuilder) MakeResponse(receiver, name string, isSuccess bool, r
|
||||
Extensions: resp.Extensions,
|
||||
StrictResponders: b.GenOpts.StrictResponders,
|
||||
OperationName: b.Name,
|
||||
Examples: examples,
|
||||
}
|
||||
|
||||
// prepare response headers
|
||||
@@ -583,26 +580,29 @@ func (b *codeGenOpBuilder) MakeResponse(receiver, name string, isSuccess bool, r
|
||||
}
|
||||
|
||||
func (b *codeGenOpBuilder) MakeHeader(receiver, name string, hdr spec.Header) (GenHeader, error) {
|
||||
tpe := typeForHeader(hdr) //simpleResolvedType(hdr.Type, hdr.Format, hdr.Items)
|
||||
tpe := simpleResolvedType(hdr.Type, hdr.Format, hdr.Items, &hdr.CommonValidations)
|
||||
|
||||
id := swag.ToGoName(name)
|
||||
res := GenHeader{
|
||||
sharedValidations: sharedValidationsFromSimple(hdr.CommonValidations, true), // NOTE: Required is not defined by the Swagger schema for header. Set arbitrarily to true for convenience in templates.
|
||||
resolvedType: tpe,
|
||||
Package: b.GenOpts.LanguageOpts.ManglePackageName(b.APIPackage, defaultOperationsTarget),
|
||||
ReceiverName: receiver,
|
||||
ID: id,
|
||||
Name: name,
|
||||
Path: fmt.Sprintf("%q", name),
|
||||
ValueExpression: fmt.Sprintf("%s.%s", receiver, id),
|
||||
Description: trimBOM(hdr.Description),
|
||||
Default: hdr.Default,
|
||||
HasDefault: hdr.Default != nil,
|
||||
Converter: stringConverters[tpe.GoType],
|
||||
Formatter: stringFormatters[tpe.GoType],
|
||||
ZeroValue: tpe.Zero(),
|
||||
CollectionFormat: hdr.CollectionFormat,
|
||||
IndexVar: "i",
|
||||
sharedValidations: sharedValidations{
|
||||
Required: true,
|
||||
SchemaValidations: hdr.Validations(), // NOTE: Required is not defined by the Swagger schema for header. Set arbitrarily to true for convenience in templates.
|
||||
},
|
||||
resolvedType: tpe,
|
||||
Package: b.GenOpts.LanguageOpts.ManglePackageName(b.APIPackage, defaultOperationsTarget),
|
||||
ReceiverName: receiver,
|
||||
ID: id,
|
||||
Name: name,
|
||||
Path: fmt.Sprintf("%q", name),
|
||||
ValueExpression: fmt.Sprintf("%s.%s", receiver, id),
|
||||
Description: trimBOM(hdr.Description),
|
||||
Default: hdr.Default,
|
||||
HasDefault: hdr.Default != nil,
|
||||
Converter: stringConverters[tpe.GoType],
|
||||
Formatter: stringFormatters[tpe.GoType],
|
||||
ZeroValue: tpe.Zero(),
|
||||
CollectionFormat: hdr.CollectionFormat,
|
||||
IndexVar: "i",
|
||||
}
|
||||
res.HasValidations, res.HasSliceValidations = b.HasValidations(hdr.CommonValidations, res.resolvedType)
|
||||
|
||||
@@ -625,8 +625,12 @@ func (b *codeGenOpBuilder) MakeHeader(receiver, name string, hdr spec.Header) (G
|
||||
|
||||
func (b *codeGenOpBuilder) MakeHeaderItem(receiver, paramName, indexVar, path, valueExpression string, items, parent *spec.Items) (GenItems, error) {
|
||||
var res GenItems
|
||||
res.resolvedType = simpleResolvedType(items.Type, items.Format, items.Items)
|
||||
res.sharedValidations = sharedValidationsFromSimple(items.CommonValidations, false)
|
||||
res.resolvedType = simpleResolvedType(items.Type, items.Format, items.Items, &items.CommonValidations)
|
||||
|
||||
res.sharedValidations = sharedValidations{
|
||||
Required: false,
|
||||
SchemaValidations: items.Validations(),
|
||||
}
|
||||
res.Name = paramName
|
||||
res.Path = path
|
||||
res.Location = "header"
|
||||
@@ -656,18 +660,20 @@ func (b *codeGenOpBuilder) MakeHeaderItem(receiver, paramName, indexVar, path, v
|
||||
|
||||
// HasValidations resolves the validation status for simple schema objects
|
||||
func (b *codeGenOpBuilder) HasValidations(sh spec.CommonValidations, rt resolvedType) (hasValidations bool, hasSliceValidations bool) {
|
||||
hasNumberValidation := sh.Maximum != nil || sh.Minimum != nil || sh.MultipleOf != nil
|
||||
hasStringValidation := sh.MaxLength != nil || sh.MinLength != nil || sh.Pattern != ""
|
||||
hasSliceValidations = sh.MaxItems != nil || sh.MinItems != nil || sh.UniqueItems || len(sh.Enum) > 0
|
||||
hasValidations = hasNumberValidation || hasStringValidation || hasSliceValidations || hasFormatValidation(rt)
|
||||
hasSliceValidations = sh.HasArrayValidations() || sh.HasEnum()
|
||||
hasValidations = sh.HasNumberValidations() || sh.HasStringValidations() || hasSliceValidations || hasFormatValidation(rt)
|
||||
return
|
||||
}
|
||||
|
||||
func (b *codeGenOpBuilder) MakeParameterItem(receiver, paramName, indexVar, path, valueExpression, location string, resolver *typeResolver, items, parent *spec.Items) (GenItems, error) {
|
||||
debugLog("making parameter item recv=%s param=%s index=%s valueExpr=%s path=%s location=%s", receiver, paramName, indexVar, valueExpression, path, location)
|
||||
var res GenItems
|
||||
res.resolvedType = simpleResolvedType(items.Type, items.Format, items.Items)
|
||||
res.sharedValidations = sharedValidationsFromSimple(items.CommonValidations, false)
|
||||
res.resolvedType = simpleResolvedType(items.Type, items.Format, items.Items, &items.CommonValidations)
|
||||
|
||||
res.sharedValidations = sharedValidations{
|
||||
Required: false,
|
||||
SchemaValidations: items.Validations(),
|
||||
}
|
||||
res.Name = paramName
|
||||
res.Path = path
|
||||
res.Location = location
|
||||
@@ -741,8 +747,11 @@ func (b *codeGenOpBuilder) MakeParameter(receiver string, resolver *typeResolver
|
||||
}
|
||||
} else {
|
||||
// Process parameters declared in other inputs: path, query, header (SimpleSchema)
|
||||
res.resolvedType = simpleResolvedType(param.Type, param.Format, param.Items)
|
||||
res.sharedValidations = sharedValidationsFromSimple(param.CommonValidations, param.Required)
|
||||
res.resolvedType = simpleResolvedType(param.Type, param.Format, param.Items, ¶m.CommonValidations)
|
||||
res.sharedValidations = sharedValidations{
|
||||
Required: param.Required,
|
||||
SchemaValidations: param.Validations(),
|
||||
}
|
||||
|
||||
res.ZeroValue = res.resolvedType.Zero()
|
||||
|
||||
@@ -960,7 +969,7 @@ func (b *codeGenOpBuilder) setBodyParamValidation(p *GenParameter) {
|
||||
|
||||
// makeSecuritySchemes produces a sorted list of security schemes for this operation
|
||||
func (b *codeGenOpBuilder) makeSecuritySchemes(receiver string) GenSecuritySchemes {
|
||||
return gatherSecuritySchemes(b.SecurityDefinitions, b.Name, b.Principal, receiver)
|
||||
return gatherSecuritySchemes(b.SecurityDefinitions, b.Name, b.Principal, receiver, b.GenOpts.PrincipalIsNullable())
|
||||
}
|
||||
|
||||
// makeSecurityRequirements produces a sorted list of security requirements for this operation.
|
||||
@@ -1006,7 +1015,7 @@ func (b *codeGenOpBuilder) saveResolveContext(resolver *typeResolver, schema *sp
|
||||
if b.PristineDoc == nil {
|
||||
b.PristineDoc = b.Doc.Pristine()
|
||||
}
|
||||
rslv := newTypeResolver(b.GenOpts.LanguageOpts.ManglePackageName(resolver.ModelsPackage, defaultModelsTarget), b.PristineDoc)
|
||||
rslv := newTypeResolver(b.GenOpts.LanguageOpts.ManglePackageName(resolver.ModelsPackage, defaultModelsTarget), b.DefaultImports[b.ModelsPackage], b.PristineDoc)
|
||||
|
||||
return rslv, b.cloneSchema(schema)
|
||||
}
|
||||
@@ -1026,7 +1035,7 @@ func (b *codeGenOpBuilder) liftExtraSchemas(resolver, rslv *typeResolver, bs *sp
|
||||
pkg := b.GenOpts.LanguageOpts.ManglePackageName(resolver.ModelsPackage, defaultModelsTarget)
|
||||
|
||||
// make a resolver for current package (i.e. operations)
|
||||
pg.TypeResolver = newTypeResolver("", rslv.Doc).withKeepDefinitionsPackage(pkg)
|
||||
pg.TypeResolver = newTypeResolver("", b.DefaultImports[b.APIPackage], rslv.Doc).withKeepDefinitionsPackage(pkg)
|
||||
pg.ExtraSchemas = make(map[string]GenSchema, len(sc.ExtraSchemas))
|
||||
pg.UseContainerInName = true
|
||||
|
||||
@@ -1062,7 +1071,10 @@ func (b *codeGenOpBuilder) buildOperationSchema(schemaPath, containerName, schem
|
||||
if sch == nil {
|
||||
sch = &spec.Schema{}
|
||||
}
|
||||
rslv := resolver
|
||||
shallowClonedResolver := *resolver
|
||||
shallowClonedResolver.ModelsFullPkg = b.DefaultImports[b.ModelsPackage]
|
||||
rslv := &shallowClonedResolver
|
||||
|
||||
sc := schemaGenContext{
|
||||
Path: schemaPath,
|
||||
Name: containerName,
|
||||
@@ -1203,7 +1215,7 @@ func (b *codeGenOpBuilder) analyzeTags() (string, []string, bool) {
|
||||
}
|
||||
}
|
||||
if tag == b.APIPackage {
|
||||
// confict with "operations" package is handled separately
|
||||
// conflict with "operations" package is handled separately
|
||||
tag = renameOperationPackage(intersected, tag)
|
||||
}
|
||||
b.APIPackage = b.GenOpts.LanguageOpts.ManglePackageName(tag, b.APIPackage) // actual package name
|
||||
@@ -1238,11 +1250,14 @@ func deconflictPrincipal(pkg string) string {
|
||||
// deconflictPkg renames package names which conflict with standard imports
|
||||
func deconflictPkg(pkg string, renamer func(string) string) string {
|
||||
switch pkg {
|
||||
case "api", "httptransport", "formats":
|
||||
// package conflict with variables
|
||||
case "api", "httptransport", "formats", "server":
|
||||
fallthrough
|
||||
// package conflict with go-openapi imports
|
||||
case "errors", "runtime", "middleware", "security", "spec", "strfmt", "loads", "swag", "validate":
|
||||
fallthrough
|
||||
case "tls", "http", "fmt", "strings", "log":
|
||||
// package conflict with stdlib/other lib imports
|
||||
case "tls", "http", "fmt", "strings", "log", "flags", "pflag", "json", "time":
|
||||
return renamer(pkg)
|
||||
}
|
||||
return pkg
|
||||
@@ -1260,5 +1275,16 @@ func renameOperationPackage(seenTags []string, pkg string) string {
|
||||
}
|
||||
|
||||
func renamePrincipalPackage(pkg string) string {
|
||||
// favors readability over perfect deconfliction
|
||||
return "auth"
|
||||
}
|
||||
|
||||
func renameServerPackage(pkg string) string {
|
||||
// favors readability over perfect deconfliction
|
||||
return "swagger" + pkg + "srv"
|
||||
}
|
||||
|
||||
func renameAPIPackage(pkg string) string {
|
||||
// favors readability over perfect deconfliction
|
||||
return "swagger" + pkg
|
||||
}
|
||||
+125
-62
@@ -197,6 +197,29 @@ func DefaultSectionOpts(gen *GenOpts) {
|
||||
|
||||
}
|
||||
|
||||
// MarkdownOpts for rendering a spec as markdown
|
||||
func MarkdownOpts() *LanguageOpts {
|
||||
opts := &LanguageOpts{}
|
||||
opts.Init()
|
||||
return opts
|
||||
}
|
||||
|
||||
// MarkdownSectionOpts for a given opts and output file.
|
||||
func MarkdownSectionOpts(gen *GenOpts, output string) {
|
||||
gen.Sections.Models = nil
|
||||
gen.Sections.OperationGroups = nil
|
||||
gen.Sections.Operations = nil
|
||||
gen.LanguageOpts = MarkdownOpts()
|
||||
gen.Sections.Application = []TemplateOpts{
|
||||
{
|
||||
Name: "markdowndocs",
|
||||
Source: "asset:markdownDocs",
|
||||
Target: filepath.Dir(output),
|
||||
FileName: filepath.Base(output),
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
// TemplateOpts allows for codegen customization
|
||||
type TemplateOpts struct {
|
||||
Name string `mapstructure:"name"`
|
||||
@@ -241,6 +264,7 @@ type GenOpts struct {
|
||||
ServerPackage string
|
||||
ClientPackage string
|
||||
Principal string
|
||||
PrincipalCustomIface bool // user-provided interface for Principal (non-nullable)
|
||||
Target string
|
||||
Sections SectionOpts
|
||||
LanguageOpts *LanguageOpts
|
||||
@@ -268,6 +292,8 @@ type GenOpts struct {
|
||||
AllowEnumCI bool
|
||||
StrictResponders bool
|
||||
AcceptDefinitionsOnly bool
|
||||
|
||||
templates *Repository // a shallow clone of the global template repository
|
||||
}
|
||||
|
||||
// CheckOpts carries out some global consistency checks on options.
|
||||
@@ -362,12 +388,23 @@ func (g *GenOpts) SpecPath() string {
|
||||
return specRel
|
||||
}
|
||||
|
||||
// PrincipalIsNullable indicates whether the principal type used for authentication
|
||||
// may be used as a pointer
|
||||
func (g *GenOpts) PrincipalIsNullable() bool {
|
||||
debugLog("Principal: %s, %t, isnullable: %t", g.Principal, g.PrincipalCustomIface, g.Principal != iface && !g.PrincipalCustomIface)
|
||||
return g.Principal != iface && !g.PrincipalCustomIface
|
||||
}
|
||||
|
||||
// EnsureDefaults for these gen opts
|
||||
func (g *GenOpts) EnsureDefaults() error {
|
||||
if g.defaultsEnsured {
|
||||
return nil
|
||||
}
|
||||
|
||||
g.templates = templates.ShallowClone()
|
||||
|
||||
g.templates.LoadDefaults()
|
||||
|
||||
if g.LanguageOpts == nil {
|
||||
g.LanguageOpts = DefaultLanguageFunc()
|
||||
}
|
||||
@@ -401,6 +438,7 @@ func (g *GenOpts) EnsureDefaults() error {
|
||||
|
||||
if g.Principal == "" {
|
||||
g.Principal = iface
|
||||
g.PrincipalCustomIface = false
|
||||
}
|
||||
|
||||
g.defaultsEnsured = true
|
||||
@@ -426,7 +464,9 @@ func (g *GenOpts) location(t *TemplateOpts, data interface{}) (string, string, e
|
||||
var tags []string
|
||||
tagsF := v.FieldByName("Tags")
|
||||
if tagsF.IsValid() {
|
||||
tags = tagsF.Interface().([]string)
|
||||
if tt, ok := tagsF.Interface().([]string); ok {
|
||||
tags = tt
|
||||
}
|
||||
}
|
||||
|
||||
var useTags bool
|
||||
@@ -482,7 +522,7 @@ func (g *GenOpts) render(t *TemplateOpts, data interface{}) ([]byte, error) {
|
||||
var templ *template.Template
|
||||
|
||||
if strings.HasPrefix(strings.ToLower(t.Source), "asset:") {
|
||||
tt, err := templates.Get(strings.TrimPrefix(t.Source, "asset:"))
|
||||
tt, err := g.templates.Get(strings.TrimPrefix(t.Source, "asset:"))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -492,7 +532,7 @@ func (g *GenOpts) render(t *TemplateOpts, data interface{}) ([]byte, error) {
|
||||
if templ == nil {
|
||||
// try to load from repository (and enable dependencies)
|
||||
name := swag.ToJSONName(strings.TrimSuffix(t.Source, ".gotmpl"))
|
||||
tt, err := templates.Get(name)
|
||||
tt, err := g.templates.Get(name)
|
||||
if err == nil {
|
||||
templ = tt
|
||||
}
|
||||
@@ -611,7 +651,8 @@ func (g *GenOpts) shouldRenderOperations() bool {
|
||||
|
||||
func (g *GenOpts) renderApplication(app *GenApp) error {
|
||||
log.Printf("rendering %d templates for application %s", len(g.Sections.Application), app.Name)
|
||||
for _, templ := range g.Sections.Application {
|
||||
for _, tp := range g.Sections.Application {
|
||||
templ := tp
|
||||
if !g.shouldRenderApp(&templ, app) {
|
||||
continue
|
||||
}
|
||||
@@ -624,7 +665,8 @@ func (g *GenOpts) renderApplication(app *GenApp) error {
|
||||
|
||||
func (g *GenOpts) renderOperationGroup(gg *GenOperationGroup) error {
|
||||
log.Printf("rendering %d templates for operation group %s", len(g.Sections.OperationGroups), g.Name)
|
||||
for _, templ := range g.Sections.OperationGroups {
|
||||
for _, tp := range g.Sections.OperationGroups {
|
||||
templ := tp
|
||||
if !g.shouldRenderOperations() {
|
||||
continue
|
||||
}
|
||||
@@ -638,7 +680,8 @@ func (g *GenOpts) renderOperationGroup(gg *GenOperationGroup) error {
|
||||
|
||||
func (g *GenOpts) renderOperation(gg *GenOperation) error {
|
||||
log.Printf("rendering %d templates for operation %s", len(g.Sections.Operations), g.Name)
|
||||
for _, templ := range g.Sections.Operations {
|
||||
for _, tp := range g.Sections.Operations {
|
||||
templ := tp
|
||||
if !g.shouldRenderOperations() {
|
||||
continue
|
||||
}
|
||||
@@ -652,7 +695,8 @@ func (g *GenOpts) renderOperation(gg *GenOperation) error {
|
||||
|
||||
func (g *GenOpts) renderDefinition(gg *GenDefinition) error {
|
||||
log.Printf("rendering %d templates for model %s", len(g.Sections.Models), gg.Name)
|
||||
for _, templ := range g.Sections.Models {
|
||||
for _, tp := range g.Sections.Models {
|
||||
templ := tp
|
||||
if !g.IncludeModel {
|
||||
continue
|
||||
}
|
||||
@@ -665,20 +709,18 @@ func (g *GenOpts) renderDefinition(gg *GenDefinition) error {
|
||||
}
|
||||
|
||||
func (g *GenOpts) setTemplates() error {
|
||||
templates.LoadDefaults()
|
||||
|
||||
if g.Template != "" {
|
||||
// set contrib templates
|
||||
if err := templates.LoadContrib(g.Template); err != nil {
|
||||
if err := g.templates.LoadContrib(g.Template); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
templates.SetAllowOverride(g.AllowTemplateOverride)
|
||||
g.templates.SetAllowOverride(g.AllowTemplateOverride)
|
||||
|
||||
if g.TemplateDir != "" {
|
||||
// set custom templates
|
||||
if err := templates.LoadDir(g.TemplateDir); err != nil {
|
||||
if err := g.templates.LoadDir(g.TemplateDir); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
@@ -690,27 +732,33 @@ func (g *GenOpts) defaultImports() map[string]string {
|
||||
baseImport := g.LanguageOpts.baseImport(g.Target)
|
||||
defaultImports := make(map[string]string, 50)
|
||||
|
||||
var modelsAlias, importPath string
|
||||
if g.ExistingModels == "" {
|
||||
// generated models
|
||||
importPath := path.Join(
|
||||
importPath = path.Join(
|
||||
baseImport,
|
||||
g.LanguageOpts.ManglePackagePath(g.ModelPackage, defaultModelsTarget))
|
||||
defaultImports[g.LanguageOpts.ManglePackageName(g.ModelPackage, defaultModelsTarget)] = importPath
|
||||
modelsAlias = g.LanguageOpts.ManglePackageName(g.ModelPackage, defaultModelsTarget)
|
||||
} else {
|
||||
// external models
|
||||
importPath := g.LanguageOpts.ManglePackagePath(g.ExistingModels, "")
|
||||
defaultImports["models"] = importPath
|
||||
importPath = g.LanguageOpts.ManglePackagePath(g.ExistingModels, "")
|
||||
modelsAlias = path.Base(defaultModelsTarget)
|
||||
}
|
||||
defaultImports[modelsAlias] = importPath
|
||||
|
||||
// resolve model representing an authenticated principal
|
||||
alias, _, target := g.resolvePrincipal()
|
||||
if alias == "" || target == g.ModelPackage || path.Base(target) == modelsAlias {
|
||||
// if principal is specified with the models generation package, do not import any extra package
|
||||
return defaultImports
|
||||
}
|
||||
|
||||
alias, _, target := g.resolvePrincipal()
|
||||
if alias != "" {
|
||||
if pth, _ := path.Split(target); pth != "" {
|
||||
// if principal is specified with an path, generate this import
|
||||
defaultImports[alias] = target
|
||||
} else {
|
||||
// if principal is specified with a relative path, assume it is located in generated target
|
||||
defaultImports[alias] = path.Join(baseImport, target)
|
||||
}
|
||||
if pth, _ := path.Split(target); pth != "" {
|
||||
// if principal is specified with a path, assume this is a fully qualified package and generate this import
|
||||
defaultImports[alias] = target
|
||||
} else {
|
||||
// if principal is specified with a relative path (no "/", e.g. internal.Principal), assume it is located in generated target
|
||||
defaultImports[alias] = path.Join(baseImport, target)
|
||||
}
|
||||
return defaultImports
|
||||
}
|
||||
@@ -873,16 +921,18 @@ func trimBOM(in string) string {
|
||||
}
|
||||
|
||||
// gatherSecuritySchemes produces a sorted representation from a map of spec security schemes
|
||||
func gatherSecuritySchemes(securitySchemes map[string]spec.SecurityScheme, appName, principal, receiver string) (security GenSecuritySchemes) {
|
||||
func gatherSecuritySchemes(securitySchemes map[string]spec.SecurityScheme, appName, principal, receiver string, nullable bool) (security GenSecuritySchemes) {
|
||||
for scheme, req := range securitySchemes {
|
||||
isOAuth2 := strings.ToLower(req.Type) == "oauth2"
|
||||
var scopes []string
|
||||
scopes := make([]string, 0, len(req.Scopes))
|
||||
genScopes := make([]GenSecurityScope, 0, len(req.Scopes))
|
||||
if isOAuth2 {
|
||||
for k := range req.Scopes {
|
||||
for k, v := range req.Scopes {
|
||||
scopes = append(scopes, k)
|
||||
genScopes = append(genScopes, GenSecurityScope{Name: k, Description: v})
|
||||
}
|
||||
sort.Strings(scopes)
|
||||
}
|
||||
sort.Strings(scopes)
|
||||
|
||||
security = append(security, GenSecurityScheme{
|
||||
AppName: appName,
|
||||
@@ -893,6 +943,7 @@ func gatherSecuritySchemes(securitySchemes map[string]spec.SecurityScheme, appNa
|
||||
IsAPIKeyAuth: strings.ToLower(req.Type) == "apikey",
|
||||
IsOAuth2: isOAuth2,
|
||||
Scopes: scopes,
|
||||
ScopesDesc: genScopes,
|
||||
Principal: principal,
|
||||
Source: req.In,
|
||||
// from original spec
|
||||
@@ -903,12 +954,26 @@ func gatherSecuritySchemes(securitySchemes map[string]spec.SecurityScheme, appNa
|
||||
AuthorizationURL: req.AuthorizationURL,
|
||||
TokenURL: req.TokenURL,
|
||||
Extensions: req.Extensions,
|
||||
|
||||
PrincipalIsNullable: nullable,
|
||||
})
|
||||
}
|
||||
sort.Sort(security)
|
||||
return
|
||||
}
|
||||
|
||||
// securityRequirements just clones the original SecurityRequirements from either the spec
|
||||
// or an operation, without any modification. This is used to generate documentation.
|
||||
func securityRequirements(orig []map[string][]string) (result []analysis.SecurityRequirement) {
|
||||
for _, r := range orig {
|
||||
for k, v := range r {
|
||||
result = append(result, analysis.SecurityRequirement{Name: k, Scopes: v})
|
||||
}
|
||||
}
|
||||
// TODO(fred): sort this for stable generation
|
||||
return
|
||||
}
|
||||
|
||||
// gatherExtraSchemas produces a sorted list of extra schemas.
|
||||
//
|
||||
// ExtraSchemas are inlined types rendered in the same model file.
|
||||
@@ -927,42 +992,23 @@ func gatherExtraSchemas(extraMap map[string]GenSchema) (extras GenSchemaList) {
|
||||
return
|
||||
}
|
||||
|
||||
func sharedValidationsFromSimple(v spec.CommonValidations, isRequired bool) (sh sharedValidations) {
|
||||
sh = sharedValidations{
|
||||
Required: isRequired,
|
||||
Maximum: v.Maximum,
|
||||
ExclusiveMaximum: v.ExclusiveMaximum,
|
||||
Minimum: v.Minimum,
|
||||
ExclusiveMinimum: v.ExclusiveMinimum,
|
||||
MaxLength: v.MaxLength,
|
||||
MinLength: v.MinLength,
|
||||
Pattern: v.Pattern,
|
||||
MaxItems: v.MaxItems,
|
||||
MinItems: v.MinItems,
|
||||
UniqueItems: v.UniqueItems,
|
||||
MultipleOf: v.MultipleOf,
|
||||
Enum: v.Enum,
|
||||
func getExtraSchemes(ext spec.Extensions) []string {
|
||||
if ess, ok := ext.GetStringSlice(xSchemes); ok {
|
||||
return ess
|
||||
}
|
||||
return
|
||||
return nil
|
||||
}
|
||||
|
||||
func sharedValidationsFromSchema(v spec.Schema, isRequired bool) (sh sharedValidations) {
|
||||
sh = sharedValidations{
|
||||
Required: isRequired,
|
||||
Maximum: v.Maximum,
|
||||
ExclusiveMaximum: v.ExclusiveMaximum,
|
||||
Minimum: v.Minimum,
|
||||
ExclusiveMinimum: v.ExclusiveMinimum,
|
||||
MaxLength: v.MaxLength,
|
||||
MinLength: v.MinLength,
|
||||
Pattern: v.Pattern,
|
||||
MaxItems: v.MaxItems,
|
||||
MinItems: v.MinItems,
|
||||
UniqueItems: v.UniqueItems,
|
||||
MultipleOf: v.MultipleOf,
|
||||
Enum: v.Enum,
|
||||
}
|
||||
return
|
||||
func gatherURISchemes(swsp *spec.Swagger, operation spec.Operation) ([]string, []string) {
|
||||
var extraSchemes []string
|
||||
extraSchemes = append(extraSchemes, getExtraSchemes(operation.Extensions)...)
|
||||
extraSchemes = concatUnique(getExtraSchemes(swsp.Extensions), extraSchemes)
|
||||
sort.Strings(extraSchemes)
|
||||
|
||||
schemes := concatUnique(swsp.Schemes, operation.Schemes)
|
||||
sort.Strings(schemes)
|
||||
|
||||
return schemes, extraSchemes
|
||||
}
|
||||
|
||||
func dumpData(data interface{}) error {
|
||||
@@ -978,3 +1024,20 @@ func importAlias(pkg string) string {
|
||||
_, k := path.Split(pkg)
|
||||
return k
|
||||
}
|
||||
|
||||
// concatUnique concatenate collections of strings with deduplication
|
||||
func concatUnique(collections ...[]string) []string {
|
||||
resultSet := make(map[string]struct{})
|
||||
for _, c := range collections {
|
||||
for _, i := range c {
|
||||
if _, ok := resultSet[i]; !ok {
|
||||
resultSet[i] = struct{}{}
|
||||
}
|
||||
}
|
||||
}
|
||||
result := make([]string, 0, len(resultSet))
|
||||
for k := range resultSet {
|
||||
result = append(result, k)
|
||||
}
|
||||
return result
|
||||
}
|
||||
+3
-3
@@ -119,7 +119,7 @@ func (g *GenOpts) printFlattenOpts() {
|
||||
log.Printf("preprocessing spec with option: %s", preprocessingOption)
|
||||
}
|
||||
|
||||
//findSwaggerSpec fetches a default swagger spec if none is provided
|
||||
// findSwaggerSpec fetches a default swagger spec if none is provided
|
||||
func findSwaggerSpec(nm string) (string, error) {
|
||||
specs := []string{"swagger.json", "swagger.yml", "swagger.yaml"}
|
||||
if nm != "" {
|
||||
@@ -168,7 +168,7 @@ func WithAutoXOrder(specPath string) string {
|
||||
for i, prop := range props {
|
||||
if pSlice, ok := prop.Value.(yaml.MapSlice); ok {
|
||||
isObject := false
|
||||
xOrderIndex := -1 //Find if x-order already exists
|
||||
xOrderIndex := -1 // find if x-order already exists
|
||||
|
||||
for i, v := range pSlice {
|
||||
if v.Key == "type" && v.Value == object {
|
||||
@@ -180,7 +180,7 @@ func WithAutoXOrder(specPath string) string {
|
||||
}
|
||||
}
|
||||
|
||||
if xOrderIndex > -1 { //Override existing x-order
|
||||
if xOrderIndex > -1 { // override existing x-order
|
||||
pSlice[xOrderIndex] = yaml.MapItem{Key: xOrder, Value: i}
|
||||
} else { // append new x-order
|
||||
pSlice = append(pSlice, yaml.MapItem{Key: xOrder, Value: i})
|
||||
|
||||
+211
-69
@@ -8,6 +8,7 @@ import (
|
||||
"strconv"
|
||||
"strings"
|
||||
|
||||
"github.com/go-openapi/analysis"
|
||||
"github.com/go-openapi/spec"
|
||||
)
|
||||
|
||||
@@ -94,6 +95,106 @@ type GenSchema struct {
|
||||
WantsMarshalBinary bool // do we generate MarshalBinary interface?
|
||||
StructTags []string
|
||||
ExtraImports map[string]string // non-standard imports detected when using external types
|
||||
ExternalDocs *spec.ExternalDocumentation
|
||||
}
|
||||
|
||||
func (g GenSchema) renderMarshalTag() string {
|
||||
if g.HasBaseType {
|
||||
return "-"
|
||||
}
|
||||
|
||||
var result strings.Builder
|
||||
|
||||
result.WriteString(g.OriginalName)
|
||||
|
||||
if !g.Required && g.IsEmptyOmitted {
|
||||
result.WriteString(",omitempty")
|
||||
}
|
||||
|
||||
if g.IsJSONString {
|
||||
result.WriteString(",string")
|
||||
}
|
||||
|
||||
return result.String()
|
||||
}
|
||||
|
||||
// PrintTags takes care of rendering tags for a struct field
|
||||
func (g GenSchema) PrintTags() string {
|
||||
tags := make(map[string]string, 3)
|
||||
orderedTags := make([]string, 0, 3)
|
||||
|
||||
tags["json"] = g.renderMarshalTag()
|
||||
orderedTags = append(orderedTags, "json")
|
||||
|
||||
if len(g.XMLName) > 0 {
|
||||
if !g.Required && g.IsEmptyOmitted {
|
||||
tags["xml"] = g.XMLName + ",omitempty"
|
||||
} else {
|
||||
tags["xml"] = g.XMLName
|
||||
}
|
||||
orderedTags = append(orderedTags, "xml")
|
||||
}
|
||||
|
||||
// Add extra struct tags, only if the tag hasn't already been set, i.e. example.
|
||||
// Extra struct tags have the same value has the `json` tag.
|
||||
for _, tag := range g.StructTags {
|
||||
if _, exists := tags[tag]; exists {
|
||||
// dedupe
|
||||
continue
|
||||
}
|
||||
|
||||
if tag == "example" && len(g.Example) > 0 {
|
||||
// only add example tag if it's contained in the struct tags
|
||||
tags["example"] = g.Example // json representation of the example object
|
||||
} else {
|
||||
tags[tag] = tags["json"]
|
||||
}
|
||||
|
||||
orderedTags = append(orderedTags, tag)
|
||||
}
|
||||
|
||||
// Assemble the tags in key value pairs with the value properly quoted.
|
||||
kvPairs := make([]string, 0, len(orderedTags)+1)
|
||||
for _, key := range orderedTags {
|
||||
kvPairs = append(kvPairs, fmt.Sprintf("%s:%s", key, strconv.Quote(tags[key])))
|
||||
}
|
||||
|
||||
if len(g.CustomTag) > 0 {
|
||||
kvPairs = append(kvPairs, g.CustomTag)
|
||||
}
|
||||
|
||||
// Join the key value pairs by a space.
|
||||
completeTag := strings.Join(kvPairs, " ")
|
||||
|
||||
// If the values contain a backtick, we cannot render the tag using backticks because Go does not support
|
||||
// escaping backticks in raw string literals.
|
||||
valuesHaveBacktick := false
|
||||
for _, value := range tags {
|
||||
if !strconv.CanBackquote(value) {
|
||||
valuesHaveBacktick = true
|
||||
break
|
||||
}
|
||||
}
|
||||
|
||||
if !valuesHaveBacktick {
|
||||
return fmt.Sprintf("`%s`", completeTag)
|
||||
}
|
||||
|
||||
// We have to escape the tag again to put it in a literal with double quotes as the tag format uses double quotes.
|
||||
return strconv.Quote(completeTag)
|
||||
}
|
||||
|
||||
// UnderlyingType tells the go type or the aliased go type
|
||||
func (g GenSchema) UnderlyingType() string {
|
||||
if g.IsAliased {
|
||||
return g.AliasedType
|
||||
}
|
||||
return g.GoType
|
||||
}
|
||||
|
||||
// ToString returns a string conversion expression for the schema
|
||||
func (g GenSchema) ToString() string {
|
||||
return g.resolvedType.ToString(g.ValueExpression)
|
||||
}
|
||||
|
||||
func (g GenSchemaList) Len() int { return len(g) }
|
||||
@@ -122,32 +223,13 @@ func (g GenSchemaList) Less(i, j int) bool {
|
||||
}
|
||||
|
||||
type sharedValidations struct {
|
||||
HasValidations bool
|
||||
Required bool
|
||||
spec.SchemaValidations
|
||||
|
||||
// String validations
|
||||
MaxLength *int64
|
||||
MinLength *int64
|
||||
Pattern string
|
||||
|
||||
// Number validations
|
||||
MultipleOf *float64
|
||||
Minimum *float64
|
||||
Maximum *float64
|
||||
ExclusiveMinimum bool
|
||||
ExclusiveMaximum bool
|
||||
|
||||
Enum []interface{}
|
||||
ItemsEnum []interface{}
|
||||
|
||||
// Slice validations
|
||||
MinItems *int64
|
||||
MaxItems *int64
|
||||
UniqueItems bool
|
||||
HasSliceValidations bool
|
||||
|
||||
// Not used yet (perhaps intended for maxProperties, minProperties validations?)
|
||||
NeedsSize bool
|
||||
HasValidations bool
|
||||
HasContextValidations bool
|
||||
Required bool
|
||||
HasSliceValidations bool
|
||||
ItemsEnum []interface{}
|
||||
|
||||
// NOTE: "patternProperties" and "dependencies" not supported by Swagger 2.0
|
||||
}
|
||||
@@ -176,6 +258,20 @@ type GenResponse struct {
|
||||
|
||||
StrictResponders bool
|
||||
OperationName string
|
||||
Examples GenResponseExamples
|
||||
}
|
||||
|
||||
// GenResponseExamples is a sortable collection []GenResponseExample
|
||||
type GenResponseExamples []GenResponseExample
|
||||
|
||||
func (g GenResponseExamples) Len() int { return len(g) }
|
||||
func (g GenResponseExamples) Swap(i, j int) { g[i], g[j] = g[j], g[i] }
|
||||
func (g GenResponseExamples) Less(i, j int) bool { return g[i].MediaType < g[j].MediaType }
|
||||
|
||||
// GenResponseExample captures an example provided for a response for some mime type
|
||||
type GenResponseExample struct {
|
||||
MediaType string
|
||||
Example interface{}
|
||||
}
|
||||
|
||||
// GenHeader represents a header on a response for code generation
|
||||
@@ -210,11 +306,16 @@ type GenHeader struct {
|
||||
|
||||
// ItemsDepth returns a string "items.items..." with as many items as the level of nesting of the array.
|
||||
// For a header objects it always returns "".
|
||||
func (g *GenHeader) ItemsDepth() string {
|
||||
func (h *GenHeader) ItemsDepth() string {
|
||||
// NOTE: this is currently used by templates to generate explicit comments in nested structures
|
||||
return ""
|
||||
}
|
||||
|
||||
// ToString returns a string conversion expression for the header
|
||||
func (h GenHeader) ToString() string {
|
||||
return h.resolvedType.ToString(h.ValueExpression)
|
||||
}
|
||||
|
||||
// GenHeaders is a sorted collection of headers for codegen
|
||||
type GenHeaders []GenHeader
|
||||
|
||||
@@ -260,8 +361,8 @@ type GenParameter struct {
|
||||
Child *GenItems
|
||||
Parent *GenItems
|
||||
|
||||
/// Unused
|
||||
//BodyParam *GenParameter
|
||||
// Unused
|
||||
// BodyParam *GenParameter
|
||||
|
||||
Default interface{}
|
||||
HasDefault bool
|
||||
@@ -323,6 +424,16 @@ func (g *GenParameter) ItemsDepth() string {
|
||||
return ""
|
||||
}
|
||||
|
||||
// UnderlyingType tells the go type or the aliased go type
|
||||
func (g GenParameter) UnderlyingType() string {
|
||||
return g.GoType
|
||||
}
|
||||
|
||||
// ToString returns a string conversion expression for the parameter
|
||||
func (g GenParameter) ToString() string {
|
||||
return g.resolvedType.ToString(g.ValueExpression)
|
||||
}
|
||||
|
||||
// GenParameters represents a sorted parameter collection
|
||||
type GenParameters []GenParameter
|
||||
|
||||
@@ -377,6 +488,16 @@ func (g *GenItems) ItemsDepth() string {
|
||||
return strings.Repeat("items.", i)
|
||||
}
|
||||
|
||||
// UnderlyingType tells the go type or the aliased go type
|
||||
func (g GenItems) UnderlyingType() string {
|
||||
return g.GoType
|
||||
}
|
||||
|
||||
// ToString returns a string conversion expression for the item
|
||||
func (g GenItems) ToString() string {
|
||||
return g.resolvedType.ToString(g.ValueExpression)
|
||||
}
|
||||
|
||||
// GenOperationGroup represents a named (tagged) group of operations
|
||||
type GenOperationGroup struct {
|
||||
GenCommon
|
||||
@@ -470,10 +591,12 @@ type GenOperation struct {
|
||||
ExtraSchemas GenSchemaList
|
||||
PackageAlias string
|
||||
|
||||
Authorized bool
|
||||
Security []GenSecurityRequirements
|
||||
SecurityDefinitions GenSecuritySchemes
|
||||
Principal string
|
||||
Authorized bool
|
||||
Security []GenSecurityRequirements // resolved security requirements for the operation
|
||||
SecurityDefinitions GenSecuritySchemes
|
||||
SecurityRequirements []analysis.SecurityRequirement // original security requirements as per the spec (for doc)
|
||||
Principal string
|
||||
PrincipalIsNullable bool
|
||||
|
||||
SuccessResponse *GenResponse
|
||||
SuccessResponses []GenResponse
|
||||
@@ -494,15 +617,20 @@ type GenOperation struct {
|
||||
HasBodyParams bool
|
||||
HasStreamingResponse bool
|
||||
|
||||
Schemes []string
|
||||
ExtraSchemes []string
|
||||
ProducesMediaTypes []string
|
||||
ConsumesMediaTypes []string
|
||||
TimeoutName string
|
||||
Schemes []string
|
||||
ExtraSchemes []string
|
||||
SchemeOverrides []string // original scheme overrides for operation, as per spec (for doc)
|
||||
ExtraSchemeOverrides []string // original extra scheme overrides for operation, as per spec (for doc)
|
||||
ProducesMediaTypes []string
|
||||
ConsumesMediaTypes []string
|
||||
TimeoutName string
|
||||
|
||||
Extensions map[string]interface{}
|
||||
|
||||
StrictResponders bool
|
||||
ExternalDocs *spec.ExternalDocumentation
|
||||
Produces []string // original produces for operation (for doc)
|
||||
Consumes []string // original consumes for operation (for doc)
|
||||
}
|
||||
|
||||
// GenOperations represents a list of operations to generate
|
||||
@@ -517,28 +645,33 @@ func (g GenOperations) Swap(i, j int) { g[i], g[j] = g[j], g[i] }
|
||||
// from a swagger spec
|
||||
type GenApp struct {
|
||||
GenCommon
|
||||
APIPackage string
|
||||
Package string
|
||||
ReceiverName string
|
||||
Name string
|
||||
Principal string
|
||||
DefaultConsumes string
|
||||
DefaultProduces string
|
||||
Host string
|
||||
BasePath string
|
||||
Info *spec.Info
|
||||
ExternalDocs *spec.ExternalDocumentation
|
||||
Imports map[string]string
|
||||
DefaultImports map[string]string
|
||||
Schemes []string
|
||||
ExtraSchemes []string
|
||||
Consumes GenSerGroups
|
||||
Produces GenSerGroups
|
||||
SecurityDefinitions GenSecuritySchemes
|
||||
Models []GenDefinition
|
||||
Operations GenOperations
|
||||
OperationGroups GenOperationGroups
|
||||
SwaggerJSON string
|
||||
APIPackage string
|
||||
ServerPackageAlias string
|
||||
APIPackageAlias string
|
||||
Package string
|
||||
ReceiverName string
|
||||
Name string
|
||||
Principal string
|
||||
PrincipalIsNullable bool
|
||||
DefaultConsumes string
|
||||
DefaultProduces string
|
||||
Host string
|
||||
BasePath string
|
||||
Info *spec.Info
|
||||
ExternalDocs *spec.ExternalDocumentation
|
||||
Tags []spec.Tag
|
||||
Imports map[string]string
|
||||
DefaultImports map[string]string
|
||||
Schemes []string
|
||||
ExtraSchemes []string
|
||||
Consumes GenSerGroups
|
||||
Produces GenSerGroups
|
||||
SecurityDefinitions GenSecuritySchemes
|
||||
SecurityRequirements []analysis.SecurityRequirement // original security requirements as per the spec (for doc)
|
||||
Models []GenDefinition
|
||||
Operations GenOperations
|
||||
OperationGroups GenOperationGroups
|
||||
SwaggerJSON string
|
||||
// Embedded specs: this is important for when the generated server adds routes.
|
||||
// NOTE: there is a distinct advantage to having this in runtime rather than generated code.
|
||||
// We are not ever going to generate the router.
|
||||
@@ -613,16 +746,18 @@ type GenSerializer struct {
|
||||
|
||||
// GenSecurityScheme represents a security scheme for code generation
|
||||
type GenSecurityScheme struct {
|
||||
AppName string
|
||||
ID string
|
||||
Name string
|
||||
ReceiverName string
|
||||
IsBasicAuth bool
|
||||
IsAPIKeyAuth bool
|
||||
IsOAuth2 bool
|
||||
Scopes []string
|
||||
Source string
|
||||
Principal string
|
||||
AppName string
|
||||
ID string
|
||||
Name string
|
||||
ReceiverName string
|
||||
IsBasicAuth bool
|
||||
IsAPIKeyAuth bool
|
||||
IsOAuth2 bool
|
||||
Scopes []string
|
||||
Source string
|
||||
Principal string
|
||||
PrincipalIsNullable bool
|
||||
|
||||
// from spec.SecurityScheme
|
||||
Description string
|
||||
Type string
|
||||
@@ -631,6 +766,7 @@ type GenSecurityScheme struct {
|
||||
AuthorizationURL string
|
||||
TokenURL string
|
||||
Extensions map[string]interface{}
|
||||
ScopesDesc []GenSecurityScope
|
||||
}
|
||||
|
||||
// GenSecuritySchemes sorted representation of serializers
|
||||
@@ -646,6 +782,12 @@ type GenSecurityRequirement struct {
|
||||
Scopes []string
|
||||
}
|
||||
|
||||
// GenSecurityScope represents a scope descriptor for an OAuth2 security scheme
|
||||
type GenSecurityScope struct {
|
||||
Name string
|
||||
Description string
|
||||
}
|
||||
|
||||
// GenSecurityRequirements represents a compounded security requirement specification.
|
||||
// In a []GenSecurityRequirements complete requirements specification,
|
||||
// outer elements are interpreted as optional requirements (OR), and
|
||||
|
||||
+130
-37
@@ -49,6 +49,25 @@ func GenerateSupport(name string, modelNames, operationIDs []string, opts *GenOp
|
||||
return generator.GenerateSupport(nil)
|
||||
}
|
||||
|
||||
// GenerateMarkdown documentation for a swagger specification
|
||||
func GenerateMarkdown(output string, modelNames, operationIDs []string, opts *GenOpts) error {
|
||||
if output == "." || output == "" {
|
||||
output = "markdown.md"
|
||||
}
|
||||
|
||||
if err := opts.EnsureDefaults(); err != nil {
|
||||
return err
|
||||
}
|
||||
MarkdownSectionOpts(opts, output)
|
||||
|
||||
generator, err := newAppGenerator("", modelNames, operationIDs, opts)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return generator.GenerateMarkdown()
|
||||
}
|
||||
|
||||
func newAppGenerator(name string, modelNames, operationIDs []string, opts *GenOpts) (*appGenerator, error) {
|
||||
if err := opts.CheckOpts(); err != nil {
|
||||
return nil, err
|
||||
@@ -142,7 +161,8 @@ func (a *appGenerator) Generate() error {
|
||||
// templates are now lazy loaded so there is concurrent map access I can't guard
|
||||
if a.GenOpts.IncludeModel {
|
||||
log.Printf("rendering %d models", len(app.Models))
|
||||
for _, mod := range app.Models {
|
||||
for _, md := range app.Models {
|
||||
mod := md
|
||||
mod.IncludeModel = true
|
||||
mod.IncludeValidator = a.GenOpts.IncludeValidator
|
||||
if err := a.GenOpts.renderDefinition(&mod); err != nil {
|
||||
@@ -153,9 +173,11 @@ func (a *appGenerator) Generate() error {
|
||||
|
||||
if a.GenOpts.IncludeHandler {
|
||||
log.Printf("rendering %d operation groups (tags)", app.OperationGroups.Len())
|
||||
for _, opg := range app.OperationGroups {
|
||||
for _, g := range app.OperationGroups {
|
||||
opg := g
|
||||
log.Printf("rendering %d operations for %s", opg.Operations.Len(), opg.Name)
|
||||
for _, op := range opg.Operations {
|
||||
for _, p := range opg.Operations {
|
||||
op := p
|
||||
if err := a.GenOpts.renderOperation(&op); err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -190,11 +212,23 @@ func (a *appGenerator) GenerateSupport(ap *GenApp) error {
|
||||
baseImport := a.GenOpts.LanguageOpts.baseImport(a.Target)
|
||||
serverPath := path.Join(baseImport,
|
||||
a.GenOpts.LanguageOpts.ManglePackagePath(a.ServerPackage, defaultServerTarget))
|
||||
app.DefaultImports[importAlias(serverPath)] = serverPath
|
||||
|
||||
pkgAlias := deconflictPkg(importAlias(serverPath), renameServerPackage)
|
||||
app.DefaultImports[pkgAlias] = serverPath
|
||||
app.ServerPackageAlias = pkgAlias
|
||||
|
||||
return a.GenOpts.renderApplication(app)
|
||||
}
|
||||
|
||||
func (a *appGenerator) GenerateMarkdown() error {
|
||||
app, err := a.makeCodegenApp()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return a.GenOpts.renderApplication(&app)
|
||||
}
|
||||
|
||||
func (a *appGenerator) makeSecuritySchemes() GenSecuritySchemes {
|
||||
requiredSecuritySchemes := make(map[string]spec.SecurityScheme, len(a.Analyzed.RequiredSecuritySchemes()))
|
||||
for _, scheme := range a.Analyzed.RequiredSecuritySchemes() {
|
||||
@@ -202,7 +236,7 @@ func (a *appGenerator) makeSecuritySchemes() GenSecuritySchemes {
|
||||
requiredSecuritySchemes[scheme] = *req
|
||||
}
|
||||
}
|
||||
return gatherSecuritySchemes(requiredSecuritySchemes, a.Name, a.Principal, a.Receiver)
|
||||
return gatherSecuritySchemes(requiredSecuritySchemes, a.Name, a.Principal, a.Receiver, a.GenOpts.PrincipalIsNullable())
|
||||
}
|
||||
|
||||
func (a *appGenerator) makeCodegenApp() (GenApp, error) {
|
||||
@@ -219,9 +253,14 @@ func (a *appGenerator) makeCodegenApp() (GenApp, error) {
|
||||
|
||||
baseImport := a.GenOpts.LanguageOpts.baseImport(a.Target)
|
||||
defaultImports := a.GenOpts.defaultImports()
|
||||
imports := a.GenOpts.initImports(a.OperationsPackage)
|
||||
|
||||
log.Println("planning definitions")
|
||||
imports := make(map[string]string, 50)
|
||||
alias := deconflictPkg(a.GenOpts.LanguageOpts.ManglePackageName(a.OperationsPackage, defaultOperationsTarget), renameAPIPackage)
|
||||
imports[alias] = path.Join(
|
||||
baseImport,
|
||||
a.GenOpts.LanguageOpts.ManglePackagePath(a.OperationsPackage, defaultOperationsTarget))
|
||||
|
||||
log.Printf("planning definitions (found: %d)", len(a.Models))
|
||||
|
||||
genModels := make(GenDefinitions, 0, len(a.Models))
|
||||
for mn, m := range a.Models {
|
||||
@@ -250,7 +289,7 @@ func (a *appGenerator) makeCodegenApp() (GenApp, error) {
|
||||
}
|
||||
sort.Sort(genModels)
|
||||
|
||||
log.Println("planning operations")
|
||||
log.Printf("planning operations (found: %d)", len(a.Operations))
|
||||
|
||||
genOps := make(GenOperations, 0, len(a.Operations))
|
||||
for operationName, opp := range a.Operations {
|
||||
@@ -318,15 +357,16 @@ func (a *appGenerator) makeCodegenApp() (GenApp, error) {
|
||||
}
|
||||
sort.Sort(genOps)
|
||||
|
||||
log.Println("grouping operations into packages")
|
||||
|
||||
opsGroupedByPackage := make(map[string]GenOperations, len(genOps))
|
||||
for _, operation := range genOps {
|
||||
opsGroupedByPackage[operation.PackageAlias] = append(opsGroupedByPackage[operation.PackageAlias], operation)
|
||||
}
|
||||
|
||||
log.Printf("grouping operations into packages (packages: %d)", len(opsGroupedByPackage))
|
||||
|
||||
opGroups := make(GenOperationGroups, 0, len(opsGroupedByPackage))
|
||||
for k, v := range opsGroupedByPackage {
|
||||
log.Printf("operations for package packages %q (found: %d)", k, len(v))
|
||||
sort.Sort(v)
|
||||
// trim duplicate extra schemas within the same package
|
||||
vv := make(GenOperations, 0, len(v))
|
||||
@@ -368,8 +408,7 @@ func (a *appGenerator) makeCodegenApp() (GenApp, error) {
|
||||
|
||||
log.Println("planning meta data and facades")
|
||||
|
||||
var collectedSchemes []string
|
||||
var extraSchemes []string
|
||||
var collectedSchemes, extraSchemes []string
|
||||
for _, op := range genOps {
|
||||
collectedSchemes = concatUnique(collectedSchemes, op.Schemes)
|
||||
extraSchemes = concatUnique(extraSchemes, op.ExtraSchemes)
|
||||
@@ -395,31 +434,36 @@ func (a *appGenerator) makeCodegenApp() (GenApp, error) {
|
||||
Copyright: a.GenOpts.Copyright,
|
||||
TargetImportPath: baseImport,
|
||||
},
|
||||
APIPackage: a.GenOpts.LanguageOpts.ManglePackageName(a.ServerPackage, defaultServerTarget),
|
||||
Package: a.Package,
|
||||
ReceiverName: receiver,
|
||||
Name: a.Name,
|
||||
Host: host,
|
||||
BasePath: basePath,
|
||||
Schemes: schemeOrDefault(collectedSchemes, a.DefaultScheme),
|
||||
ExtraSchemes: extraSchemes,
|
||||
ExternalDocs: sw.ExternalDocs,
|
||||
Info: sw.Info,
|
||||
Consumes: consumes,
|
||||
Produces: produces,
|
||||
DefaultConsumes: a.DefaultConsumes,
|
||||
DefaultProduces: a.DefaultProduces,
|
||||
DefaultImports: defaultImports,
|
||||
Imports: imports,
|
||||
SecurityDefinitions: security,
|
||||
Models: genModels,
|
||||
Operations: genOps,
|
||||
OperationGroups: opGroups,
|
||||
Principal: a.GenOpts.PrincipalAlias(),
|
||||
SwaggerJSON: generateReadableSpec(jsonb),
|
||||
FlatSwaggerJSON: generateReadableSpec(flatjsonb),
|
||||
ExcludeSpec: a.GenOpts.ExcludeSpec,
|
||||
GenOpts: a.GenOpts,
|
||||
APIPackage: a.GenOpts.LanguageOpts.ManglePackageName(a.ServerPackage, defaultServerTarget),
|
||||
APIPackageAlias: alias,
|
||||
Package: a.Package,
|
||||
ReceiverName: receiver,
|
||||
Name: a.Name,
|
||||
Host: host,
|
||||
BasePath: basePath,
|
||||
Schemes: schemeOrDefault(collectedSchemes, a.DefaultScheme),
|
||||
ExtraSchemes: extraSchemes,
|
||||
ExternalDocs: trimExternalDoc(sw.ExternalDocs),
|
||||
Tags: trimTags(sw.Tags),
|
||||
Info: trimInfo(sw.Info),
|
||||
Consumes: consumes,
|
||||
Produces: produces,
|
||||
DefaultConsumes: a.DefaultConsumes,
|
||||
DefaultProduces: a.DefaultProduces,
|
||||
DefaultImports: defaultImports,
|
||||
Imports: imports,
|
||||
SecurityDefinitions: security,
|
||||
SecurityRequirements: securityRequirements(a.SpecDoc.Spec().Security), // top level securityRequirements
|
||||
Models: genModels,
|
||||
Operations: genOps,
|
||||
OperationGroups: opGroups,
|
||||
Principal: a.GenOpts.PrincipalAlias(),
|
||||
SwaggerJSON: generateReadableSpec(jsonb),
|
||||
FlatSwaggerJSON: generateReadableSpec(flatjsonb),
|
||||
ExcludeSpec: a.GenOpts.ExcludeSpec,
|
||||
GenOpts: a.GenOpts,
|
||||
|
||||
PrincipalIsNullable: a.GenOpts.PrincipalIsNullable(),
|
||||
}, nil
|
||||
}
|
||||
|
||||
@@ -438,3 +482,52 @@ func generateReadableSpec(spec []byte) string {
|
||||
}
|
||||
return buf.String()
|
||||
}
|
||||
|
||||
func trimExternalDoc(in *spec.ExternalDocumentation) *spec.ExternalDocumentation {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
|
||||
return &spec.ExternalDocumentation{
|
||||
URL: in.URL,
|
||||
Description: trimBOM(in.Description),
|
||||
}
|
||||
}
|
||||
|
||||
func trimInfo(in *spec.Info) *spec.Info {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
|
||||
return &spec.Info{
|
||||
InfoProps: spec.InfoProps{
|
||||
Contact: in.Contact,
|
||||
Title: trimBOM(in.Title),
|
||||
Description: trimBOM(in.Description),
|
||||
TermsOfService: trimBOM(in.TermsOfService),
|
||||
License: in.License,
|
||||
Version: in.Version,
|
||||
},
|
||||
VendorExtensible: in.VendorExtensible,
|
||||
}
|
||||
}
|
||||
|
||||
func trimTags(in []spec.Tag) []spec.Tag {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
|
||||
tags := make([]spec.Tag, 0, len(in))
|
||||
|
||||
for _, tag := range in {
|
||||
tags = append(tags, spec.Tag{
|
||||
TagProps: spec.TagProps{
|
||||
Name: tag.Name,
|
||||
Description: trimBOM(tag.Description),
|
||||
ExternalDocs: trimExternalDoc(tag.ExternalDocs),
|
||||
},
|
||||
})
|
||||
}
|
||||
|
||||
return tags
|
||||
}
|
||||
+251
-7
@@ -5,10 +5,14 @@ import (
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"math"
|
||||
"os"
|
||||
"path"
|
||||
"path/filepath"
|
||||
"reflect"
|
||||
"strconv"
|
||||
"strings"
|
||||
"sync"
|
||||
"text/template"
|
||||
"text/template/parse"
|
||||
"unicode"
|
||||
@@ -16,6 +20,7 @@ import (
|
||||
"log"
|
||||
|
||||
"github.com/go-openapi/inflect"
|
||||
"github.com/go-openapi/runtime"
|
||||
"github.com/go-openapi/swag"
|
||||
"github.com/kr/pretty"
|
||||
)
|
||||
@@ -28,6 +33,8 @@ var (
|
||||
FuncMapFunc func(*LanguageOpts) template.FuncMap
|
||||
|
||||
templates *Repository
|
||||
|
||||
docFormat map[string]string
|
||||
)
|
||||
|
||||
func initTemplateRepo() {
|
||||
@@ -40,6 +47,11 @@ func initTemplateRepo() {
|
||||
assets = defaultAssets()
|
||||
protectedTemplates = defaultProtectedTemplates()
|
||||
templates = NewRepository(FuncMapFunc(DefaultLanguageFunc()))
|
||||
|
||||
docFormat = map[string]string{
|
||||
"binary": "binary (byte stream)",
|
||||
"byte": "byte (base64 string)",
|
||||
}
|
||||
}
|
||||
|
||||
// DefaultFuncMap yields a map with default functions for use n the templates.
|
||||
@@ -72,9 +84,11 @@ func DefaultFuncMap(lang *LanguageOpts) template.FuncMap {
|
||||
},
|
||||
"dropPackage": dropPackage,
|
||||
"upper": strings.ToUpper,
|
||||
"lower": strings.ToLower,
|
||||
"contains": swag.ContainsStrings,
|
||||
"padSurround": padSurround,
|
||||
"joinFilePath": filepath.Join,
|
||||
"joinPath": path.Join,
|
||||
"comment": padComment,
|
||||
"blockcomment": blockComment,
|
||||
"inspect": pretty.Sprint,
|
||||
@@ -85,6 +99,44 @@ func DefaultFuncMap(lang *LanguageOpts) template.FuncMap {
|
||||
"stringContains": strings.Contains,
|
||||
"imports": lang.imports,
|
||||
"dict": dict,
|
||||
"isInteger": isInteger,
|
||||
"escapeBackticks": func(arg string) string {
|
||||
return strings.ReplaceAll(arg, "`", "`+\"`\"+`")
|
||||
},
|
||||
"paramDocType": func(param GenParameter) string {
|
||||
return resolvedDocType(param.SwaggerType, param.SwaggerFormat, param.Child)
|
||||
},
|
||||
"headerDocType": func(header GenHeader) string {
|
||||
return resolvedDocType(header.SwaggerType, header.SwaggerFormat, header.Child)
|
||||
},
|
||||
"schemaDocType": func(in interface{}) string {
|
||||
switch schema := in.(type) {
|
||||
case GenSchema:
|
||||
return resolvedDocSchemaType(schema.SwaggerType, schema.SwaggerFormat, schema.Items)
|
||||
case *GenSchema:
|
||||
if schema == nil {
|
||||
return ""
|
||||
}
|
||||
return resolvedDocSchemaType(schema.SwaggerType, schema.SwaggerFormat, schema.Items)
|
||||
case GenDefinition:
|
||||
return resolvedDocSchemaType(schema.SwaggerType, schema.SwaggerFormat, schema.Items)
|
||||
case *GenDefinition:
|
||||
if schema == nil {
|
||||
return ""
|
||||
}
|
||||
return resolvedDocSchemaType(schema.SwaggerType, schema.SwaggerFormat, schema.Items)
|
||||
default:
|
||||
panic("dev error: schemaDocType should be called with GenSchema or GenDefinition")
|
||||
}
|
||||
},
|
||||
"schemaDocMapType": func(schema GenSchema) string {
|
||||
return resolvedDocElemType("object", schema.SwaggerFormat, &schema.resolvedType)
|
||||
},
|
||||
"docCollectionFormat": resolvedDocCollectionFormat,
|
||||
"trimSpace": strings.TrimSpace,
|
||||
"httpStatus": httpStatus,
|
||||
"cleanupEnumVariant": cleanupEnumVariant,
|
||||
"gt0": gt0,
|
||||
})
|
||||
}
|
||||
|
||||
@@ -98,6 +150,9 @@ func defaultAssets() map[string][]byte {
|
||||
"schemavalidator.gotmpl": MustAsset("templates/schemavalidator.gotmpl"),
|
||||
"schemapolymorphic.gotmpl": MustAsset("templates/schemapolymorphic.gotmpl"),
|
||||
"schemaembedded.gotmpl": MustAsset("templates/schemaembedded.gotmpl"),
|
||||
"validation/minimum.gotmpl": MustAsset("templates/validation/minimum.gotmpl"),
|
||||
"validation/maximum.gotmpl": MustAsset("templates/validation/maximum.gotmpl"),
|
||||
"validation/multipleOf.gotmpl": MustAsset("templates/validation/multipleOf.gotmpl"),
|
||||
|
||||
// schema serialization templates
|
||||
"additionalpropertiesserializer.gotmpl": MustAsset("templates/serializers/additionalpropertiesserializer.gotmpl"),
|
||||
@@ -117,6 +172,10 @@ func defaultAssets() map[string][]byte {
|
||||
"model.gotmpl": MustAsset("templates/model.gotmpl"),
|
||||
"header.gotmpl": MustAsset("templates/header.gotmpl"),
|
||||
|
||||
// simple schema generation helpers templates
|
||||
"simpleschema/defaultsvar.gotmpl": MustAsset("templates/simpleschema/defaultsvar.gotmpl"),
|
||||
"simpleschema/defaultsinit.gotmpl": MustAsset("templates/simpleschema/defaultsinit.gotmpl"),
|
||||
|
||||
"swagger_json_embed.gotmpl": MustAsset("templates/swagger_json_embed.gotmpl"),
|
||||
|
||||
// server templates
|
||||
@@ -135,6 +194,8 @@ func defaultAssets() map[string][]byte {
|
||||
"client/response.gotmpl": MustAsset("templates/client/response.gotmpl"),
|
||||
"client/client.gotmpl": MustAsset("templates/client/client.gotmpl"),
|
||||
"client/facade.gotmpl": MustAsset("templates/client/facade.gotmpl"),
|
||||
|
||||
"markdown/docs.gotmpl": MustAsset("templates/markdown/docs.gotmpl"),
|
||||
}
|
||||
}
|
||||
|
||||
@@ -167,13 +228,20 @@ func defaultProtectedTemplates() map[string]bool {
|
||||
"tuplefield": true,
|
||||
"tuplefieldIface": true,
|
||||
"typeSchemaType": true,
|
||||
"validationCustomformat": true,
|
||||
"validationPrimitive": true,
|
||||
"validationStructfield": true,
|
||||
"withBaseTypeBody": true,
|
||||
"withoutBaseTypeBody": true,
|
||||
"simpleschemaDefaultsvar": true,
|
||||
"simpleschemaDefaultsinit": true,
|
||||
|
||||
// all serializers TODO(fred)
|
||||
// validation helpers
|
||||
"validationCustomformat": true,
|
||||
"validationPrimitive": true,
|
||||
"validationStructfield": true,
|
||||
"withBaseTypeBody": true,
|
||||
"withoutBaseTypeBody": true,
|
||||
"validationMinimum": true,
|
||||
"validationMaximum": true,
|
||||
"validationMultipleOf": true,
|
||||
|
||||
// all serializers
|
||||
"additionalPropertiesSerializer": true,
|
||||
"tupleSerializer": true,
|
||||
"schemaSerializer": true,
|
||||
@@ -213,6 +281,31 @@ type Repository struct {
|
||||
templates map[string]*template.Template
|
||||
funcs template.FuncMap
|
||||
allowOverride bool
|
||||
mux sync.Mutex
|
||||
}
|
||||
|
||||
// ShallowClone a repository.
|
||||
//
|
||||
// Clones the maps of files and templates, so as to be able to use
|
||||
// the cloned repo concurrently.
|
||||
func (t *Repository) ShallowClone() *Repository {
|
||||
clone := &Repository{
|
||||
files: make(map[string]string, len(t.files)),
|
||||
templates: make(map[string]*template.Template, len(t.templates)),
|
||||
funcs: t.funcs,
|
||||
allowOverride: t.allowOverride,
|
||||
}
|
||||
|
||||
t.mux.Lock()
|
||||
defer t.mux.Unlock()
|
||||
|
||||
for k, file := range t.files {
|
||||
clone.files[k] = file
|
||||
}
|
||||
for k, tpl := range t.templates {
|
||||
clone.templates[k] = tpl
|
||||
}
|
||||
return clone
|
||||
}
|
||||
|
||||
// LoadDefaults will load the embedded templates
|
||||
@@ -532,7 +625,7 @@ func padComment(str string, pads ...string) string {
|
||||
}
|
||||
|
||||
func blockComment(str string) string {
|
||||
return strings.Replace(str, "*/", "[*]/", -1)
|
||||
return strings.ReplaceAll(str, "*/", "[*]/")
|
||||
}
|
||||
|
||||
func pascalize(arg string) string {
|
||||
@@ -566,6 +659,28 @@ func prefixForName(arg string) string {
|
||||
return "Nr"
|
||||
}
|
||||
|
||||
func replaceSpecialChar(in rune) string {
|
||||
switch in {
|
||||
case '.':
|
||||
return "-Dot-"
|
||||
case '+':
|
||||
return "-Plus-"
|
||||
case '-':
|
||||
return "-Dash-"
|
||||
case '#':
|
||||
return "-Hashtag-"
|
||||
}
|
||||
return string(in)
|
||||
}
|
||||
|
||||
func cleanupEnumVariant(in string) string {
|
||||
replaced := ""
|
||||
for _, char := range in {
|
||||
replaced += replaceSpecialChar(char)
|
||||
}
|
||||
return replaced
|
||||
}
|
||||
|
||||
func dict(values ...interface{}) (map[string]interface{}, error) {
|
||||
if len(values)%2 != 0 {
|
||||
return nil, fmt.Errorf("expected even number of arguments, got %d", len(values))
|
||||
@@ -580,3 +695,132 @@ func dict(values ...interface{}) (map[string]interface{}, error) {
|
||||
}
|
||||
return dict, nil
|
||||
}
|
||||
|
||||
func isInteger(arg interface{}) bool {
|
||||
// is integer determines if a value may be represented by an integer
|
||||
switch val := arg.(type) {
|
||||
case int8, int16, int32, int, int64, uint8, uint16, uint32, uint, uint64:
|
||||
return true
|
||||
case *int8, *int16, *int32, *int, *int64, *uint8, *uint16, *uint32, *uint, *uint64:
|
||||
v := reflect.ValueOf(arg)
|
||||
return !v.IsNil()
|
||||
case float64:
|
||||
return math.Round(val) == val
|
||||
case *float64:
|
||||
return val != nil && math.Round(*val) == *val
|
||||
case float32:
|
||||
return math.Round(float64(val)) == float64(val)
|
||||
case *float32:
|
||||
return val != nil && math.Round(float64(*val)) == float64(*val)
|
||||
case string:
|
||||
_, err := strconv.ParseInt(val, 10, 64)
|
||||
return err == nil
|
||||
case *string:
|
||||
if val == nil {
|
||||
return false
|
||||
}
|
||||
_, err := strconv.ParseInt(*val, 10, 64)
|
||||
return err == nil
|
||||
default:
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
func resolvedDocCollectionFormat(cf string, child *GenItems) string {
|
||||
if child == nil {
|
||||
return cf
|
||||
}
|
||||
ccf := cf
|
||||
if ccf == "" {
|
||||
ccf = "csv"
|
||||
}
|
||||
rcf := resolvedDocCollectionFormat(child.CollectionFormat, child.Child)
|
||||
if rcf == "" {
|
||||
return ccf
|
||||
}
|
||||
return ccf + "|" + rcf
|
||||
}
|
||||
|
||||
func resolvedDocType(tn, ft string, child *GenItems) string {
|
||||
if tn == "array" {
|
||||
if child == nil {
|
||||
return "[]any"
|
||||
}
|
||||
return "[]" + resolvedDocType(child.SwaggerType, child.SwaggerFormat, child.Child)
|
||||
}
|
||||
|
||||
if ft != "" {
|
||||
if doc, ok := docFormat[ft]; ok {
|
||||
return doc
|
||||
}
|
||||
return fmt.Sprintf("%s (formatted %s)", ft, tn)
|
||||
}
|
||||
|
||||
return tn
|
||||
}
|
||||
|
||||
func resolvedDocSchemaType(tn, ft string, child *GenSchema) string {
|
||||
if tn == "array" {
|
||||
if child == nil {
|
||||
return "[]any"
|
||||
}
|
||||
return "[]" + resolvedDocSchemaType(child.SwaggerType, child.SwaggerFormat, child.Items)
|
||||
}
|
||||
|
||||
if tn == "object" {
|
||||
if child == nil || child.ElemType == nil {
|
||||
return "map of any"
|
||||
}
|
||||
if child.IsMap {
|
||||
return "map of " + resolvedDocElemType(child.SwaggerType, child.SwaggerFormat, &child.resolvedType)
|
||||
}
|
||||
|
||||
return child.GoType
|
||||
}
|
||||
|
||||
if ft != "" {
|
||||
if doc, ok := docFormat[ft]; ok {
|
||||
return doc
|
||||
}
|
||||
return fmt.Sprintf("%s (formatted %s)", ft, tn)
|
||||
}
|
||||
|
||||
return tn
|
||||
}
|
||||
|
||||
func resolvedDocElemType(tn, ft string, schema *resolvedType) string {
|
||||
if schema == nil {
|
||||
return ""
|
||||
}
|
||||
if schema.IsMap {
|
||||
return "map of " + resolvedDocElemType(schema.ElemType.SwaggerType, schema.ElemType.SwaggerFormat, schema.ElemType)
|
||||
}
|
||||
|
||||
if schema.IsArray {
|
||||
return "[]" + resolvedDocElemType(schema.ElemType.SwaggerType, schema.ElemType.SwaggerFormat, schema.ElemType)
|
||||
}
|
||||
|
||||
if ft != "" {
|
||||
if doc, ok := docFormat[ft]; ok {
|
||||
return doc
|
||||
}
|
||||
return fmt.Sprintf("%s (formatted %s)", ft, tn)
|
||||
}
|
||||
|
||||
return tn
|
||||
}
|
||||
|
||||
func httpStatus(code int) string {
|
||||
if name, ok := runtime.Statuses[code]; ok {
|
||||
return name
|
||||
}
|
||||
// non-standard codes deserve some name
|
||||
return fmt.Sprintf("Status %d", code)
|
||||
}
|
||||
|
||||
func gt0(in *int64) bool {
|
||||
// gt0 returns true if the *int64 points to a value > 0
|
||||
// NOTE: plain {{ gt .MinProperties 0 }} just refuses to work normally
|
||||
// with a pointer
|
||||
return in != nil && *in > 0
|
||||
}
|
||||
+351
-70
@@ -17,8 +17,8 @@ package generator
|
||||
import (
|
||||
"fmt"
|
||||
"log"
|
||||
"path"
|
||||
"path/filepath"
|
||||
"reflect"
|
||||
"strings"
|
||||
|
||||
"github.com/go-openapi/loads"
|
||||
@@ -69,10 +69,14 @@ func initTypes() {
|
||||
}
|
||||
}
|
||||
|
||||
func simpleResolvedType(tn, fmt string, items *spec.Items) (result resolvedType) {
|
||||
func simpleResolvedType(tn, fmt string, items *spec.Items, v *spec.CommonValidations) (result resolvedType) {
|
||||
result.SwaggerType = tn
|
||||
result.SwaggerFormat = fmt
|
||||
|
||||
defer func() {
|
||||
guardValidations(result.SwaggerType, v)
|
||||
}()
|
||||
|
||||
if tn == file {
|
||||
// special case of swagger type "file", rendered as io.ReadCloser interface
|
||||
result.IsPrimitive = true
|
||||
@@ -82,7 +86,11 @@ func simpleResolvedType(tn, fmt string, items *spec.Items) (result resolvedType)
|
||||
}
|
||||
|
||||
if fmt != "" {
|
||||
fmtn := strings.Replace(fmt, "-", "", -1)
|
||||
defer func() {
|
||||
guardFormatConflicts(result.SwaggerFormat, v)
|
||||
}()
|
||||
|
||||
fmtn := strings.ReplaceAll(fmt, "-", "")
|
||||
if fmm, ok := formatMapping[tn]; ok {
|
||||
if tpe, ok := fmm[fmtn]; ok {
|
||||
result.GoType = tpe
|
||||
@@ -114,7 +122,7 @@ func simpleResolvedType(tn, fmt string, items *spec.Items) (result resolvedType)
|
||||
result.GoType = "[]" + iface
|
||||
return
|
||||
}
|
||||
res := simpleResolvedType(items.Type, items.Format, items.Items)
|
||||
res := simpleResolvedType(items.Type, items.Format, items.Items, &items.CommonValidations)
|
||||
result.GoType = "[]" + res.GoType
|
||||
return
|
||||
}
|
||||
@@ -123,22 +131,18 @@ func simpleResolvedType(tn, fmt string, items *spec.Items) (result resolvedType)
|
||||
return
|
||||
}
|
||||
|
||||
func typeForHeader(header spec.Header) resolvedType {
|
||||
return simpleResolvedType(header.Type, header.Format, header.Items)
|
||||
}
|
||||
|
||||
func newTypeResolver(pkg string, doc *loads.Document) *typeResolver {
|
||||
func newTypeResolver(pkg, fullPkg string, doc *loads.Document) *typeResolver {
|
||||
resolver := typeResolver{ModelsPackage: pkg, Doc: doc}
|
||||
resolver.KnownDefs = make(map[string]struct{}, len(doc.Spec().Definitions))
|
||||
for k, sch := range doc.Spec().Definitions {
|
||||
tpe, _, _ := knownDefGoType(k, sch, nil)
|
||||
tpe, _, _ := resolver.knownDefGoType(k, sch, nil)
|
||||
resolver.KnownDefs[tpe] = struct{}{}
|
||||
}
|
||||
return &resolver
|
||||
}
|
||||
|
||||
// knownDefGoType returns go type, package and package alias for definition
|
||||
func knownDefGoType(def string, schema spec.Schema, clear func(string) string) (string, string, string) {
|
||||
func (t typeResolver) knownDefGoType(def string, schema spec.Schema, clear func(string) string) (string, string, string) {
|
||||
debugLog("known def type: %q", def)
|
||||
ext := schema.Extensions
|
||||
nm, hasGoName := ext.GetString(xGoName)
|
||||
@@ -147,8 +151,7 @@ func knownDefGoType(def string, schema spec.Schema, clear func(string) string) (
|
||||
debugLog("known def type %s named from %s as %q", def, xGoName, nm)
|
||||
def = nm
|
||||
}
|
||||
extType, isExternalType := hasExternalType(ext)
|
||||
|
||||
extType, isExternalType := t.resolveExternalType(ext)
|
||||
if !isExternalType || extType.Embedded {
|
||||
if clear == nil {
|
||||
debugLog("known def type no clear: %q", def)
|
||||
@@ -159,7 +162,11 @@ func knownDefGoType(def string, schema spec.Schema, clear func(string) string) (
|
||||
}
|
||||
|
||||
// external type definition trumps regular type resolution
|
||||
log.Printf("type %s imported as external type %s.%s", def, extType.Import.Package, extType.Type)
|
||||
if extType.Import.Alias == "" {
|
||||
debugLog("type %s imported as external type %s, assumed in current package", def, extType.Type)
|
||||
return extType.Type, extType.Import.Package, extType.Import.Alias
|
||||
}
|
||||
debugLog("type %s imported as external type from %s as %s.%s", def, extType.Import.Package, extType.Import.Alias, extType.Type)
|
||||
return extType.Import.Alias + "." + extType.Type, extType.Import.Package, extType.Import.Alias
|
||||
}
|
||||
|
||||
@@ -179,8 +186,9 @@ type externalTypeDefinition struct {
|
||||
Alias string
|
||||
}
|
||||
Hints struct {
|
||||
Kind string
|
||||
Nullable bool
|
||||
Kind string
|
||||
Nullable *bool
|
||||
NoValidation *bool
|
||||
}
|
||||
Embedded bool
|
||||
}
|
||||
@@ -190,23 +198,57 @@ func hasExternalType(ext spec.Extensions) (*externalTypeDefinition, bool) {
|
||||
if !ok {
|
||||
return nil, false
|
||||
}
|
||||
|
||||
var extType externalTypeDefinition
|
||||
err := mapstructure.Decode(v, &extType)
|
||||
if err != nil {
|
||||
log.Printf("warning: x-go-type extension could not be decoded (%v). Skipped", v)
|
||||
return nil, false
|
||||
}
|
||||
if extType.Import.Package != "" && extType.Import.Alias == "" {
|
||||
// NOTE(fred): possible name conflict here (TODO(fred): deconflict this default alias)
|
||||
extType.Import.Alias = path.Base(extType.Import.Package)
|
||||
}
|
||||
debugLogAsJSON("known def external %s type", xGoType, extType)
|
||||
|
||||
return &extType, true
|
||||
}
|
||||
|
||||
func (t typeResolver) resolveExternalType(ext spec.Extensions) (*externalTypeDefinition, bool) {
|
||||
extType, hasExt := hasExternalType(ext)
|
||||
if !hasExt {
|
||||
return nil, false
|
||||
}
|
||||
|
||||
// NOTE:
|
||||
// * basic deconfliction of the default alias
|
||||
// * if no package is specified, defaults to models (as provided from CLI or defaut generation location for models)
|
||||
toAlias := func(pkg string) string {
|
||||
mangled := GoLangOpts().ManglePackageName(pkg, "")
|
||||
return deconflictPkg(mangled, func(in string) string {
|
||||
return in + "ext"
|
||||
})
|
||||
}
|
||||
|
||||
switch {
|
||||
case extType.Import.Package != "" && extType.Import.Alias == "":
|
||||
extType.Import.Alias = toAlias(extType.Import.Package)
|
||||
case extType.Import.Package == "" && extType.Import.Alias != "":
|
||||
extType.Import.Package = t.ModelsFullPkg
|
||||
case extType.Import.Package == "" && extType.Import.Alias == "":
|
||||
// in this case, the external type is assumed to be present in the current package.
|
||||
// For completion, whenever this type is used in anonymous types declared by operations,
|
||||
// we assume this is the package where models are expected to be found.
|
||||
extType.Import.Package = t.ModelsFullPkg
|
||||
if extType.Import.Package != "" {
|
||||
extType.Import.Alias = toAlias(extType.Import.Package)
|
||||
}
|
||||
}
|
||||
|
||||
debugLogAsJSON("known def external %s type", xGoType, extType)
|
||||
|
||||
return extType, true
|
||||
}
|
||||
|
||||
type typeResolver struct {
|
||||
Doc *loads.Document
|
||||
ModelsPackage string
|
||||
ModelsPackage string // package alias (e.g. "models")
|
||||
ModelsFullPkg string // fully qualified package (e.g. "github.com/example/models")
|
||||
ModelName string
|
||||
KnownDefs map[string]struct{}
|
||||
// unexported fields
|
||||
@@ -216,7 +258,7 @@ type typeResolver struct {
|
||||
|
||||
// NewWithModelName clones a type resolver and specifies a new model name
|
||||
func (t *typeResolver) NewWithModelName(name string) *typeResolver {
|
||||
tt := newTypeResolver(t.ModelsPackage, t.Doc)
|
||||
tt := newTypeResolver(t.ModelsPackage, t.ModelsFullPkg, t.Doc)
|
||||
tt.ModelName = name
|
||||
|
||||
// propagates kept definitions
|
||||
@@ -236,24 +278,12 @@ func (t *typeResolver) withKeepDefinitionsPackage(definitionsPackage string) *ty
|
||||
return t
|
||||
}
|
||||
|
||||
// IsNullable hints the generator as to render the type with a pointer or not.
|
||||
//
|
||||
// A schema is deemed nullable (i.e. rendered by a pointer) when:
|
||||
// - a custom extension says it has to be so
|
||||
// - it is an object with properties
|
||||
// - it is a composed object (allOf)
|
||||
//
|
||||
// The interpretation of Required as a mean to make a type nullable is carried on elsewhere.
|
||||
func (t *typeResolver) IsNullable(schema *spec.Schema) bool {
|
||||
nullable := t.isNullable(schema)
|
||||
return nullable || len(schema.AllOf) > 0
|
||||
}
|
||||
|
||||
func (t *typeResolver) resolveSchemaRef(schema *spec.Schema, isRequired bool) (returns bool, result resolvedType, err error) {
|
||||
if schema.Ref.String() == "" {
|
||||
return
|
||||
}
|
||||
debugLog("resolving ref (anon: %t, req: %t) %s", false, isRequired, schema.Ref.String())
|
||||
|
||||
returns = true
|
||||
var ref *spec.Schema
|
||||
var er error
|
||||
@@ -264,6 +294,13 @@ func (t *typeResolver) resolveSchemaRef(schema *spec.Schema, isRequired bool) (r
|
||||
err = er
|
||||
return
|
||||
}
|
||||
|
||||
extType, isExternalType := t.resolveExternalType(schema.Extensions)
|
||||
if isExternalType {
|
||||
// deal with validations for an aliased external type
|
||||
result.SkipExternalValidation = swag.BoolValue(extType.Hints.NoValidation)
|
||||
}
|
||||
|
||||
res, er := t.ResolveSchema(ref, false, isRequired)
|
||||
if er != nil {
|
||||
err = er
|
||||
@@ -272,7 +309,7 @@ func (t *typeResolver) resolveSchemaRef(schema *spec.Schema, isRequired bool) (r
|
||||
result = res
|
||||
|
||||
tn := filepath.Base(schema.Ref.GetURL().Fragment)
|
||||
tpe, pkg, alias := knownDefGoType(tn, *ref, t.goTypeName)
|
||||
tpe, pkg, alias := t.knownDefGoType(tn, *ref, t.goTypeName)
|
||||
debugLog("type name %s, package %s, alias %s", tpe, pkg, alias)
|
||||
if tpe != "" {
|
||||
result.GoType = tpe
|
||||
@@ -281,7 +318,7 @@ func (t *typeResolver) resolveSchemaRef(schema *spec.Schema, isRequired bool) (r
|
||||
}
|
||||
result.HasDiscriminator = res.HasDiscriminator
|
||||
result.IsBaseType = result.HasDiscriminator
|
||||
result.IsNullable = t.IsNullable(ref)
|
||||
result.IsNullable = result.IsNullable || t.isNullable(ref) // this has to be overriden for slices and maps
|
||||
result.IsEnumCI = false
|
||||
return
|
||||
}
|
||||
@@ -304,7 +341,7 @@ func (t *typeResolver) resolveFormat(schema *spec.Schema, isAnonymous bool, isRe
|
||||
}
|
||||
|
||||
debugLog("resolving format (anon: %t, req: %t)", isAnonymous, isRequired)
|
||||
schFmt := strings.Replace(schema.Format, "-", "", -1)
|
||||
schFmt := strings.ReplaceAll(schema.Format, "-", "")
|
||||
if fmm, ok := formatMapping[result.SwaggerType]; ok {
|
||||
if tpe, ok := fmm[schFmt]; ok {
|
||||
returns = true
|
||||
@@ -334,13 +371,33 @@ func (t *typeResolver) resolveFormat(schema *spec.Schema, isAnonymous bool, isRe
|
||||
case number, integer:
|
||||
result.IsNullable = nullableNumber(schema, isRequired)
|
||||
default:
|
||||
result.IsNullable = t.IsNullable(schema)
|
||||
result.IsNullable = t.isNullable(schema)
|
||||
}
|
||||
}
|
||||
|
||||
guardFormatConflicts(schema.Format, schema)
|
||||
return
|
||||
}
|
||||
|
||||
// isNullable hints the generator as to render the type with a pointer or not.
|
||||
//
|
||||
// A schema is deemed nullable (i.e. rendered by a pointer) when:
|
||||
// - a custom extension says it has to be so
|
||||
// - it is an object with properties
|
||||
// - it is a composed object (allOf)
|
||||
//
|
||||
// The interpretation of Required as a mean to make a type nullable is carried out elsewhere.
|
||||
func (t *typeResolver) isNullable(schema *spec.Schema) bool {
|
||||
|
||||
if nullable, ok := t.isNullableOverride(schema); ok {
|
||||
return nullable
|
||||
}
|
||||
|
||||
return len(schema.Properties) > 0 || len(schema.AllOf) > 0
|
||||
}
|
||||
|
||||
// isNullableOverride determines a nullable flag forced by an extension
|
||||
func (t *typeResolver) isNullableOverride(schema *spec.Schema) (bool, bool) {
|
||||
check := func(extension string) (bool, bool) {
|
||||
v, found := schema.Extensions[extension]
|
||||
nullable, cast := v.(bool)
|
||||
@@ -348,12 +405,14 @@ func (t *typeResolver) isNullable(schema *spec.Schema) bool {
|
||||
}
|
||||
|
||||
if nullable, ok := check(xIsNullable); ok {
|
||||
return nullable
|
||||
return nullable, ok
|
||||
}
|
||||
|
||||
if nullable, ok := check(xNullable); ok {
|
||||
return nullable
|
||||
return nullable, ok
|
||||
}
|
||||
return len(schema.Properties) > 0
|
||||
|
||||
return false, false
|
||||
}
|
||||
|
||||
func (t *typeResolver) firstType(schema *spec.Schema) string {
|
||||
@@ -402,9 +461,30 @@ func (t *typeResolver) resolveArray(schema *spec.Schema, isAnonymous, isRequired
|
||||
err = er
|
||||
return
|
||||
}
|
||||
// override the general nullability rule from ResolveSchema():
|
||||
// only complex items are nullable (when not discriminated, not forced by x-nullable)
|
||||
rt.IsNullable = t.IsNullable(schema.Items.Schema) && !rt.HasDiscriminator
|
||||
|
||||
// Override the general nullability rule from ResolveSchema() in array elements:
|
||||
// - only complex items are nullable (when not discriminated, not forced by x-nullable)
|
||||
// - arrays of allOf have non nullable elements when not forced by x-nullable
|
||||
elem := schema.Items.Schema
|
||||
if elem.Ref.String() != "" {
|
||||
// drill into $ref to figure out whether we want the element type to nullable or not
|
||||
resolved, erf := spec.ResolveRef(t.Doc.Spec(), &elem.Ref)
|
||||
if erf != nil {
|
||||
debugLog("error resolving ref %s: %v", schema.Ref.String(), erf)
|
||||
}
|
||||
elem = resolved
|
||||
}
|
||||
|
||||
debugLogAsJSON("resolved item for %s", rt.GoType, elem)
|
||||
if nullable, ok := t.isNullableOverride(elem); ok {
|
||||
debugLog("found nullable override in element %s: %t", rt.GoType, nullable)
|
||||
rt.IsNullable = nullable
|
||||
} else {
|
||||
// this differs from isNullable for elements with AllOf
|
||||
debugLog("no nullable override in element %s: Properties: %t, HasDiscriminator: %t", rt.GoType, len(elem.Properties) > 0, rt.HasDiscriminator)
|
||||
rt.IsNullable = len(elem.Properties) > 0 && !rt.HasDiscriminator
|
||||
}
|
||||
|
||||
result.GoType = "[]" + rt.GoType
|
||||
if rt.IsNullable && !strings.HasPrefix(rt.GoType, "*") {
|
||||
result.GoType = "[]*" + rt.GoType
|
||||
@@ -448,7 +528,7 @@ func (t *typeResolver) resolveObject(schema *spec.Schema, isAnonymous bool) (res
|
||||
result.IsBaseType = schema.Discriminator != ""
|
||||
if !isAnonymous {
|
||||
result.SwaggerType = object
|
||||
tpe, pkg, alias := knownDefGoType(t.ModelName, *schema, t.goTypeName)
|
||||
tpe, pkg, alias := t.knownDefGoType(t.ModelName, *schema, t.goTypeName)
|
||||
result.GoType = tpe
|
||||
result.Pkg = pkg
|
||||
result.PkgAlias = alias
|
||||
@@ -457,12 +537,18 @@ func (t *typeResolver) resolveObject(schema *spec.Schema, isAnonymous bool) (res
|
||||
result.GoType = t.goTypeName(t.ModelName)
|
||||
result.IsComplexObject = true
|
||||
var isNullable bool
|
||||
for _, p := range schema.AllOf {
|
||||
if t.IsNullable(&p) {
|
||||
for _, sch := range schema.AllOf {
|
||||
p := sch
|
||||
if t.isNullable(&p) {
|
||||
isNullable = true
|
||||
}
|
||||
}
|
||||
result.IsNullable = isNullable
|
||||
if override, ok := t.isNullableOverride(schema); ok {
|
||||
// prioritize x-nullable extensions
|
||||
result.IsNullable = override
|
||||
} else {
|
||||
result.IsNullable = isNullable
|
||||
}
|
||||
result.SwaggerType = object
|
||||
return
|
||||
}
|
||||
@@ -471,7 +557,7 @@ func (t *typeResolver) resolveObject(schema *spec.Schema, isAnonymous bool) (res
|
||||
// resolved type, this should also flag the object as anonymous,
|
||||
// when a ref is found, the anonymous flag will be reset
|
||||
if len(schema.Properties) > 0 {
|
||||
result.IsNullable = t.IsNullable(schema)
|
||||
result.IsNullable = t.isNullable(schema)
|
||||
result.IsComplexObject = true
|
||||
// no return here, still need to check for additional properties
|
||||
}
|
||||
@@ -489,6 +575,12 @@ func (t *typeResolver) resolveObject(schema *spec.Schema, isAnonymous bool) (res
|
||||
|
||||
result.SwaggerType = object
|
||||
|
||||
if et.IsExternal {
|
||||
// external AdditionalProperties are a special case because we look ahead into schemas
|
||||
extType, _, _ := t.knownDefGoType(t.ModelName, *sch, t.goTypeName)
|
||||
et.GoType = extType
|
||||
}
|
||||
|
||||
// only complex map elements are nullable (when not forced by x-nullable)
|
||||
// TODO: figure out if required to check when not discriminated like arrays?
|
||||
et.IsNullable = t.isNullable(schema.AdditionalProperties.Schema)
|
||||
@@ -544,11 +636,16 @@ func (t *typeResolver) resolveObject(schema *spec.Schema, isAnonymous bool) (res
|
||||
}
|
||||
|
||||
// an object without property and without AdditionalProperties schema is rendered as interface{}
|
||||
result.GoType = iface
|
||||
result.IsMap = true
|
||||
result.SwaggerType = object
|
||||
result.IsNullable = false
|
||||
result.IsInterface = len(schema.Properties) == 0
|
||||
// an object without properties but with MinProperties or MaxProperties is rendered as map[string]interface{}
|
||||
result.IsInterface = len(schema.Properties) == 0 && !schema.Validations().HasObjectValidations()
|
||||
if result.IsInterface {
|
||||
result.GoType = iface
|
||||
} else {
|
||||
result.GoType = "map[string]interface{}"
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
@@ -656,21 +753,38 @@ func hasEnumCI(ve spec.Extensions) bool {
|
||||
return ok && isEnumCI
|
||||
}
|
||||
|
||||
func (t *typeResolver) shortCircuitResolveExternal(tpe, pkg, alias string, extType *externalTypeDefinition, schema *spec.Schema) resolvedType {
|
||||
func (t *typeResolver) shortCircuitResolveExternal(tpe, pkg, alias string, extType *externalTypeDefinition, schema *spec.Schema, isRequired bool) resolvedType {
|
||||
// short circuit type resolution for external types
|
||||
debugLogAsJSON("shortCircuitResolveExternal", extType)
|
||||
|
||||
var result resolvedType
|
||||
result.Extensions = schema.Extensions
|
||||
result.GoType = tpe
|
||||
result.Pkg = pkg
|
||||
result.PkgAlias = alias
|
||||
result.IsInterface = false
|
||||
// by default consider that we have a type with validations. Use hint "interface" or "noValidation" to disable validations
|
||||
result.SkipExternalValidation = swag.BoolValue(extType.Hints.NoValidation)
|
||||
result.IsNullable = isRequired
|
||||
|
||||
result.setKind(extType.Hints.Kind)
|
||||
result.IsNullable = t.IsNullable(schema)
|
||||
if result.IsInterface || result.IsStream {
|
||||
result.IsNullable = false
|
||||
}
|
||||
if extType.Hints.Nullable != nil {
|
||||
result.IsNullable = swag.BoolValue(extType.Hints.Nullable)
|
||||
}
|
||||
|
||||
if nullable, ok := t.isNullableOverride(schema); ok {
|
||||
result.IsNullable = nullable // x-nullable directive rules them all
|
||||
}
|
||||
|
||||
// other extensions
|
||||
if result.IsArray {
|
||||
result.IsEmptyOmitted = false
|
||||
tpe = "array"
|
||||
}
|
||||
|
||||
result.setExtensions(schema, tpe)
|
||||
return result
|
||||
}
|
||||
@@ -687,32 +801,73 @@ func (t *typeResolver) ResolveSchema(schema *spec.Schema, isAnonymous, isRequire
|
||||
return
|
||||
}
|
||||
|
||||
extType, isExternalType := hasExternalType(schema.Extensions)
|
||||
extType, isExternalType := t.resolveExternalType(schema.Extensions)
|
||||
if isExternalType {
|
||||
tpe, pkg, alias := knownDefGoType(t.ModelName, *schema, t.goTypeName)
|
||||
debugLog("found type declared as external, imported from %s as %s. Has type hints? %t, rendered has embedded? %t",
|
||||
pkg, tpe, extType.Hints.Kind != "", extType.Embedded)
|
||||
tpe, pkg, alias := t.knownDefGoType(t.ModelName, *schema, t.goTypeName)
|
||||
debugLog("found type %s declared as external, imported from %s as %s. Has type hints? %t, rendered has embedded? %t",
|
||||
t.ModelName, pkg, tpe, extType.Hints.Kind != "", extType.Embedded)
|
||||
|
||||
if extType.Hints.Kind != "" && !extType.Embedded {
|
||||
// use hint to qualify type
|
||||
debugLog("short circuits external type resolution with hint for %s", tpe)
|
||||
result = t.shortCircuitResolveExternal(tpe, pkg, alias, extType, schema)
|
||||
result = t.shortCircuitResolveExternal(tpe, pkg, alias, extType, schema, isRequired)
|
||||
result.IsExternal = isAnonymous // mark anonymous external types only, not definitions
|
||||
return
|
||||
}
|
||||
|
||||
// use spec to qualify type
|
||||
debugLog("marking type %s as external embedded: %t", tpe, extType.Embedded)
|
||||
// mark this type as an embedded external definition if requested
|
||||
defer func() {
|
||||
defer func() { // enforce bubbling up decisions taken about being an external type
|
||||
// mark this type as an embedded external definition if requested
|
||||
result.IsEmbedded = extType.Embedded
|
||||
result.IsExternal = isAnonymous // for non-embedded, mark anonymous external types only, not definitions
|
||||
|
||||
result.IsAnonymous = false
|
||||
result.IsAliased = true
|
||||
result.IsNullable = isRequired
|
||||
if extType.Hints.Nullable != nil {
|
||||
result.IsNullable = swag.BoolValue(extType.Hints.Nullable)
|
||||
}
|
||||
|
||||
result.IsMap = false
|
||||
result.AliasedType = result.GoType
|
||||
result.IsInterface = false
|
||||
|
||||
if result.IsEmbedded {
|
||||
result.ElemType = &resolvedType{
|
||||
GoType: extType.Import.Alias + "." + extType.Type,
|
||||
Pkg: extType.Import.Package,
|
||||
PkgAlias: extType.Import.Alias,
|
||||
IsNullable: extType.Hints.Nullable,
|
||||
IsExternal: isAnonymous, // mark anonymous external types only, not definitions
|
||||
IsInterface: false,
|
||||
Pkg: extType.Import.Package,
|
||||
PkgAlias: extType.Import.Alias,
|
||||
SkipExternalValidation: swag.BoolValue(extType.Hints.NoValidation),
|
||||
}
|
||||
result.setKind(extType.Hints.Kind)
|
||||
if extType.Import.Alias != "" {
|
||||
result.ElemType.GoType = extType.Import.Alias + "." + extType.Type
|
||||
} else {
|
||||
result.ElemType.GoType = extType.Type
|
||||
}
|
||||
result.ElemType.setKind(extType.Hints.Kind)
|
||||
if result.IsInterface || result.IsStream {
|
||||
result.ElemType.IsNullable = false
|
||||
}
|
||||
if extType.Hints.Nullable != nil {
|
||||
result.ElemType.IsNullable = swag.BoolValue(extType.Hints.Nullable)
|
||||
}
|
||||
// embedded external: by default consider validation is skipped for the external type
|
||||
//
|
||||
// NOTE: at this moment the template generates a type assertion, so this setting does not really matter
|
||||
// for embedded types.
|
||||
if extType.Hints.NoValidation != nil {
|
||||
result.ElemType.SkipExternalValidation = swag.BoolValue(extType.Hints.NoValidation)
|
||||
} else {
|
||||
result.ElemType.SkipExternalValidation = true
|
||||
}
|
||||
} else {
|
||||
// non-embedded external type: by default consider that validation is enabled (SkipExternalValidation: false)
|
||||
result.SkipExternalValidation = swag.BoolValue(extType.Hints.NoValidation)
|
||||
}
|
||||
if nullable, ok := t.isNullableOverride(schema); ok {
|
||||
result.IsNullable = nullable
|
||||
}
|
||||
}()
|
||||
}
|
||||
@@ -720,15 +875,16 @@ func (t *typeResolver) ResolveSchema(schema *spec.Schema, isAnonymous, isRequire
|
||||
tpe := t.firstType(schema)
|
||||
var returns bool
|
||||
|
||||
guardValidations(tpe, schema, schema.Type...)
|
||||
|
||||
returns, result, err = t.resolveSchemaRef(schema, isRequired)
|
||||
|
||||
if returns {
|
||||
if !isAnonymous {
|
||||
result.IsMap = false
|
||||
result.IsComplexObject = true
|
||||
debugLog("not anonymous ref")
|
||||
}
|
||||
debugLog("anonymous after ref")
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
@@ -793,6 +949,18 @@ func (t *typeResolver) ResolveSchema(schema *spec.Schema, isAnonymous, isRequire
|
||||
result.HasDiscriminator = schema.Discriminator != ""
|
||||
|
||||
case "null":
|
||||
if schema.Validations().HasObjectValidations() {
|
||||
// no explicit object type, but inferred from object validations:
|
||||
// this makes the type a map[string]interface{} instead of interface{}
|
||||
result, err = t.resolveObject(schema, isAnonymous)
|
||||
if err != nil {
|
||||
result = resolvedType{}
|
||||
break
|
||||
}
|
||||
result.HasDiscriminator = schema.Discriminator != ""
|
||||
break
|
||||
}
|
||||
|
||||
result.GoType = iface
|
||||
result.SwaggerType = object
|
||||
result.IsNullable = false
|
||||
@@ -801,9 +969,89 @@ func (t *typeResolver) ResolveSchema(schema *spec.Schema, isAnonymous, isRequire
|
||||
default:
|
||||
err = fmt.Errorf("unresolvable: %v (format %q)", schema.Type, schema.Format)
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
func warnSkipValidation(types interface{}) func(string, interface{}) {
|
||||
return func(validation string, value interface{}) {
|
||||
value = reflect.Indirect(reflect.ValueOf(value)).Interface()
|
||||
log.Printf("warning: validation %s (value: %v) not compatible with type %v. Skipped", validation, value, types)
|
||||
}
|
||||
}
|
||||
|
||||
// guardValidations removes (with a warning) validations that don't fit with the schema type.
|
||||
//
|
||||
// Notice that the "enum" validation is allowed on any type but file.
|
||||
func guardValidations(tpe string, schema interface {
|
||||
Validations() spec.SchemaValidations
|
||||
SetValidations(spec.SchemaValidations)
|
||||
}, types ...string) {
|
||||
|
||||
v := schema.Validations()
|
||||
if len(types) == 0 {
|
||||
types = []string{tpe}
|
||||
}
|
||||
defer func() {
|
||||
schema.SetValidations(v)
|
||||
}()
|
||||
|
||||
if tpe != array {
|
||||
v.ClearArrayValidations(warnSkipValidation(types))
|
||||
}
|
||||
|
||||
if tpe != str && tpe != file {
|
||||
v.ClearStringValidations(warnSkipValidation(types))
|
||||
}
|
||||
|
||||
if tpe != object {
|
||||
v.ClearObjectValidations(warnSkipValidation(types))
|
||||
}
|
||||
|
||||
if tpe != number && tpe != integer {
|
||||
v.ClearNumberValidations(warnSkipValidation(types))
|
||||
}
|
||||
|
||||
if tpe == file {
|
||||
// keep MinLength/MaxLength on file
|
||||
if v.Pattern != "" {
|
||||
warnSkipValidation(types)("pattern", v.Pattern)
|
||||
v.Pattern = ""
|
||||
}
|
||||
if v.HasEnum() {
|
||||
warnSkipValidation(types)("enum", v.Enum)
|
||||
v.Enum = nil
|
||||
}
|
||||
}
|
||||
|
||||
// other cases: mapped as interface{}: no validations allowed but Enum
|
||||
}
|
||||
|
||||
// guardFormatConflicts handles all conflicting properties
|
||||
// (for schema model or simple schema) when a format is set.
|
||||
//
|
||||
// At this moment, validation guards already handle all known conflicts, but for the
|
||||
// special case of binary (i.e. io.Reader).
|
||||
func guardFormatConflicts(format string, schema interface {
|
||||
Validations() spec.SchemaValidations
|
||||
SetValidations(spec.SchemaValidations)
|
||||
}) {
|
||||
v := schema.Validations()
|
||||
msg := fmt.Sprintf("for format %q", format)
|
||||
|
||||
// for this format, no additional validations are supported
|
||||
if format == "binary" {
|
||||
// no validations supported on binary fields at this moment (io.Reader)
|
||||
v.ClearStringValidations(warnSkipValidation(msg))
|
||||
if v.HasEnum() {
|
||||
warnSkipValidation(msg)
|
||||
v.Enum = nil
|
||||
}
|
||||
schema.SetValidations(v)
|
||||
}
|
||||
// more cases should be inserted here if they arise
|
||||
}
|
||||
|
||||
// resolvedType is a swagger type that has been resolved and analyzed for usage
|
||||
// in a template
|
||||
type resolvedType struct {
|
||||
@@ -820,6 +1068,7 @@ type resolvedType struct {
|
||||
IsJSONString bool
|
||||
IsEnumCI bool
|
||||
IsBase64 bool
|
||||
IsExternal bool
|
||||
|
||||
// A tuple gets rendered as an anonymous struct with P{index} as property name
|
||||
IsTuple bool
|
||||
@@ -855,9 +1104,12 @@ type resolvedType struct {
|
||||
// is generated in models that embeds the external type, with the Validate
|
||||
// method.
|
||||
IsEmbedded bool
|
||||
|
||||
SkipExternalValidation bool
|
||||
}
|
||||
|
||||
func (rt *resolvedType) Zero() string {
|
||||
// Zero returns an initializer for the type
|
||||
func (rt resolvedType) Zero() string {
|
||||
// if type is aliased, provide zero from the aliased type
|
||||
if rt.IsAliased {
|
||||
if zr, ok := zeroes[rt.AliasedType]; ok {
|
||||
@@ -889,10 +1141,39 @@ func (rt *resolvedType) Zero() string {
|
||||
return ""
|
||||
}
|
||||
|
||||
// ToString returns a string conversion for a type akin to a string
|
||||
func (rt resolvedType) ToString(value string) string {
|
||||
if !rt.IsPrimitive || rt.SwaggerType != "string" || rt.IsStream {
|
||||
return ""
|
||||
}
|
||||
if rt.IsCustomFormatter {
|
||||
if rt.IsAliased {
|
||||
return fmt.Sprintf("%s(%s).String()", rt.AliasedType, value)
|
||||
}
|
||||
return fmt.Sprintf("%s.String()", value)
|
||||
}
|
||||
var deref string
|
||||
if rt.IsNullable {
|
||||
deref = "*"
|
||||
}
|
||||
if rt.GoType == "string" || rt.GoType == "*string" {
|
||||
return fmt.Sprintf("%s%s", deref, value)
|
||||
}
|
||||
|
||||
return fmt.Sprintf("string(%s%s)", deref, value)
|
||||
}
|
||||
|
||||
func (rt *resolvedType) setExtensions(schema *spec.Schema, origType string) {
|
||||
rt.IsEnumCI = hasEnumCI(schema.Extensions)
|
||||
rt.setIsEmptyOmitted(schema, origType)
|
||||
rt.setIsJSONString(schema, origType)
|
||||
|
||||
if customTag, found := schema.Extensions[xGoCustomTag]; found {
|
||||
if rt.Extensions == nil {
|
||||
rt.Extensions = make(spec.Extensions)
|
||||
}
|
||||
rt.Extensions[xGoCustomTag] = customTag
|
||||
}
|
||||
}
|
||||
|
||||
func (rt *resolvedType) setIsEmptyOmitted(schema *spec.Schema, tpe string) {
|
||||
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
# scan
|
||||
|
||||
Pre go1.11 version of the go source parser, without support for go modules.
|
||||
+3
-3
@@ -119,7 +119,7 @@ func (pc *programClassifier) Classify(prog *loader.Program) (*classifiedProgram,
|
||||
if seenStruct == "" || seenStruct == matches[1] {
|
||||
seenStruct = matches[1]
|
||||
} else {
|
||||
return nil, fmt.Errorf("classifier: already annotated as %s, can't also be %q", seenStruct, matches[1])
|
||||
return nil, fmt.Errorf("classifier: already annotated as %s, can't also be %q - %s", seenStruct, matches[1], cline.Text)
|
||||
}
|
||||
case "meta":
|
||||
if !mt {
|
||||
@@ -134,7 +134,7 @@ func (pc *programClassifier) Classify(prog *loader.Program) (*classifiedProgram,
|
||||
if seenStruct == "" || seenStruct == matches[1] {
|
||||
seenStruct = matches[1]
|
||||
} else {
|
||||
return nil, fmt.Errorf("classifier: already annotated as %s, can't also be %q", seenStruct, matches[1])
|
||||
return nil, fmt.Errorf("classifier: already annotated as %s, can't also be %q - %s", seenStruct, matches[1], cline.Text)
|
||||
}
|
||||
case "response":
|
||||
if !rs {
|
||||
@@ -144,7 +144,7 @@ func (pc *programClassifier) Classify(prog *loader.Program) (*classifiedProgram,
|
||||
if seenStruct == "" || seenStruct == matches[1] {
|
||||
seenStruct = matches[1]
|
||||
} else {
|
||||
return nil, fmt.Errorf("classifier: already annotated as %s, can't also be %q", seenStruct, matches[1])
|
||||
return nil, fmt.Errorf("classifier: already annotated as %s, can't also be %q - %s", seenStruct, matches[1], cline.Text)
|
||||
}
|
||||
case "strfmt", "name", "discriminated", "file", "enum", "default", "alias", "type":
|
||||
// TODO: perhaps collect these and pass along to avoid lookups later on
|
||||
|
||||
+2
@@ -16,6 +16,8 @@
|
||||
|
||||
/*Package scan provides a scanner for go files that produces a swagger spec document.
|
||||
|
||||
This package is intended for pre-go1.11 versions, and does not support go modules.
|
||||
|
||||
You give it a main file and it will parse all the files that are required by that main
|
||||
package to produce a swagger specification.
|
||||
|
||||
|
||||
Reference in new issue
Block a user