github.com/kaisawind/go-swagger@v0.19.0/fixtures/goparsing/classification/transitive/mods/category.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 mods
    16  
    17  // Category represents a category for a pet
    18  // categories are things like: cat, dog, fish
    19  //
    20  // Even though this model is not annotated with anything,
    21  // and it's not included in the initial imports
    22  // it should still register because it's a required file for the pet model
    23  type Category struct {
    24  	// ID the id of the category
    25  	//
    26  	// required: true
    27  	// min: 1
    28  	ID int64 `json:"id"`
    29  
    30  	// Name the name of the category
    31  	//
    32  	// required: true
    33  	Name string `json:"name"`
    34  }