internal

package
v0.0.0-...-b9d0bc2 Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

func LowercaseFirstCharacter

func LowercaseFirstCharacter(str string) string

LowercaseFirstCharacter returns copy of str with first char lowercase. With respect to Unicode.

func SchemaHasAdditionalProperties

func SchemaHasAdditionalProperties(schema *openapi3.Schema) bool

SchemaHasAdditionalProperties returns true if schema can or do contain additional properties.

func SortedContentKeys

func SortedContentKeys(dict openapi3.Content) []string

SortedContentKeys returns Content map keys in sorted order.

func SortedOperationsKeys

func SortedOperationsKeys(m map[string]*openapi3.Operation) []string

SortedOperationsKeys returns Operation map keys in sorted order.

func SortedParameterKeys

func SortedParameterKeys(dict map[string]*openapi3.ParameterRef) []string

SortedParameterKeys returns ParameterRef map keys in sorted order.

func SortedPathsKeys

func SortedPathsKeys(m openapi3.Paths) []string

SortedPathsKeys returns Paths map keys in sorted order.

func SortedRequestBodyKeys

func SortedRequestBodyKeys(dict map[string]*openapi3.RequestBodyRef) []string

SortedRequestBodyKeys returns RequestBodyRef map keys in sorted order.

func SortedResponsesKeys

func SortedResponsesKeys(m openapi3.Responses) []string

SortedResponsesKeys returns Responses map keys in sorted order.

func SortedSchemaKeys

func SortedSchemaKeys(m map[string]*openapi3.SchemaRef) []string

SortedSchemaKeys returns SchemaRef map keys in sorted order.

func SortedStringKeys

func SortedStringKeys(dict map[string]string) []string

SortedStringKeys returns strings map keys in sorted order.

func StringInArray

func StringInArray(str string, sl []string) bool

StringInArray returns true if provided string is in provided slice.

func StringToGoComment

func StringToGoComment(in string) string

StringToGoComment renders a possible multi-line string as a valid Go-Comment. Each line is prefixed as a comment.

func ToCamelCase

func ToCamelCase(str string) string

ToCamelCase converts query-arg style strings to CamelCase.

We will use `., -, +, :, ;, _, ~, ' ', (, ), {, }, [, ]` as valid delimiters for words.

Example
s := "word.word-word+word:word;word_word~word word(word)word{word}[word]"

converted := ToCamelCase(s)

fmt.Println(converted)
Output:

WordWordWordWordWordWordWordWordWordWordWordWordWord

func UppercaseFirstCharacter

func UppercaseFirstCharacter(str string) string

UppercaseFirstCharacter returns copy of str with first char uppercase. With respect to Unicode.

Types

type Imports

type Imports []string

func (Imports) Len

func (i Imports) Len() int

func (Imports) Less

func (i Imports) Less(x, y int) bool

func (Imports) String

func (i Imports) String() string

func (Imports) Swap

func (i Imports) Swap(x, y int)

type ImportsSet

type ImportsSet map[string]Imports

func NewImportsSet

func NewImportsSet() ImportsSet

func (ImportsSet) External

func (i ImportsSet) External() Imports

func (ImportsSet) Local

func (i ImportsSet) Local() Imports

func (ImportsSet) Sort

func (i ImportsSet) Sort()

func (ImportsSet) Std

func (i ImportsSet) Std() Imports

Jump to

Keyboard shortcuts

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