From 3cfbdf0e60c94733c0a79e94bdf8627afc6bb2a4 Mon Sep 17 00:00:00 2001 From: Ted Ross Date: Tue, 21 Sep 2010 21:48:41 +0000 Subject: QMFv2 Additions: - QMFv2 schema encoding completed - Schema queries handled by the agent and initiated by the console by user request - Full query support with predicates evaluated on the agent (regex not yet implemented) - Agent filtering in the console - Agent aging in the console - Unit tests git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@999662 13f79535-47bb-0310-9956-ffa450edef68 --- cpp/bindings/qmf2/python/qmf2.py | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'cpp/bindings/qmf2/python/qmf2.py') diff --git a/cpp/bindings/qmf2/python/qmf2.py b/cpp/bindings/qmf2/python/qmf2.py index f3ece32866..285b47ebbe 100644 --- a/cpp/bindings/qmf2/python/qmf2.py +++ b/cpp/bindings/qmf2/python/qmf2.py @@ -54,6 +54,11 @@ SEV_NOTICE = cqmf2.SEV_NOTICE SEV_INFORM = cqmf2.SEV_INFORM SEV_DEBUG = cqmf2.SEV_DEBUG +QUERY_OBJECT = cqmf2.QUERY_OBJECT +QUERY_OBJECT_ID = cqmf2.QUERY_OBJECT_ID +QUERY_SCHEMA = cqmf2.QUERY_SCHEMA +QUERY_SCHEMA_ID = cqmf2.QUERY_SCHEMA_ID + #=================================================================================================== # EXCEPTIONS @@ -153,7 +158,7 @@ class ConsoleSession(object): def setAgentFilter(self, filt): """ """ - self.setAgentFilter(filt) + self._impl.setAgentFilter(filt) def open(self): """ @@ -321,6 +326,12 @@ class Agent(object): dataList.append(Data(result.getData(i))) return dataList + def loadSchemaInfo(self, timeout=30): + """ + """ + dur = cqpid.Duration(cqpid.Duration.SECOND.getMilliseconds() * timeout) + self._impl.querySchema(dur) + def getPackages(self): """ """ @@ -457,7 +468,7 @@ class Data(object): result = agent.callMethod(name, argmap, addr, dur) ## - ## If the agent sent an exception, raise it in a QmfAgentExeption. + ## If the agent sent an exception, raise it in a QmfAgentException. ## if result.getType() == cqmf2.CONSOLE_EXCEPTION: exdata = result.getData(0) -- cgit v1.2.1