github.com/vnforks/kid/v5@v5.22.1-0.20200408055009-b89d99c65676/services/searchengine/interface.go (about)

     1  // Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
     2  // See LICENSE.txt for license information.
     3  
     4  package searchengine
     5  
     6  import (
     7  	"time"
     8  
     9  	"github.com/vnforks/kid/v5/model"
    10  )
    11  
    12  type SearchEngineInterface interface {
    13  	Start() *model.AppError
    14  	Stop() *model.AppError
    15  	GetVersion() int
    16  	UpdateConfig(cfg *model.Config)
    17  	GetName() string
    18  	IsActive() bool
    19  	IsIndexingEnabled() bool
    20  	IsSearchEnabled() bool
    21  	IsAutocompletionEnabled() bool
    22  	IsIndexingSync() bool
    23  	IndexClass(class *model.Class) *model.AppError
    24  	DeleteClass(class *model.Class) *model.AppError
    25  	IndexUser(user *model.User, branchesIds, classesIds []string) *model.AppError
    26  	//	SearchUsersInBranch(branchId string, restrictedToClasses []string, term string, options *model.UserSearchOptions) ([]string, *model.AppError)
    27  	DeleteUser(user *model.User) *model.AppError
    28  	TestConfig(cfg *model.Config) *model.AppError
    29  	PurgeIndexes() *model.AppError
    30  	RefreshIndexes() *model.AppError
    31  	DataRetentionDeleteIndexes(cutoff time.Time) *model.AppError
    32  }