You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by ch...@apache.org on 2016/07/28 18:10:17 UTC

qpid-dispatch git commit: DISPATCH-462: fix Entity class names to print exact entity type

Repository: qpid-dispatch
Updated Branches:
  refs/heads/master 9cdabfc1d -> 417a06dfd


DISPATCH-462: fix Entity class names to print exact entity type


Project: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/repo
Commit: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/commit/417a06df
Tree: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/tree/417a06df
Diff: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/diff/417a06df

Branch: refs/heads/master
Commit: 417a06dfdaa464f2726f978c39deb307a6225019
Parents: 9cdabfc
Author: Chuck Rolke <cr...@redhat.com>
Authored: Thu Jul 28 14:07:41 2016 -0400
Committer: Chuck Rolke <cr...@redhat.com>
Committed: Thu Jul 28 14:07:41 2016 -0400

----------------------------------------------------------------------
 python/qpid_dispatch_internal/management/agent.py | 9 +++++++++
 1 file changed, 9 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/qpid-dispatch/blob/417a06df/python/qpid_dispatch_internal/management/agent.py
----------------------------------------------------------------------
diff --git a/python/qpid_dispatch_internal/management/agent.py b/python/qpid_dispatch_internal/management/agent.py
index d9c0382..c8ebf65 100644
--- a/python/qpid_dispatch_internal/management/agent.py
+++ b/python/qpid_dispatch_internal/management/agent.py
@@ -311,6 +311,9 @@ class PolicyEntity(EntityAdapter):
     def _identifier(self):
         return self.attributes.get('module')
 
+    def __str__(self):
+        return super(PolicyEntity, self).__str__().replace("Entity(", "PolicyEntity(")
+
 
 class VhostEntity(EntityAdapter):
     def create(self):
@@ -319,11 +322,17 @@ class VhostEntity(EntityAdapter):
     def _identifier(self):
         return self.attributes.get('id')
 
+    def __str__(self):
+        return super(VhostEntity, self).__str__().replace("Entity(", "VhostEntity(")
+
 
 class VhostStatsEntity(EntityAdapter):
     def _identifier(self):
         return self.attributes.get('id')
 
+    def __str__(self):
+        return super(VhostStatsEntity, self).__str__().replace("Entity(", "VhostStatsEntity(")
+
 
 def _host_port_name_identifier(entity):
     for attr in ['host', 'port', 'name']: # Set default values if need be


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org