public static function setBaseDirectory($directory)
    {
        if (!is_dir($directory))
            throw new \InvalidArgumentException('m\View\GenericView: Given string "'.$directory.'" is not a valid directory.');

        static::$_defaultDir = (string) rtrim($directory, DIRECTORY_SEPARATOR).DIRECTORY_SEPARATOR;
    }