structHelper

package
v1.5.54 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2025 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetStructAllFields

func GetStructAllFields(target interface{})

*

  • @func: GetStructAllFields 打印结构体的所有键值
  • @author Wiidz
  • @date 2019-11-16

func GetStructAllKV

func GetStructAllKV(target interface{})

*

  • @func: GetStructAllFields 打印结构体的所有键值对
  • @author Wiidz
  • @date 2019-11-16

func GetStructAllMethods

func GetStructAllMethods(target interface{})

*

  • @func: GetStructAllMethods 打印结构体的所有方法
  • @author Wiidz
  • @date 2019-11-16

func GetStructPointAllKV added in v1.5.6

func GetStructPointAllKV(target interface{})

*

  • @func: GetStructAllFields 打印结构体的所有键值对
  • @author Wiidz
  • @date 2019-11-16

func GetValueByKeyName added in v1.5.6

func GetValueByKeyName(targetStruct interface{}, keyName string) interface{}

GetValueByKeyName 根据键名获取结构体中的数据

Types

type Set

type Set struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

集合模拟

func NewSet

func NewSet() *Set

func (*Set) Add

func (s *Set) Add(item int)

func (*Set) Clear

func (s *Set) Clear()

func (*Set) Has

func (s *Set) Has(item int) bool

func (*Set) IsEmpty

func (s *Set) IsEmpty() bool

func (*Set) Len

func (s *Set) Len() int

func (*Set) List

func (s *Set) List() []int

func (*Set) Remove

func (s *Set) Remove(item int)

func (*Set) SortList

func (s *Set) SortList() []int

Jump to

Keyboard shortcuts

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