Reads an environment variable from the system environment and converts it to the specified type.
Return
an Optional containing the value of the environment variable, or empty if the variable is not set
Parameters
the name of the environment variable
the type to convert the value to