Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F93934328
PhabricatorSearchEngineExtension.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Mon, Dec 2, 15:23
Size
1 KB
Mime Type
text/x-php
Expires
Wed, Dec 4, 15:23 (2 d)
Engine
blob
Format
Raw Data
Handle
22727046
Attached To
rPH Phabricator
PhabricatorSearchEngineExtension.php
View Options
<?php
abstract
class
PhabricatorSearchEngineExtension
extends
Phobject
{
private
$viewer
;
private
$searchEngine
;
final
public
function
getExtensionKey
()
{
return
$this
->
getPhobjectClassConstant
(
'EXTENSIONKEY'
);
}
final
public
function
setViewer
(
$viewer
)
{
$this
->
viewer
=
$viewer
;
return
$this
;
}
final
public
function
getViewer
()
{
return
$this
->
viewer
;
}
final
public
function
setSearchEngine
(
PhabricatorApplicationSearchEngine
$engine
)
{
$this
->
searchEngine
=
$engine
;
return
$this
;
}
final
public
function
getSearchEngine
()
{
return
$this
->
searchEngine
;
}
abstract
public
function
isExtensionEnabled
();
abstract
public
function
getExtensionName
();
abstract
public
function
supportsObject
(
$object
);
public
function
getExtensionOrder
()
{
return
7000
;
}
public
function
getSearchFields
(
$object
)
{
return
array
();
}
public
function
getSearchAttachments
(
$object
)
{
return
array
();
}
public
function
applyConstraintsToQuery
(
$object
,
$query
,
PhabricatorSavedQuery
$saved
,
array
$map
)
{
return
;
}
public
function
getFieldSpecificationsForConduit
(
$object
)
{
return
array
();
}
public
function
getFieldValuesForConduit
(
$object
)
{
return
array
();
}
final
public
static
function
getAllExtensions
()
{
return
id
(
new
PhutilClassMapQuery
())
->
setAncestorClass
(
__CLASS__
)
->
setUniqueMethod
(
'getExtensionKey'
)
->
setSortMethod
(
'getExtensionOrder'
)
->
execute
();
}
final
public
static
function
getAllEnabledExtensions
()
{
$extensions
=
self
::
getAllExtensions
();
foreach
(
$extensions
as
$key
=>
$extension
)
{
if
(!
$extension
->
isExtensionEnabled
())
{
unset
(
$extensions
[
$key
]);
}
}
return
$extensions
;
}
}
Event Timeline
Log In to Comment