intf

package
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2023 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CacheAssemble = map[string][]interface{}{
	"Cache": {
		&list.LFUCache{},
		&list.LRUCache{},
	},
}
View Source
var CalculatorAssemble = map[string][]interface{}{
	"Calculator": {
		&stack.Calculator{},
		&stack.CalculatorWithBracket{},
		&stack.CalculatorWithOutBracket{},
	},
}
View Source
var DynamicAssemble = map[string][]interface{}{
	"LIS": {
		lis.LIS_Backtrack{},
		lis.LIS_Bisection{},
		lis.LIS_Dynamic{},
		lis.LIS_LCS{},
		lis.LIS_Poker{},
		lis.LIS_TwoPoint{},
		lis.LIS_Violence{},
	},
	"LCS": {
		&lcs.LCS_Dynamic{},
		&lcs.LCS_Optimize{},
	},
	"LMS": {lms.LMS_Dynamic{}},
	"LNS": {lns.LNS_Queue{}},
	"LSG": {
		lsg.LSG_BackTrack{},
		lsg.LSG_Dynamic{},
	},
	"LSS": {
		lss.LSS_Bisection{},
		lss.LSS_Dynamic{}},
}
View Source
var ListAssemble = map[string][]interface{}{
	"List": {
		&list.SkipList{},
		&list.SimplexList{},
		&list.DuplexList{},
	},
	"LastK": {
		&list.LastKRecursion{},
		&list.LastKTwoPoint{},
	},
}
View Source
var QueueAssemble = map[string][]interface{}{
	"Queue": {
		&queue.ArrayQueue{},

		&queue.LinkedQueue{},
		queue.NewStackQueue(),
	},
}

Functions

This section is empty.

Types

type Array2BTINFT

type Array2BTINFT interface {
	Method([]int) *list.Node
}

type ArraySortINTF

type ArraySortINTF interface {
	SortMethod(array []int)
	GetAttribute() *C.Attribute
}

所有排序算法的接口

type BT2ArrayINFT

type BT2ArrayINFT interface {
	Method(*list.Node) []int
}

type CacheINTF

type CacheINTF interface {
	Set(key, value interface{})
	Get(key interface{}) interface{}
	Delete(key interface{})
	Length() int
	Clear()
	GetAttribute() *C.Attribute
}

*

  • @author ljfirst
  • @version V1.0
  • @date 2023/6/28 17:17
  • @author-Email ljfirst@mail.ustc.edu.cn
  • @blogURL https://blog.csdn.net/ljfirst
  • @description *

type CalculatorINTF

type CalculatorINTF interface {
	Cal(string) float64
	StructName() string
}

*

  • @author ljfirst
  • @version V1.0
  • @date 2023/6/28 17:11
  • @author-Email ljfirst@mail.ustc.edu.cn
  • @blogURL https://blog.csdn.net/ljfirst
  • @description *

type CombineINTF

type CombineINTF interface {
}

type FindNum

type FindNum interface {
	FindMethod([]int32) []int32
	GetAttribute() *C.Attribute
}

type GraphINTF

type GraphINTF interface {
}

*

  • @author ljfirst
  • @version V1.0
  • @date 2023/6/26 08:25
  • @author-Email ljfirst@mail.ustc.edu.cn
  • @blogURL https://blog.csdn.net/ljfirst
  • @description *

type HeapINTF

type HeapINTF interface {
}

*

  • @author ljfirst
  • @version V1.0
  • @date 2023/6/26 08:25
  • @author-Email ljfirst@mail.ustc.edu.cn
  • @blogURL https://blog.csdn.net/ljfirst
  • @description *

type LCSINTF

type LCSINTF interface {
	LCSMethods(str string) int
}

type LISINTF

type LISINTF interface {
	LISMethod(str string) int
}

*

  • @author ljfirst
  • @version V1.0
  • @date 2023/7/10 00:03
  • @author-Email ljfirst@mail.ustc.edu.cn
  • @blogURL https://blog.csdn.net/ljfirst
  • @description *

