Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F92648578
PhabricatorCalendarEventHeraldAdapter.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
Fri, Nov 22, 09:15
Size
1 KB
Mime Type
text/x-php
Expires
Sun, Nov 24, 09:15 (2 d)
Engine
blob
Format
Raw Data
Handle
22478075
Attached To
rPH Phabricator
PhabricatorCalendarEventHeraldAdapter.php
View Options
<?php
final
class
PhabricatorCalendarEventHeraldAdapter
extends
HeraldAdapter
{
private
$object
;
public
function
getAdapterApplicationClass
()
{
return
'PhabricatorCalendarApplication'
;
}
public
function
getAdapterContentDescription
()
{
return
pht
(
'React to events being created or updated.'
);
}
protected
function
newObject
()
{
return
new
PhabricatorCalendarEvent
();
}
public
function
isTestAdapterForObject
(
$object
)
{
return
(
$object
instanceof
PhabricatorCalendarEvent
);
}
public
function
getAdapterTestDescription
()
{
return
pht
(
'Test rules which run when an event is created or updated.'
);
}
public
function
setObject
(
$object
)
{
$this
->
object
=
$object
;
return
$this
;
}
public
function
getObject
()
{
return
$this
->
object
;
}
public
function
getAdapterContentName
()
{
return
pht
(
'Calendar Events'
);
}
public
function
supportsRuleType
(
$rule_type
)
{
switch
(
$rule_type
)
{
case
HeraldRuleTypeConfig
::
RULE_TYPE_GLOBAL
:
case
HeraldRuleTypeConfig
::
RULE_TYPE_PERSONAL
:
return
true
;
case
HeraldRuleTypeConfig
::
RULE_TYPE_OBJECT
:
default
:
return
false
;
}
}
public
function
getRepetitionOptions
()
{
return
array
(
HeraldRepetitionPolicyConfig
::
EVERY
,
HeraldRepetitionPolicyConfig
::
FIRST
,
);
}
public
function
getHeraldName
()
{
return
$this
->
getObject
()->
getMonogram
();
}
}
Event Timeline
Log In to Comment