stackKit

package
v2.9.114 Latest Latest
Warning

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

Go to latest
Published: Feb 4, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Stack

type Stack[V any] interface {
	// Push 放在最后面
	Push(ele V)

	// Pop 移除并返回最后面的元素
	Pop() (V, bool)

	Size() int
}

Stack 堆栈(后进先出)

func NewStack

func NewStack[V any](safe ...bool) Stack[V]

func NewStackFrom deprecated added in v2.1.18

func NewStackFrom[V any](s []V, safe ...bool) Stack[V]

NewStackFrom

Deprecated: 有点耗性能,看 GoFrame 后续会不会支持泛型.

Jump to

Keyboard shortcuts

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