type LMGINTF

type LMGINTF interface {
	LMGMethods(str string) int
}

type LMSINTF

type LMSINTF interface {
	LMSMethods(str string) int
}

type LNSINTF

type LNSINTF interface {
	LNSMethods(str string) int
}

type LSGINTF

type LSGINTF interface {
	LSGMethods(str string) int
}

type LSSINTF

type LSSINTF interface {
	LSSMethods(str string) int
}

type LastKINTF

type LastKINTF interface {
	FindMethod(*list.Node, int) *list.Node
	Delete(*list.Node, int) *list.Node
	GetAttribute() *C.Attribute
}

type ListINTF

type ListINTF interface {
	Insert(...*list.Node)           // 默认插在最后面
	InsertIndex(int, ...*list.Node) // 当index=0的时候,默认插在最前面

	Delete(*list.Node)
	DeleteIndex(int)

	ValueSet() []interface{}
	Equals(*list.Node)
	Size() int
	Clear()
	GetAttribute() *C.Attribute
}

*

  • @author ljfirst
  • @version V1.0
  • @date 2023/6/28 16:56
  • @author-Email ljfirst@mail.ustc.edu.cn
  • @blogURL https://blog.csdn.net/ljfirst
  • @description 链表 *

type MinStackINTF

type MinStackINTF interface {
	StackINTF // grammar接口之间的继承关系
	GetMin() int
	GetAttribute() *C.Attribute
}

最小栈 和 单调栈

type MonotonousStackINTF

type MonotonousStackINTF interface {
	NextValue([]int) []int
	GetAttribute() *C.Attribute
}

type OverHalfNumINTF

type OverHalfNumINTF interface {
	Method([]int) int
	GetAttribute() *C.Attribute
}

超过半数的数

type PermuteINTF

type PermuteINTF interface {
	PermuteMethod(arrayI interface{}) [][]interface{}
}

*

  • @author ljfirst
  • @version V1.0
  • @date 2023/7/7 13:29
  • @author-Email ljfirst@mail.ustc.edu.cn
  • @blogURL https://blog.csdn.net/ljfirst
  • @description 排列组合 *

type QueueINTF

type QueueINTF interface {
	Offer(interface{}) // insert into queue
	Poll() interface{} // pop from queue
	Peak() interface{} // get the ahead value from queue
	Size() int
	Resize() // extension the capacity of the queue
	StructName() string
}

*

  • @author ljfirst
  • @version V1.0
  • @date 2023/6/25 20:51
  • @author-Email ljfirst@mail.ustc.edu.cn
  • @blogURL https://blog.csdn.net/ljfirst
  • @description queue *

type ReturnKMinINTF

type ReturnKMinINTF interface {
	ReturnKMin([]int, int) []int
	GetAttribute() *C.Attribute
}
返回数组中最小的 k 个元素 -> 堆排法和快排法

Returns the smallest k elements in this array

type SlidingWindowINTF

type SlidingWindowINTF interface {
}

*

  • @author ljfirst
  • @version V1.0
  • @date 2023/7/7 13:24
  • @author-Email ljfirst@mail.ustc.edu.cn
  • @blogURL https://blog.csdn.net/ljfirst
  • @description 滑动窗口 *

type StackINTF

type StackINTF interface {
	Push(interface{})  // push value in to stack
	Pop() interface{}  // pop value from stack
	Peak() interface{} // get first value from stack
	Resize()           // extension the capacity of the stack
	Empty() bool
	Size() int
	GetAttribute() *C.Attribute
}

type TreeINTF

type TreeINTF interface {
}

*

  • @author ljfirst
  • @version V1.0
  • @date 2023/6/26 08:25
  • @author-Email ljfirst@mail.ustc.edu.cn
  • @blogURL https://blog.csdn.net/ljfirst
  • @description *

Jump to

Keyboard shortcuts

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