move functions about environment to class environment