roundingTimeOptionEnum

package
v0.0.0-...-61f454b Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RoundingTimeOption

type RoundingTimeOption int

RoundingTimeOption .

const (
	// NoRounding .
	NoRounding RoundingTimeOption = iota + 1
	// MinuteCeil .
	MinuteCeil
	// MinuteRound .
	MinuteRound
	// MinuteFloor .
	MinuteFloor
	// HourCeil .
	HourCeil
	// HourRound .
	HourRound
	// HourFloor .
	HourFloor

	// Default .
	Default = NoRounding
)

func (RoundingTimeOption) Code

func (c RoundingTimeOption) Code() string

Code .

func (RoundingTimeOption) MarshalJSON

func (c RoundingTimeOption) MarshalJSON() ([]byte, error)

MarshalJSON presents value to the client

func (RoundingTimeOption) Name

func (c RoundingTimeOption) Name() string

Name .

func (RoundingTimeOption) RoundTime

func (c RoundingTimeOption) RoundTime(t time.Time) time.Time

func (*RoundingTimeOption) Scan

func (c *RoundingTimeOption) Scan(val interface{}) error

Scan retrieves value from the DB

func (*RoundingTimeOption) UnmarshalJSON

func (c *RoundingTimeOption) UnmarshalJSON(val []byte) error

UnmarshalJSON parses value from the client

func (*RoundingTimeOption) UnmarshalParam

func (c *RoundingTimeOption) UnmarshalParam(src string) error

UnmarshalParam parses value from the client (handled by gorm)

func (RoundingTimeOption) Value

func (c RoundingTimeOption) Value() (driver.Value, error)

Value encodes value to the DB

type RoundingTimeOptionClass

type RoundingTimeOptionClass struct {
	Code string `json:"code"`
	Name string `json:"name"`
}

RoundingTimeOptionClass .

Jump to

Keyboard shortcuts

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