Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F105929815
DarkConsoleEventPluginAPI.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, Mar 20, 21:44
Size
536 B
Mime Type
text/x-php
Expires
Sat, Mar 22, 21:44 (2 d)
Engine
blob
Format
Raw Data
Handle
25076015
Attached To
rPH Phabricator
DarkConsoleEventPluginAPI.php
View Options
<?php
final
class
DarkConsoleEventPluginAPI
extends
PhabricatorEventListener
{
private
static
$events
=
array
();
private
static
$discardMode
=
false
;
public
static
function
enableDiscardMode
()
{
self
::
$discardMode
=
true
;
}
public
static
function
getEvents
()
{
return
self
::
$events
;
}
public
function
register
()
{
$this
->
listen
(
PhabricatorEventType
::
TYPE_ALL
);
}
public
function
handleEvent
(
PhutilEvent
$event
)
{
if
(
self
::
$discardMode
)
{
return
;
}
self
::
$events
[]
=
$event
;
}
}
Event Timeline
Log In to Comment