searches for $key in $values keys and returns the associated value.
If it doesn't exist, it will return the $default value if it is not null. Otherwise a
TokenNotFoundException will be thrown
Parameters
- $key
- the value to look for
- $values
- the availables values
- $default
- the default value to return if the $key is not found
Returns
mixed
the corresponding value
Throws
TokenNotFoundException