Documentation
¶
Index ¶
- type Counted
- type TopKCounter
- func (c *TopKCounter) Bytes() []byte
- func (c *TopKCounter) Offer(item string) bool
- func (c *TopKCounter) OfferN(item string, increment int) bool
- func (c *TopKCounter) OfferReturnAll(item string, increment int) (bool, string)
- func (c *TopKCounter) OfferReturnDropped(item string, increment int) string
- func (c *TopKCounter) Peek(k int) []string
- func (c *TopKCounter) Size() int
- func (c *TopKCounter) TopK(k int) []Counted
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TopKCounter ¶
type TopKCounter struct {
// contains filtered or unexported fields
}
func NewTopKCounter ¶
func NewTopKCounter(capacity int64) *TopKCounter
func NewTopKCounterBytes ¶
func NewTopKCounterBytes(buf []byte) (c *TopKCounter, err error)
func (*TopKCounter) Bytes ¶
func (c *TopKCounter) Bytes() []byte
func (*TopKCounter) Offer ¶
func (c *TopKCounter) Offer(item string) bool
func (*TopKCounter) OfferReturnAll ¶
func (c *TopKCounter) OfferReturnAll(item string, increment int) (bool, string)
func (*TopKCounter) OfferReturnDropped ¶
func (c *TopKCounter) OfferReturnDropped(item string, increment int) string
func (*TopKCounter) Peek ¶
func (c *TopKCounter) Peek(k int) []string
func (*TopKCounter) Size ¶
func (c *TopKCounter) Size() int
func (*TopKCounter) TopK ¶
func (c *TopKCounter) TopK(k int) []Counted
Click to show internal directories.
Click to hide internal directories.