github.com/josephspurrier/go-swagger@v0.2.1-0.20221129144919-1f672a142a00/fixtures/goparsing/classification/models/order_go118.go (about)

     1  //go:build !go1.19
     2  // +build !go1.19
     3  
     4  // Copyright 2015 go-swagger maintainers
     5  //
     6  // Licensed under the Apache License, Version 2.0 (the "License");
     7  // you may not use this file except in compliance with the License.
     8  // You may obtain a copy of the License at
     9  //
    10  //    http://www.apache.org/licenses/LICENSE-2.0
    11  //
    12  // Unless required by applicable law or agreed to in writing, software
    13  // distributed under the License is distributed on an "AS IS" BASIS,
    14  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    15  // See the License for the specific language governing permissions and
    16  // limitations under the License.
    17  
    18  package models
    19  
    20  import "github.com/go-swagger/go-swagger/fixtures/goparsing/classification/transitive/mods"
    21  
    22  // StoreOrder represents an order in this application.
    23  //
    24  // An order can either be created, processed or completed.
    25  //
    26  // swagger:model order
    27  type StoreOrder struct {
    28  	// the id for this order
    29  	//
    30  	// required: true
    31  	// min: 1
    32  	ID int64 `json:"id"`
    33  
    34  	// the name for this user
    35  	//
    36  	// required: true
    37  	// min length: 3
    38  	UserID int64 `json:"userId"`
    39  
    40  	// the category of this user
    41  	//
    42  	// required: true
    43  	// default: bar
    44  	// enum: foo,bar,none
    45  	Category string `json:"category"`
    46  
    47  	// the items for this order
    48  	Items []struct {
    49  		ID       int32    `json:"id"`
    50  		Pet      mods.Pet `json:"pet"`
    51  		Quantity int16    `json:"quantity"`
    52  	} `json:"items"`
    53  }