tools

package
v0.0.0-...-089390d Latest Latest
Warning

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

Go to latest
Published: Aug 17, 2017 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package tools contains: calendar.go - cron.go - substrings.go

Format provides the functions to analyze the name, the number and the lenght of months

Package tools contains: calendar.go - cron.go - substrings.go

Cron provides the functions to extract the information of JSON crontab Returns human readable format

Package tools contains: calendar.go - cron.go - substrings.go

Functions to get substrings Sort a list of snapshots

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func After

func After(value string, a string) string

After gets substring after a string

func Arrange

func Arrange(SnapshotsList []string) []string

Arrange sorts the list of snapshots

func Before

func Before(value string, a string) string

Before gets substring before a string

func Between

func Between(value string, a string, b string) string

Between gets a substring between two strings

func Crontab

func Crontab(cron string) ([]int, []int, []int, []time.Month, []time.Weekday)

Crontab extract the information of JSON crontab

func LengthMonth

func LengthMonth(year int, month time.Month) (bool, string)

LengthMonth specifies the length of the month in function of days

func NameMonth

func NameMonth(month string) time.Month

NameMonth returns the name of the month

func NameMonthInt

func NameMonthInt(month int) time.Month

NameMonthInt returns the name of the month

func NameMonthZero

func NameMonthZero(month string) time.Month

NameMonthZero returns the name of the month

func NameWeek

func NameWeek(weekday string) time.Weekday

NameWeek returns the name of the weekday

func NameWeekInt

func NameWeekInt(weekday int) time.Weekday

NameWeekInt returns the name of the weekday

func NumberMonth

func NumberMonth(SnapshotName string) string

NumberMonth replaces the name of the month by the number

func NumberMonthReverse

func NumberMonthReverse(SnapshotName string) string

NumberMonthReverse replaces the number of the month by the name

func Reverse

func Reverse(value string, a string) string

Reverse gets substring

Types

This section is empty.

Jump to

Keyboard shortcuts

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