Add exists function to test for existance of key.