util

package
v0.9.3 Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DayInterval

func DayInterval(t time.Time) (time.Time, time.Time)

DayInterval returns a time interval for 24h

func HourInterval

func HourInterval(t time.Time) (time.Time, time.Time)

HourInterval returns a time interval for an hour

func MustInt64

func MustInt64(input string) int64

MustInt64 returns an Int64 value without an error

func MustTime

func MustTime(input string) time.Time

MustTime returns a time from a string

func MustUInt64

func MustUInt64(input string) uint64

MustUInt64 returns an UInt64 value without an error

func ParseBase58

func ParseBase58(input string) []byte

ParseBase58 returns a decoded base58 data

func ParseInt

func ParseInt(input string) (int, error)

func ParseInt64

func ParseInt64(input string) (int64, error)

ParseInt64 returns an Int64 from a string

func ParseMemoText

func ParseMemoText(input string) string

ParseMemoText returns memo plaintext from base58 data

func ParseTime

func ParseTime(input string) (*time.Time, error)

ParseTime returns a timestamp from a string

func ParseUInt64

func ParseUInt64(input string) (uint64, error)

ParseUInt64 returns an UInt64 from a string

func SHA1

func SHA1(input string) string

SHA1 returns a SHA1 digest of a given string in hex format

Types

This section is empty.

Jump to

Keyboard shortcuts

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