Stud.IP  5.4
 All Data Structures Namespaces Files Functions Variables Groups
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

static dropIndexForFile ( \FileRef  $fileRef)
static

This method drops the index of a single file.

Parameters
FileRefthe file whose index shall be dropped
static dropIndexForFolder ( \Folder  $folder)
static

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

Parameters
Folder$folderthe folder to drop indexes of
static indexFile ( \FileRef  $fileRef)
static

This method indexes a single file.

Parameters
FileRef$fileRefthe file to index
static indexFiles ( )
static

This method indexes all files.

static indexFolder ( \Folder  $folder)
static

This method indexes the direct children of a folder.

Parameters
Folder$folderthe folder to index
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

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

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