Debian Codegraph @

pkg/spec3/component.go

raw symbols SCIP
1 /*
2 Copyright 2021 The Kubernetes Authors.
3
4 Licensed under the Apache License, Version 2.0 (the "License");
5 you may not use this file except in compliance with the License.
6 You may obtain a copy of the License at
7
8 http://www.apache.org/licenses/LICENSE-2.0
9
10 Unless required by applicable law or agreed to in writing, software
11 distributed under the License is distributed on an "AS IS" BASIS,
12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 See the License for the specific language governing permissions and
14 limitations under the License.
15 */
16
17 package spec3
18
19 import "k8s.io/kube-openapi/pkg/validation/spec"
20
21 // Components holds a set of reusable objects for different aspects of the OAS.
22 // All objects defined within the components object will have no effect on the API
23 // unless they are explicitly referenced from properties outside the components object.
24 //
25 // more at https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.0.md#componentsObject
26 type Components struct {
27 // Schemas holds reusable Schema Objects
28 Schemas map[string]*spec.Schema `json:"schemas,omitempty"`
29 // SecuritySchemes holds reusable Security Scheme Objects, more at https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.0.md#securitySchemeObject
30 SecuritySchemes SecuritySchemes `json:"securitySchemes,omitempty"`
31 // Responses holds reusable Responses Objects
32 Responses map[string]*Response `json:"responses,omitempty"`
33 // Parameters holds reusable Parameters Objects
34 Parameters map[string]*Parameter `json:"parameters,omitempty"`
35 // Example holds reusable Example objects
36 Examples map[string]*Example `json:"examples,omitempty"`
37 // RequestBodies holds reusable Request Body objects
38 RequestBodies map[string]*RequestBody `json:"requestBodies,omitempty"`
39 // Links is a map of operations links that can be followed from the response
40 Links map[string]*Link `json:"links,omitempty"`
41 // Headers holds a maps of a headers name to its definition
42 Headers map[string]*Header `json:"headers,omitempty"`
43 // all fields are defined at https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.0.md#componentsObject
44 }
45
46 // SecuritySchemes holds reusable Security Scheme Objects, more at https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.0.md#securitySchemeObject
47 type SecuritySchemes map[string]*SecurityScheme