utils

package
v0.0.0-...-1139f41 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InArray

func InArray(v interface{}, arr []interface{}) bool

InArray returns a slice contains given value or not

func IsAlnum

func IsAlnum(ch byte) bool

IsAlnum determine whether a character is a letter or a digit

func IsAlpha

func IsAlpha(ch byte) bool

IsAlpha determine whether a character is a letter

func IsDigit

func IsDigit(ch byte) bool

IsDigit determine whether a character is a digit

func QueryInMapInter

func QueryInMapInter(data map[string]interface{}, path []string) interface{}

QueryInMapInter query value in map[string]interface{} by path

Types

type Queue

type Queue struct {
	// contains filtered or unexported fields
}

Queue FIFO (First In First Out) data struct

func (*Queue) IsEmpty

func (q *Queue) IsEmpty() bool

IsEmpty is queue empty

func (*Queue) Pop

func (q *Queue) Pop() interface{}

Pop fetch the queue header element and return

func (*Queue) Push

func (q *Queue) Push(value interface{})

Push add item to queue's end

func (*Queue) Size

func (q *Queue) Size() int

Size return the queue's elements count

Jump to

Keyboard shortcuts

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