Integrate __getitem__ with IPython tab completion.
Use the IPython _ipython_key_completions_ to provide completion with the __getitem__ attribute
@@ -217,6 +217,9 @@ class ClosedNamespace(object):
def __dir__(self):
return list(self._ClosedNamespace__uris)
+ def _ipython_key_completions_(self):
+ return dir(self)
+
class _RDFNamespace(ClosedNamespace):
"""
Closed namespace for RDF terms
