Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F106995415
PhutilSyntaxHighlighterEngine.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
Thu, Apr 3, 08:06
Size
560 B
Mime Type
text/x-php
Expires
Sat, Apr 5, 08:06 (2 d)
Engine
blob
Format
Raw Data
Handle
25328022
Attached To
rPHU libphutil
PhutilSyntaxHighlighterEngine.php
View Options
<?php
abstract
class
PhutilSyntaxHighlighterEngine
{
abstract
public
function
setConfig
(
$key
,
$value
);
abstract
public
function
getHighlightFuture
(
$language
,
$source
);
abstract
public
function
getLanguageFromFilename
(
$filename
);
final
public
function
highlightSource
(
$language
,
$source
)
{
try
{
return
$this
->
getHighlightFuture
(
$language
,
$source
)->
resolve
();
}
catch
(
PhutilSyntaxHighlighterException
$ex
)
{
return
id
(
new
PhutilDefaultSyntaxHighlighter
())
->
getHighlightFuture
(
$source
)
->
resolve
();
}
}
}
Event Timeline
Log In to Comment