This commit is contained in:
2022-03-17 15:55:27 +08:00
commit bd5a9fad97
92 changed files with 13861 additions and 0 deletions

21
dtask/pkg/rbtree/util.go Normal file
View File

@@ -0,0 +1,21 @@
// Copyright 2015, Hu Keping. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package rbtree
// Int is type of int
type Int int
// Less returns whether x(Int) is smaller than specified item
func (x Int) Less(than Item) bool {
return x < than.(Int)
}
// String is type of string
type String string
// Less returns whether x(String) is smaller than specified item
func (x String) Less(than Item) bool {
return x < than.(String)
}