create

package
v2.0.1 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2026 License: MIT Imports: 3 Imported by: 30

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Create

type Create struct {
	// Any use this for cases where you need to pass something down to the
	// adapter.
	Any interface{} `form:"any" json:"any" param:"any" query:"any" validate:"omitempty,gt=0"`

	// ID of the resource.
	ID string `form:"id" json:"id,omitempty" param:"id" query:"id" validate:"omitempty,gt=0"`

	// Routing informs the storage adapter to use a specific route to access the
	// data.
	Routing string `form:"routing" json:"routing" param:"routing" query:"routing" validate:"omitempty,gt=0"`

	// TTL is the time-to-live.
	//
	// NOTE: Not all storage supports that.
	TTL time.Duration `form:"ttl" json:"ttl,omitempty" param:"ttl" query:"ttl" validate:"omitempty,gt=0"`
}

Create params.

SEE: https://echo.labstack.com/guide/binding/#data-sources on data binding.

func New

func New() (*Create, error)

New creates a new param.

func (*Create) Process

func (s *Create) Process() error

Process the `default` -> `env` -> `validate` struct's fields tags.

NOTE: This function just for testing purpose.

Jump to

Keyboard shortcuts

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