Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2891320
CelerityResources.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Advanced/Developer...
View Handle
View Hovercard
Size
845 B
Referenced Files
None
Subscribers
None
CelerityResources.php
View Options
<?php
/**
* Defines the location of static resources.
*/
abstract
class
CelerityResources
{
private
$map
;
abstract
public
function
getName
(
)
;
abstract
public
function
getResourceData
(
$name
)
;
public
function
getResourceModifiedTime
(
$name
)
{
return
0
;
}
public
function
getCelerityHash
(
$data
)
{
$tail
=
PhabricatorEnv
::
getEnvConfig
(
'celerity.resource-hash'
)
;
$hash
=
PhabricatorHash
::
digest
(
$data
,
$tail
)
;
return
substr
(
$hash
,
0
,
8
)
;
}
public
function
getResourceType
(
$path
)
{
return
CelerityResourceTransformer
::
getResourceType
(
$path
)
;
}
public
function
getResourceURI
(
$hash
,
$name
)
{
$resources
=
$this
->
getName
(
)
;
return
"/res/{$resources}/{$hash}/{$name}"
;
}
public
function
getResourcePackages
(
)
{
return
array
(
)
;
}
public
function
loadMap
(
)
{
return
array
(
)
;
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sun, Jan 19, 15:01 (3 w, 1 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1125756
Default Alt Text
CelerityResources.php (845 B)
Attached To
Mode
rP Phorge
Attached
Detach File
Event Timeline
Log In to Comment