This is an automatically generated e-mail. To reply, visit: http://reviewboard-openlmi.rhcloud.com/r/691/

On August 8th, 2013, 6:06 a.m. UTC, Michal Minar wrote:

cli/lmi/shell/LMIConnection.py (Diff revision 2)
def __init__(self, hostname, username="", password="", interactive=False, use_cache=True, \
142
    def __repr__(self):
shouldn't this be a __str__() ?
__repr__ should return representation, which could be used in python expression to reconstruct the object. If not possible, it should return some description enclosed with '<' and '>'.
Nope. Python doc: Called by the repr() built-in function and by string conversions (reverse quotes) to compute the “official” string representation of an object.

On August 8th, 2013, 6:06 a.m. UTC, Michal Minar wrote:

cli/lmi/shell/LMIInstance.py (Diff revision 2)
def references(self, **kwargs):
471
        return map(lambda ref: lmi_wrap_cim_instance(self._client, ref, ref.classname, \
470
        return map(lambda ref: lmi_wrap_cim_instance(self._conn, ref, ref.classname, \
in python 2, generator expression is more effective than map():
[lmi_write_cim_instance(...) for ... ]
OK.

- Peter


On August 8th, 2013, 5:30 a.m. UTC, Peter Hatina wrote:

Review request for OpenLMI Developers.
By Peter Hatina.

Updated Aug. 8, 2013, 5:30 a.m.

Repository: openlmi-tools

Description

By this patch, all the wrapper classes (LMINamespace, LMIClass, LMIInstance{Name}, LMIMethod) have now property "connection", which returns the former LMIConnection object retrieved by connect().

Diffs

  • cli/lmi/shell/LMIBaseObject.py (08d05513892c68388d76730652df1d07ced626f9)
  • cli/lmi/shell/LMIClass.py (5e8db27847d9ddefb7883946b8ae8fe65faf5eee)
  • cli/lmi/shell/LMIConnection.py (786fdd578b06873fe51528acaca575cde00133c7)
  • cli/lmi/shell/LMIInstance.py (af83f647b0037a259d0e5fdfefbd0176ead41dba)
  • cli/lmi/shell/LMIInstanceName.py (20440cb20af0671a927de547d3537f5206cd7a50)
  • cli/lmi/shell/LMIMethod.py (3a05740aab526f9cf3f35b2ae6d33e0555c5572f)
  • cli/lmi/shell/LMINamespace.py (72a5f4d88d370768fe58c9796cfc1c45b14ad036)
  • cli/lmi/shell/LMIUtil.py (370c073a22c2461428c066d019326d9941235679)

View Diff