PHP Class LaravelFCM\Request\Request

Inheritance: extends BaseRequest
Show file Open project: brozot/laravel-fcm

Protected Properties

Property Type Description
$data LaravelFCM\Message\PayloadData
$notification LaravelFCM\Message\PayloadNotification
$options LaravelFCM\Message\Options
$to string | array
$topic LaravelFCM\Message\Topics | null

Public Methods

Method Description
__construct ( $to, Options $options = null, PayloadNotification $notification = null, PayloadData $data = null, Topics $topic = null ) Request constructor.

Protected Methods

Method Description
buildBody ( ) : array Build the body for the request
getData ( ) : array | null get data transformed
getNotification ( ) : array | null get notification transformed
getOptions ( ) : array get Options transformed
getRegistrationIds ( ) : array | null get registrationIds transformed
getTo ( ) : array | null | string get to key transformed

Method Details

__construct() public method

Request constructor.
public __construct ( $to, Options $options = null, PayloadNotification $notification = null, PayloadData $data = null, Topics $topic = null )
$to
$options LaravelFCM\Message\Options
$notification LaravelFCM\Message\PayloadNotification
$data LaravelFCM\Message\PayloadData
$topic LaravelFCM\Message\Topics

buildBody() protected method

Build the body for the request
protected buildBody ( ) : array
return array

getData() protected method

get data transformed
protected getData ( ) : array | null
return array | null

getNotification() protected method

get notification transformed
protected getNotification ( ) : array | null
return array | null

getOptions() protected method

get Options transformed
protected getOptions ( ) : array
return array

getRegistrationIds() protected method

get registrationIds transformed
protected getRegistrationIds ( ) : array | null
return array | null

getTo() protected method

get to key transformed
protected getTo ( ) : array | null | string
return array | null | string

Property Details

$data protected property

protected PayloadData,LaravelFCM\Message $data
return LaravelFCM\Message\PayloadData

$notification protected property

protected PayloadNotification,LaravelFCM\Message $notification
return LaravelFCM\Message\PayloadNotification

$options protected property

protected Options,LaravelFCM\Message $options
return LaravelFCM\Message\Options

$to protected property

protected string|array $to
return string | array

$topic protected property

protected Topics,LaravelFCM\Message|null $topic
return LaravelFCM\Message\Topics | null