key

package
v0.0.0-...-931a7b5 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2024 License: MIT Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var GlobRegex = regexp.MustCompile(`^[a-zA-Z\*\d]$|^[a-zA-Z\*\d][a-zA-Z\*\d\/]+[a-zA-Z\*\d]$`)

GlobRegex checks for valid glob paths

Functions

func Build

func Build(key string) string

Build a new key for a path

func Contains

func Contains(s []string, e string) bool

Contains find match in an array of paths

func Decode

func Decode(key string) int64

Decode key to timestamp

func IsValid

func IsValid(key string) bool

IsValid checks that the key pattern issuported

func LastIndex

func LastIndex(key string) string

LastIndex will return the last sub path of the key

func Match

func Match(path string, key string) bool

Match checks if a key is part of a path (glob)

func Peer

func Peer(a string, b string) bool

Types

This section is empty.

Jump to

Keyboard shortcuts

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