rfc3339

package
v1.0.6 Latest Latest
Warning

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

Go to latest
Published: Feb 10, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CurrentZone

func CurrentZone() (string, int)

Return the current time zone. Deprecated: use `types.RFC3339` instead.

func FromUnix

func FromUnix(t int64) time.Time

Convert a Unix `time_t` value to a time. Deprecated: use `types.RFC3339` instead.

func Parse added in v0.4.1

func Parse(data string) (time.Time, error)

Parse a string to an RFC3339 timestamp. Deprecated: use `types.RFC3339` instead.

func TimeToMySQL

func TimeToMySQL(t time.Time) string

Convert a time to a MySQL string. Deprecated: use `types.RFC3339` instead.

Types

type JSONRFC3339 added in v0.4.1

type JSONRFC3339 time.Time

An RFC3339 object. Deprecated: use `types.RFC3339` instead.

func (JSONRFC3339) Format added in v0.4.1

func (j JSONRFC3339) Format(s string) string

Format an RFC3339 object as a string. Deprecated: use `types.RFC3339` instead.

func (JSONRFC3339) MarshalJSON added in v0.4.1

func (j JSONRFC3339) MarshalJSON() ([]byte, error)

Marshal an RFC3339 object to JSON. Deprecated: use `types.RFC3339` instead.

func (JSONRFC3339) MySQL added in v0.4.1

func (j JSONRFC3339) MySQL() string

Convert an RFC3339 time to a MySQL timestamp. Deprecated: use `types.RFC3339` instead.

func (JSONRFC3339) Time added in v0.4.1

func (j JSONRFC3339) Time() time.Time

convert an RFC3339 time to time.Time. Deprecated: use `types.RFC3339` instead.

func (JSONRFC3339) UTC added in v0.4.1

func (j JSONRFC3339) UTC() time.Time

Convert an RFC3339 time to UTC. Deprecated: use `types.RFC3339` instead.

func (JSONRFC3339) Unix added in v0.4.1

func (j JSONRFC3339) Unix() int64

Convert an RFC3339 time to Unix time. Deprecated: use `types.RFC3339` instead.

func (*JSONRFC3339) UnmarshalJSON added in v0.4.1

func (j *JSONRFC3339) UnmarshalJSON(b []byte) error

Unmarshal an RFC3339 timestamp from JSON. Deprecated: use `types.RFC3339` instead.

Jump to

Keyboard shortcuts

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