calendar

package
v0.0.0-...-fae1b12 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2020 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Calendar

type Calendar struct {
	Solar  *solar.Solar
	Lunar  *lunar.Lunar
	Ganzhi *ganzhi.Ganzhi
	// contains filtered or unexported fields
}

Calendar 日历

func ByLunar

func ByLunar(year, month, day, hour, minute, second int64, isLeapMonth bool) *Calendar

ByLunar 通过农历创建

func BySolar

func BySolar(year, month, day, hour, minute, second int64) *Calendar

BySolar 通过国历创建

func ByTimestamp

func ByTimestamp(ts int64) *Calendar

ByTimestamp 通过时间戳创建

func (*Calendar) Equals

func (calendar *Calendar) Equals(b *Calendar) bool

Equals 判断两个对象是否相同

func (*Calendar) ToJSON

func (calendar *Calendar) ToJSON() ([]byte, error)

ToJSON JSON输出

Jump to

Keyboard shortcuts

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