[ Index ]

PHP Cross Reference of phpBB-3.2.8-deutsch

title

Body

[close]

/phpbb/notification/type/ -> base.php (summary)

This file is part of the phpBB Forum Software package.

Copyright: (c) phpBB Limited
License: GNU General Public License, version 2 (GPL-2.0)
File Size: 577 lines (14 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 28 functions

  __construct()
  set_notification_manager()
  set_initial_data()
  __get()
  __set()
  __toString()
  get_data()
  set_data()
  create_insert_array()
  get_insert_array()
  create_update_array()
  mark_read()
  mark_unread()
  get_redirect_url()
  prepare_for_display()
  get_unsubscribe_url()
  get_style_class()
  get_avatar()
  get_reference()
  get_forum()
  get_reason()
  get_load_special()
  load_special()
  is_available()
  pre_create_insert_array()
  check_user_notification_options()
  mark()
  get_authorised_recipients()

Functions
Functions that are not part of a class:

__construct(\phpbb\db\driver\driver_interface $db, \phpbb\language\language $language, \phpbb\user $user, \phpbb\auth\auth $auth, $phpbb_root_path, $php_ext, $user_notifications_table)   X-Ref
Notification Type Base Constructor

param: \phpbb\db\driver\driver_interface $db
param: \phpbb\language\language          $language
param: \phpbb\user                       $user
param: \phpbb\auth\auth                  $auth
param: string                            $phpbb_root_path
param: string                            $php_ext
param: string                            $user_notifications_table

set_notification_manager(\phpbb\notification\manager $notification_manager)   X-Ref
Set notification manager (required)

param: \phpbb\notification\manager $notification_manager

set_initial_data($data = array()   X-Ref
Set initial data from the database

param: array $data Row directly from the database

__get($name)   X-Ref
Magic method to get data from this notification

param: mixed $name
return: mixed

__set($name, $value)   X-Ref
Magic method to set data on this notification

param: mixed $name
param: mixed $value
return: null

__toString()   X-Ref
Magic method to get a string of this notification

Primarily for testing

return: mixed

get_data($name)   X-Ref
Get special data (only important for the classes that extend this)

param: string $name Name of the variable to get
return: mixed

set_data($name, $value)   X-Ref
Set special data (only important for the classes that extend this)

param: string $name Name of the variable to set
param: mixed $value Value to set to the variable
return: mixed

create_insert_array($type_data, $pre_create_data = array()   X-Ref
{@inheritdoc}


get_insert_array()   X-Ref
{@inheritdoc}


create_update_array($type_data)   X-Ref
Function for preparing the data for update in an SQL query
(The service handles insertion)

param: array $type_data Data unique to this notification type
return: array Array of data ready to be updated in the database

mark_read($return = false)   X-Ref
Mark this item read

param: bool $return True to return a string containing the SQL code to update this item, False to execute it (Default: False)
return: string|null If $return is False, nothing will be returned, else the sql code to update this item

mark_unread($return = false)   X-Ref
Mark this item unread

param: bool $return True to return a string containing the SQL code to update this item, False to execute it (Default: False)
return: string|null If $return is False, nothing will be returned, else the sql code to update this item

get_redirect_url()   X-Ref
{inheritDoc}


prepare_for_display()   X-Ref
Prepare to output the notification to the template

return: array Template variables

get_unsubscribe_url($method = false)   X-Ref
URL to unsubscribe to this notification (fall back)

param: string|bool $method Method name to unsubscribe from (email|jabber|etc), False to unsubscribe from all notifications for this item
return: false

get_style_class()   X-Ref
Get the CSS style class of the notification (fall back)

return: string

get_avatar()   X-Ref
Get the user's avatar (fall back)

return: string

get_reference()   X-Ref
Get the reference of the notifcation (fall back)

return: string

get_forum()   X-Ref
Get the forum of the notification reference (fall back)

return: string

get_reason()   X-Ref
Get the reason for the notifcation (fall back)

return: string

get_load_special()   X-Ref
Get the special items to load (fall back)

return: array

load_special($data, $notifications)   X-Ref
Load the special items (fall back)

param: array $data
param: array $notifications

is_available()   X-Ref
Is available (fall back)

return: bool

pre_create_insert_array($type_data, $notify_users)   X-Ref
Pre create insert array function (fall back)

param: array $type_data
param: array $notify_users
return: array

check_user_notification_options($user_ids = false, $options = array()   X-Ref
Find the users who want to receive notifications (helper)

param: array|bool $user_ids User IDs to check if they want to receive notifications
param: array      $options
return: array

mark($unread = true, $return = false)   X-Ref
Mark this item read/unread helper

param: bool $unread Unread (True/False) (Default: False)
param: bool $return True to return a string containing the SQL code to update this item, False to execute it (Default: False)
return: string|null If $return is False, nothing will be returned, else the sql code to update this item

get_authorised_recipients($users, $forum_id, $options, $sort = false)   X-Ref
Get a list of users that are authorised to receive notifications

param: array $users Array of users that have subscribed to a notification
param: int $forum_id Forum ID of the forum
param: array $options Array of notification options
param: bool $sort Whether the users array should be sorted. Default: false
return: array Array of users that are authorised recipients



Generated: Sat Oct 26 11:28:42 2019 Cross-referenced by PHPXref 0.7.1