You are here

TextimageTokenException.php in Textimage 8.4

Same filename and directory in other branches
  1. 8.3 src/TextimageTokenException.php

Namespace

Drupal\textimage

File

src/TextimageTokenException.php
View source
<?php

namespace Drupal\textimage;


/**
 * Exception thrown by Textimage factory on token processing failure.
 */
class TextimageTokenException extends \Exception {

  /**
   * The failing token.
   *
   * @var string
   */
  protected $token;

  /**
   * Constructs a TextimageImagerTokenException object.
   */
  public function __construct($token, \Exception $previous = NULL) {
    parent::__construct("Textimage token {$token} could not be resolved.", 0, $previous);
    $this->token = $token;
  }

  /**
   * Gets failing token.
   */
  public function getToken() {
    return $this->token;
  }

}

Classes

Namesort descending Description
TextimageTokenException Exception thrown by Textimage factory on token processing failure.