internal

package
v0.2.44 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 7, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package internal keeps reusable internal code.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OperationContext

type OperationContext struct {
	// contains filtered or unexported fields
}

OperationContext implements openapi.OperationContext.

func NewOperationContext

func NewOperationContext(method, pathPattern string) *OperationContext

NewOperationContext creates OperationContext.

func (*OperationContext) AddReqStructure

func (o *OperationContext) AddReqStructure(s interface{}, options ...openapi.ContentOption)

AddReqStructure adds request content schema.

func (*OperationContext) AddRespStructure

func (o *OperationContext) AddRespStructure(s interface{}, options ...openapi.ContentOption)

AddRespStructure adds response content schema.

func (*OperationContext) IsProcessingResponse

func (o *OperationContext) IsProcessingResponse() bool

IsProcessingResponse indicates if response is being processed.

func (*OperationContext) Method

func (o *OperationContext) Method() string

Method returns HTTP method of an operation.

func (*OperationContext) PathPattern

func (o *OperationContext) PathPattern() string

PathPattern returns operation HTTP URL path pattern.

func (*OperationContext) ProcessingIn

func (o *OperationContext) ProcessingIn() openapi.In

ProcessingIn return which content location is being processed now.

func (*OperationContext) Request

func (o *OperationContext) Request() []openapi.ContentUnit

Request returns list of operation request content schemas.

func (*OperationContext) Response

func (o *OperationContext) Response() []openapi.ContentUnit

Response returns list of operation response content schemas.

func (*OperationContext) SetIsProcessingResponse

func (o *OperationContext) SetIsProcessingResponse(is bool)

SetIsProcessingResponse sets current processing state.

func (*OperationContext) SetMethod

func (o *OperationContext) SetMethod(method string)

SetMethod sets HTTP method of an operation.

func (*OperationContext) SetPathPattern

func (o *OperationContext) SetPathPattern(pattern string)

SetPathPattern sets URL path pattern of an operation.

func (*OperationContext) SetProcessingIn

func (o *OperationContext) SetProcessingIn(in openapi.In)

SetProcessingIn sets current content location being processed.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL