public function __get($name)Inherited
$name |
wild |
public function __set($name, $value)Inherited
$name | ||
$value |
wild |
public function current()Inherited
wild |
public function key()Inherited
wild |
public function next()Inherited
wild |
public function rewind()Inherited
wild |
public function valid()Inherited
wild |
private function throwOnAttemptedIteration()Inherited
wild |
public function getPhobjectClassConstant($key, $byte_limit)Inherited
Read the value of a class constant.
This is the same as just typing self::CONSTANTNAME, but throws a more useful message if the constant is not defined and allows the constant to be limited to a maximum length.
string | $key | Name of the constant. |
int|null | $byte_limit | Maximum number of bytes permitted in the value. |
string | Value of the constant. |
public function setMailTags($mail_tags)
array | $mail_tags |
wild |
public function getMailTags()
wild |
public function setNotifyAuthor($notify_author)
$notify_author |
wild |
public function getNotifyAuthor()
wild |
public function setRelatedPHIDs($phids)
array | $phids |
wild |
public function setSubscribedPHIDs($phids)
array | $phids |
wild |
public function setPrimaryObjectPHID($phid)
$phid |
wild |
public function setUnexpandablePHIDs($unexpandable_phids)
array | $unexpandable_phids |
wild |
public function getUnexpandablePHIDs()
wild |
public function setStoryType($story_type)
$story_type |
wild |
public function setStoryData($data)
array | $data |
wild |
public function setStoryTime($time)
$time |
wild |
public function setStoryAuthorPHID($phid)
$phid |
wild |
public function setMailRecipientPHIDs($phids)
array | $phids |
wild |
public function publish()
wild |
private function insertNotifications($chrono_key, $subscribed_phids)
$chrono_key | ||
array | $subscribed_phids |
wild |
private function sendNotification($chrono_key, $subscribed_phids)
$chrono_key | ||
array | $subscribed_phids |
wild |
private function filterSubscribedPHIDs($phids)
Remove PHIDs who should not receive notifications from a subscriber list.
list<phid> | $phids | List of potential subscribers. |
list<phid> | List of actual subscribers. |
private function expandRecipients($phids)
array | $phids |
wild |
private function generateChronologicalKey()
We generate a unique chronological key for each story type because we want to be able to page through the stream with a cursor (i.e., select stories after ID = X) so we can efficiently perform filtering after selecting data, and multiple stories with the same ID make this cumbersome without putting a bunch of logic in the client. We could use the primary key, but that would prevent publishing stories which happened in the past. Since it's potentially useful to do that (e.g., if you're importing another data source) build a unique key for each story which has chronological ordering.
string | A unique, time-ordered key which identifies the story. |