github.com/rzurga/go-swagger@v0.28.1-0.20211109195225-5d1f453ffa3a/fixtures/goparsing/petstore/models/pet.go (about) 1 // Copyright 2015 go-swagger maintainers 2 // 3 // Licensed under the Apache License, Version 2.0 (the "License"); 4 // you may not use this file except in compliance with the License. 5 // You may obtain a copy of the License at 6 // 7 // http://www.apache.org/licenses/LICENSE-2.0 8 // 9 // Unless required by applicable law or agreed to in writing, software 10 // distributed under the License is distributed on an "AS IS" BASIS, 11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 // See the License for the specific language governing permissions and 13 // limitations under the License. 14 15 package models 16 17 import ( 18 "time" 19 20 "github.com/go-swagger/go-swagger/fixtures/goparsing/petstore/enums" 21 ) 22 23 // A Pet is the main product in the store. 24 // It is used to describe the animals available in the store. 25 // 26 // swagger:model pet 27 type Pet struct { 28 // The id of the pet. 29 // 30 // required: true 31 ID int64 `json:"id"` 32 33 // The name of the pet. 34 // 35 // required: true 36 // pattern: \w[\w-]+ 37 // minimum length: 3 38 // maximum length: 50 39 Name string `json:"name"` 40 41 // The photo urls for the pet. 42 // This only accepts jpeg or png images. 43 // 44 // items pattern: \.(jpe?g|png)$ 45 PhotoURLs []string `json:"photoUrls,omitempty"` 46 47 // The current status of the pet in the store. 48 Status enums.Status `json:"status,omitempty"` 49 50 // Extra bits of information attached to this pet. 51 // 52 Tags []Tag `json:"tags,omitempty"` 53 54 // The pet's birthday 55 // 56 // swagger:strfmt date 57 Birthday time.Time `json:"birthday"` 58 }