AFilesDocument
extends IndexDocument
in package
AbstractYes
Abstract Class AFilesDocument
This is mostly used by 3rd party apps that want to complete the IIndexDocument with more information about a file before its index:
\OC::$server->getEventDispatcher()->addListener( '\OCA\Files_FullTextSearch::onFileIndexing', function(GenericEvent $e) { //@var \OCP\Files\Node $file $file = $e->getArgument('file');
// @var \OCP\Files_FullTextSearch\Model\AFilesDocument $document
$document = $e->getArgument('document');
}
);
Tags
Table of Contents
Methods
- getMimetype() : string
- Returns the mimetype of the document/file.
- getOwnerId() : string
- Returns the owner of the document/file.
- getPath() : string
- Returns the path of the document/file.
- getType() : string
- Returns the type of the document/file.
- getViewerId() : string
- Returns the current viewer of the document/file.
Methods
getMimetype()
Returns the mimetype of the document/file.
public
abstract getMimetype() : string
Tags
Return values
stringgetOwnerId()
Returns the owner of the document/file.
public
abstract getOwnerId() : string
Tags
Return values
stringgetPath()
Returns the path of the document/file.
public
abstract getPath() : string
Tags
Return values
stringgetType()
Returns the type of the document/file.
public
abstract getType() : string
Tags
Return values
string —\OCP\Files\FileInfo::TYPE_FILE|\OCP\Files\FileInfo::TYPE_FOLDER
getViewerId()
Returns the current viewer of the document/file.
public
abstract getViewerId() : string