add method for retrieving values out of JS context