public static function dump($var, array $options = null)
    {
        if (Helpers::isHtmlMode()) {
            echo self::toHtml($var, $options);
        } elseif (self::detectColors()) {
            echo self::toTerminal($var, $options);
        } else {
            echo self::toText($var, $options);
        }

        return $var;
    }