public function contains(string $token): bool
    {
        $this->tokenize();
        return in_array($token, $this->tokens);
    }
public function contains(string $token): bool
    {
        $this->tokenize();
        return in_array($token, $this->tokens);
    }
public function contains ( string $ token ) : bool { $ this -> tokenize ( ) ; return in_array ( $ token , $ this -> tokens ) ; }
Returns true if the list contains the given token, otherwise false.

@param string $token The token you want to check for the existence of in the list.
@return bool true if the list contains the given token, otherwise false.
Returns true if the list contains the given token otherwise false .