Copied!
CloneableInstantiable
Methods
public Maknz\Slack\Payload::__construct(array $attributes)
 

Instantiate a new payload.

  • param array $attributes
public static Maknz\Slack\Block::factory(array $attributes)
 

Create a Block element from a keyed array of attributes.

  • param array $attributes
  • return \Block
  • throws \InvalidArgumentException
public getAltText()
 

Get the alternative text for the image.

  • return string
public Maknz\Slack\Block::getBlockId()
 

Get the block identifier.

  • return string
public getTitle()
 

Get the image title.

  • return \Maknz\Slack\BlockElement\Text
public Maknz\Slack\Block::getType()
 

Get the block type.

  • return string
public getUrl()
 

Get the image URL.

  • return string
public setAltText( $text)
 

Set the alternative text for the image.

  • param mixed $text
  • return $this
public Maknz\Slack\Block::setBlockId( $blockId)
 

Set the block identifier.

  • param string $blockId
  • return $this
public setTitle( $title)
 

Set the image title.

  • param mixed $title
  • return $this
  • throws \InvalidArgumentException
public setUrl( $url)
 

Set the image URL.

  • param string $url
  • return $this
public toArray()
 

Convert the block to its array representation.

  • return array
Properties
protected $alt_text = NULL
 

The alternative text for the image.

  • var string
protected static $availableAttributes = ['image_url' => 'url', 'alt_text' => 'alt_text', 'title' => 'title', 'block_id' => 'block_id']
 

Internal attribute to property map.

  • var array
protected Maknz\Slack\Block::$block_id = NULL
 

Block identifier.

  • var string
protected $title = NULL
 

The image title.

  • var \Maknz\Slack\BlockElement\Text
protected $type = 'image'
 

Block type.

  • var string
protected $url = NULL
 

The image URL.

  • var string
Methods
protected Maknz\Slack\Payload::fillProperties(array $attributes) : self
 
  • param array $attributes
  • return $this
Properties
protected static $availableAttributes = ['image_url' => 'url', 'alt_text' => 'alt_text', 'title' => 'title', 'block_id' => 'block_id']
 

Internal attribute to property map.

  • var array
Methods
public static Maknz\Slack\Block::factory(array $attributes)
 

Create a Block element from a keyed array of attributes.

  • param array $attributes
  • return \Block
  • throws \InvalidArgumentException
© 2024 Bruce Wells
Search Namespaces \ Classes
Configuration