Stud.IP  5.4
FilesIndexManager Class Reference

Static Public Member Functions

static sqlIndex (\FileRef $fileRef=null, array $options=[])
 
static indexFile (\FileRef $fileRef)
 
static indexFiles ()
 
static indexFolder (\Folder $folder)
 
static dropIndexForFolder (\Folder $folder)
 
static dropIndexForFile (\FileRef $fileRef)
 

Data Fields

const TIME_LIMIT = 3600
 
const RATING_FILE_REF_NAME = 0.9
 
const RATING_FILE_REF_DESCRIPTION = 0.4
 
const RATING_FILE_AUTHOR = 0.5
 
const RATING_RANGE_COURSE_NAME = 0.1
 
const RATING_RANGE_INSTITUTE_NAME = 0.1
 

Detailed Description

The FilesIndexManager is responsible for creating the fulltext index of all or just single files.

GPL2 or any later version

Since
Stud.IP 4.1

Member Function Documentation

◆ dropIndexForFile()

static dropIndexForFile ( \FileRef  $fileRef)
static

This method drops the index of a single file.

Parameters
FileRefthe file whose index shall be dropped

◆ dropIndexForFolder()

static dropIndexForFolder ( \Folder  $folder)
static

This method drops all indexes of direct children of a folder.

Parameters
Folder$folderthe folder to drop indexes of

◆ indexFile()

static indexFile ( \FileRef  $fileRef)
static

This method indexes a single file.

Parameters
FileRef$fileRefthe file to index

◆ indexFiles()

static indexFiles ( )
static

This method indexes all files.

◆ indexFolder()

static indexFolder ( \Folder  $folder)
static

This method indexes the direct children of a folder.

Parameters
Folder$folderthe folder to index

◆ sqlIndex()

static sqlIndex ( \FileRef  $fileRef = null,
array  $options = [] 
)
static

(Re-)Create the fulltext index of all files or a single file.

Parameters
FileRef$fileRefoptional; the file ref to (re-)index or otherwise all files will be indexed
array$optionsoptional; an array of options, currently only verbose is used - resulting in a verbose description of what the FilesIndexManager is doing
Returns
int the number of seconds the indexing took

Field Documentation

◆ RATING_FILE_AUTHOR

const RATING_FILE_AUTHOR = 0.5

◆ RATING_FILE_REF_DESCRIPTION

const RATING_FILE_REF_DESCRIPTION = 0.4

◆ RATING_FILE_REF_NAME

const RATING_FILE_REF_NAME = 0.9

◆ RATING_RANGE_COURSE_NAME

const RATING_RANGE_COURSE_NAME = 0.1

◆ RATING_RANGE_INSTITUTE_NAME

const RATING_RANGE_INSTITUTE_NAME = 0.1

◆ TIME_LIMIT

const TIME_LIMIT = 3600

The documentation for this class was generated from the following file: