From f09e63101fdf71a796d3e8eb874f94a16541352e Mon Sep 17 00:00:00 2001 From: Nuno Santos Date: Fri, 5 Sep 2008 20:14:29 +0000 Subject: allow creation of objectId from first/second id components git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@692525 13f79535-47bb-0310-9956-ffa450edef68 --- python/qpid/management.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'python/qpid/management.py') diff --git a/python/qpid/management.py b/python/qpid/management.py index 99c902ab30..8d8339b2c6 100644 --- a/python/qpid/management.py +++ b/python/qpid/management.py @@ -72,9 +72,13 @@ class mgmtObject (object): class objectId(object): """ Object that represents QMF object identifiers """ - def __init__(self, codec): - self.first = codec.read_uint64() - self.second = codec.read_uint64() + def __init__(self, codec, first=0, second=0): + if codec: + self.first = codec.read_uint64() + self.second = codec.read_uint64() + else: + self.first = first + self.second = second def __cmp__(self, other): if other == None: -- cgit v1.2.1