You are here

static function Notifications_Subscription::object_subscriptions in Notifications 7

Build subscriptions for array of objects and user account.

Return value

Notifications_Subscription_List

1 call to Notifications_Subscription::object_subscriptions()
notifications_notifications_subscription_list in ./notifications.module
Implementation of hook_notifications_subscription_list().

File

./notifications.subscription.inc, line 710
Drupal Notifications Framework - Default class file

Class

Notifications_Subscription
Common base for subscription type and subscription instance

Code

static function object_subscriptions($objects, $account) {
  $subscriptions = new Notifications_Subscription_List();
  foreach ($objects as $object) {
    if ($more = $object
      ->subscribe_options($account)) {
      $subscriptions
        ->add($more);
    }
  }
  return $subscriptions;
}