Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F492388
DiffusionBuildableEngine.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
DiffusionBuildableEngine.php
View Options
<?php
final
class
DiffusionBuildableEngine
extends
HarbormasterBuildableEngine
{
public
function
publishBuildable
(
HarbormasterBuildable
$old
,
HarbormasterBuildable
$new
)
{
// Don't publish manual buildables.
if
(
$new
->
getIsManualBuildable
())
{
return
;
}
// Don't publish anything if the buildable status has not changed. At
// least for now, Diffusion handles buildable status exactly the same
// way that Harbormaster does.
$old_status
=
$old
->
getBuildableStatus
();
$new_status
=
$new
->
getBuildableStatus
();
if
(
$old_status
===
$new_status
)
{
return
;
}
// Don't publish anything if the buildable is still building.
if
(
$new
->
isBuilding
())
{
return
;
}
$xaction
=
$this
->
newTransaction
()
->
setMetadataValue
(
'harbormaster:buildablePHID'
,
$new
->
getPHID
())
->
setTransactionType
(
DiffusionCommitBuildableTransaction
::
TRANSACTIONTYPE
)
->
setNewValue
(
$new
->
getBuildableStatus
());
$this
->
applyTransactions
(
array
(
$xaction
));
}
public
function
getAuthorIdentity
()
{
return
$this
->
getObject
()
->
loadIdentities
(
$this
->
getViewer
())
->
getAuthorIdentity
();
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Wed, May 7, 11:03 PM (2 d)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
80637
Default Alt Text
DiffusionBuildableEngine.php (1 KB)
Attached To
Mode
rP Phorge
Attached
Detach File
Event Timeline
Log In to Comment