handlers

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PageSize = 10
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseSearch

type BaseSearch struct {
	sync.WaitGroup
	sync.Mutex
	Nexts []Handler
	// contains filtered or unexported fields
}

func NewBaseSearch

func NewBaseSearch(nexts ...Handler) *BaseSearch

func (*BaseSearch) AppendContent

func (b *BaseSearch) AppendContent(content *pb.SearchResultContent)

func (*BaseSearch) AppendError

func (b *BaseSearch) AppendError(err error)

func (*BaseSearch) BeginSearch

func (b *BaseSearch) BeginSearch(ctx context.Context, req *pb.SearchRequest)

func (*BaseSearch) DoNexts

func (b *BaseSearch) DoNexts(ctx context.Context, req *pb.SearchRequest)

func (*BaseSearch) GetResult

func (b *BaseSearch) GetResult() (*pb.SearchResponse, error)

func (*BaseSearch) SetNexts

func (b *BaseSearch) SetNexts(handlers ...Handler)

type Handler

type Handler interface {
	BeginSearch(ctx context.Context, req *pb.SearchRequest)
	SetNexts(nexts ...Handler)
	GetResult() (*pb.SearchResponse, error)
}

type SearchType

type SearchType string
const (
	SearchTypeIssue SearchType = "issue"
)

func (SearchType) String

func (s SearchType) String() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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