Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F93657909
AlmanacPropertiesDestructionEngineExtension.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
Sat, Nov 30, 12:27
Size
712 B
Mime Type
text/x-php
Expires
Mon, Dec 2, 12:27 (2 d)
Engine
blob
Format
Raw Data
Handle
22682468
Attached To
rPH Phabricator
AlmanacPropertiesDestructionEngineExtension.php
View Options
<?php
final
class
AlmanacPropertiesDestructionEngineExtension
extends
PhabricatorDestructionEngineExtension
{
const
EXTENSIONKEY
=
'almanac.properties'
;
public
function
getExtensionName
()
{
return
pht
(
'Almanac Properties'
);
}
public
function
canDestroyObject
(
PhabricatorDestructionEngine
$engine
,
$object
)
{
return
(
$object
instanceof
AlmanacPropertyInterface
);
}
public
function
destroyObject
(
PhabricatorDestructionEngine
$engine
,
$object
)
{
$table
=
new
AlmanacProperty
();
$conn_w
=
$table
->
establishConnection
(
'w'
);
queryfx
(
$conn_w
,
'DELETE FROM %T WHERE objectPHID = %s'
,
$table
->
getTableName
(),
$object
->
getPHID
());
}
}
Event Timeline
Log In to Comment