Documentation ¶
Index ¶
- func AppendQuotedString(buf []byte, str string) []byte
- func CheckName(name string) error
- func InterfaceSliceToStringSlice(input interface{}) interface{}
- func ParseBool(b []byte) (bool, error)
- func ParseFloat(b []byte) (float64, error)
- func ParseInt(b []byte) (i int, err error)
- func QuotedBytes(s string) []byte
- func ToUpper(bP *[]byte, s string) string
- func UnsafeBytesToString(in []byte) string
- type CIContainsMatcher
- type CIExactMatcher
- type CIPrefixMatcher
- type CIStringMatcher
- type CISuffixMatcher
- type ContainsMatcher
- type ExactMatcher
- type Matcher
- type Pointer
- type PrefixMatcher
- type RegexpMatcher
- type StringBlob
- type StringMatcher
- type StringSet
- type SuffixMatcher
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AppendQuotedString ¶
func InterfaceSliceToStringSlice ¶
func InterfaceSliceToStringSlice(input interface{}) interface{}
InterfaceSliceToStringSlice converts a slice of interface{} to a slice of strings. If the input is not a slice of interface{} it is returned unmodified. If the input slice does not consist of strings (only) the input is returned unmodified.
func ParseFloat ¶
func QuotedBytes ¶
func ToUpper ¶
This is a modified, zero alloc, version of the stdlib function strings.ToUpper. The passed in byte buffer is used to hold the converted string. The returned string is not safe to use when bP goes out of scope and the content may be overwritten upon next call to this function.
func UnsafeBytesToString ¶
Types ¶
type CIContainsMatcher ¶
type CIContainsMatcher CIStringMatcher
func (*CIContainsMatcher) Matches ¶
func (m *CIContainsMatcher) Matches(s string) bool
type CIExactMatcher ¶
type CIExactMatcher CIStringMatcher
func (*CIExactMatcher) Matches ¶
func (m *CIExactMatcher) Matches(s string) bool
type CIPrefixMatcher ¶
type CIPrefixMatcher CIStringMatcher
func (*CIPrefixMatcher) Matches ¶
func (m *CIPrefixMatcher) Matches(s string) bool
type CIStringMatcher ¶
type CIStringMatcher struct {
// contains filtered or unexported fields
}
type CISuffixMatcher ¶
type CISuffixMatcher CIStringMatcher
func (*CISuffixMatcher) Matches ¶
func (m *CISuffixMatcher) Matches(s string) bool
type ContainsMatcher ¶
type ContainsMatcher StringMatcher
func (*ContainsMatcher) Matches ¶
func (m *ContainsMatcher) Matches(s string) bool
type ExactMatcher ¶
type ExactMatcher StringMatcher
func (*ExactMatcher) Matches ¶
func (m *ExactMatcher) Matches(s string) bool
type Pointer ¶
type Pointer uint64
Pointer identifies a string within a StringBlob. Max individual string size 2^28 byte ~ 268 Mb Max total size 2^35 byte ~ 34 Gb
func NewPointer ¶
type PrefixMatcher ¶
type PrefixMatcher StringMatcher
func (*PrefixMatcher) Matches ¶
func (m *PrefixMatcher) Matches(s string) bool
type RegexpMatcher ¶
type RegexpMatcher struct {
// contains filtered or unexported fields
}
func (*RegexpMatcher) Matches ¶
func (m *RegexpMatcher) Matches(s string) bool
type StringBlob ¶
StringBlob represents a set of strings. The underlying data is stored in a byte blob which can be interpreted through the pointers which identifies the start and end of individual strings in the blob.
This structure is used instead of a slice of strings or a slice of string pointers is to avoid that the GC has to scan all pointers which takes quite some time with large/many live frames.
type StringMatcher ¶
type StringMatcher struct {
// contains filtered or unexported fields
}
type StringSet ¶
type StringSet map[string]struct{}
func NewEmptyStringSet ¶
func NewEmptyStringSet() StringSet
func NewStringSet ¶
type SuffixMatcher ¶
type SuffixMatcher StringMatcher
func (*SuffixMatcher) Matches ¶
func (m *SuffixMatcher) Matches(s string) bool