class Illuminate / Notifications / Messages / SimpleMessage

SimpleMessage

Properties

public

$level string

The "level" of the notification (info, success, error).

Default: 'info'
public

$subject string

The subject of the notification.

Default: null
public

$greeting string

The notification's greeting.

Default: null
public

$salutation string

The notification's salutation.

Default: null
public

$introLines array

The "intro" lines of the notification.

Default: []
public

$outroLines array

The "outro" lines of the notification.

Default: []
public

$actionText string

The text / label for the action.

Default: null
public

$actionUrl string

The action URL.

Default: null
public

$mailer string

The name of the mailer that should send the notification.

Default: null

Methods

public

success ( ) : $this

Indicate that the notification gives information about a successful operation.

public

error ( ) : $this

Indicate that the notification gives information about an error.

public

level ( $level ) : $this

Set the "level" of the notification (success, error, etc.).

Parameters

  • $level string
public

subject ( $subject ) : $this

Set the subject of the notification.

Parameters

  • $subject string
public

greeting ( $greeting ) : $this

Set the greeting of the notification.

Parameters

  • $greeting string
public

salutation ( $salutation ) : $this

Set the salutation of the notification.

Parameters

  • $salutation string
public

line ( $line ) : $this

Add a line of text to the notification.

Parameters

  • $line mixed
public

lineIf ( $boolean , $line ) : $this

Add a line of text to the notification if the given condition is true.

Parameters

  • $boolean bool
  • $line mixed
public

lines ( $lines ) : $this

Add lines of text to the notification.

Parameters

  • $lines iterable
public

linesIf ( $boolean , $lines ) : $this

Add lines of text to the notification if the given condition is true.

Parameters

  • $boolean bool
  • $lines iterable
public

with ( $line ) : $this

Add a line of text to the notification.

Parameters

  • $line mixed
protected

formatLine ( $line ) : Htmlable |string

Format the given line of text.

Parameters

public

action ( $text , $url ) : $this

Configure the "call to action" button.

Parameters

  • $text string
  • $url string
public

mailer ( $mailer ) : $this

Set the name of the mailer that should send the notification.

Parameters

  • $mailer string
public

toArray ( ) : array

Get an array representation of the message.