common

package
v1.3.5 Latest Latest
Warning

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

Go to latest
Published: Aug 22, 2025 License: MIT Imports: 6 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetColumnValue added in v1.3.2

func GetColumnValue(v interface{}) interface{}

GetColumnValue unwraps our custom nullable types into a value the database can use.

func TryParseDateTime

func TryParseDateTime(input string) (time.Time, error)

Types

type NullableBool

type NullableBool struct {
	sql.NullBool
}

NullableBool is a custom wrapper for sql.NullBool

func (*NullableBool) UnmarshalText

func (nb *NullableBool) UnmarshalText(text []byte) error

UnmarshalText forces the implementation for csvutil

type NullableFloat64

type NullableFloat64 struct {
	sql.NullFloat64
}

NullableFloat64 is a custom wrapper for sql.NullFloat64

func (*NullableFloat64) UnmarshalText

func (nf *NullableFloat64) UnmarshalText(text []byte) error

UnmarshalText forces the implementation for csvutil

type NullableInt64

type NullableInt64 struct {
	sql.NullInt64
}

NullableInt64 is a custom type that wraps sql.NullInt64 to implement the encoding.TextUnmarshaler interface.

func (*NullableInt64) UnmarshalText

func (ni *NullableInt64) UnmarshalText(text []byte) error

UnmarshalText implements the encoding.TextUnmarshaler interface.

type NullableString

type NullableString struct {
	sql.NullString
}

func (*NullableString) UnmarshalText

func (ns *NullableString) UnmarshalText(text []byte) error

type NullableTime

type NullableTime struct {
	sql.NullTime
}

NullableTime is a custom wrapper for sql.NullTime

func (*NullableTime) Scan added in v1.3.1

func (nt *NullableTime) Scan(value interface{}) error

Scan implements the sql.Scanner interface for reading from the database.

func (*NullableTime) UnmarshalText

func (nt *NullableTime) UnmarshalText(text []byte) error

UnmarshalText forces the implementation for csvutil

func (*NullableTime) Value added in v1.3.1

func (nt *NullableTime) Value() (driver.Value, error)

Value return the value

Jump to

Keyboard shortcuts

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