validation

package
v2.0.0-beta.53 Latest Latest
Warning

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

Go to latest
Published: May 9, 2024 License: MPL-2.0 Imports: 6 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func JSONNoDuplicateKeys

func JSONNoDuplicateKeys(s string) error

JSONNoDuplicateKeys verifies the provided JSON object contains no duplicated keys

The function expects a single JSON object, and will error prior to checking for duplicate keys should an invalid input be provided.

func SupportedRegion

func SupportedRegion(region string) error

SupportedRegion checks if the given region is a valid AWS region.

Types

type DuplicateKeyError

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

DuplicateKeyError is returned when duplicate key names are detected inside a JSON object

func (*DuplicateKeyError) Error

func (e *DuplicateKeyError) Error() string

type InvalidRegionError

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

func (*InvalidRegionError) Error

func (e *InvalidRegionError) Error() string

Jump to

Keyboard shortcuts

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