summaryrefslogtreecommitdiffstats
path: root/ipalib/cli.py
diff options
context:
space:
mode:
authorJason Gerard DeRose <jderose@redhat.com>2008-08-14 05:46:20 +0000
committerJason Gerard DeRose <jderose@redhat.com>2008-08-14 05:46:20 +0000
commitba8d32a110f3dc96b091df9a2520f60c99ac26ba (patch)
treeb6161b299992f0b15b572430bdf210a67c10c527 /ipalib/cli.py
parentd95133b66f64a2e4f1c8aafa5ff9183c6acfe9a7 (diff)
downloadfreeipa-ba8d32a110f3dc96b091df9a2520f60c99ac26ba.tar.gz
freeipa-ba8d32a110f3dc96b091df9a2520f60c99ac26ba.tar.xz
freeipa-ba8d32a110f3dc96b091df9a2520f60c99ac26ba.zip
150: NameSpace.__iter__() now iterates through the names, not the members; added NameSpace.__call__() method which iterates through the members; NameSpace no longer requires members to be Proxy instances; updated unit tests and affected code; cleaned up NameSpace docstrings and switch to epydoc param docstrings
Diffstat (limited to 'ipalib/cli.py')
-rw-r--r--ipalib/cli.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/ipalib/cli.py b/ipalib/cli.py
index d17d12bc..8f09e90c 100644
--- a/ipalib/cli.py
+++ b/ipalib/cli.py
@@ -65,7 +65,7 @@ class CLI(object):
def print_commands(self):
print 'Available Commands:'
- for cmd in self.api.cmd:
+ for cmd in self.api.cmd():
print ' %s %s' % (
to_cli(cmd.name).ljust(self.mcl),
cmd.doc,
@@ -84,7 +84,7 @@ class CLI(object):
api.register(help)
api.finalize()
def d_iter():
- for cmd in api.cmd:
+ for cmd in api.cmd():
yield (to_cli(cmd.name), cmd)
self.__d = dict(d_iter())