You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@libcloud.apache.org by pq...@apache.org on 2009/12/31 03:31:18 UTC

svn commit: r894764 - /incubator/libcloud/trunk/libcloud/base.py

Author: pquerna
Date: Thu Dec 31 02:31:18 2009
New Revision: 894764

URL: http://svn.apache.org/viewvc?rev=894764&view=rev
Log:
Expose driver correctly, and improve the str(NodeLocation) to include country

Modified:
    incubator/libcloud/trunk/libcloud/base.py

Modified: incubator/libcloud/trunk/libcloud/base.py
URL: http://svn.apache.org/viewvc/incubator/libcloud/trunk/libcloud/base.py?rev=894764&r1=894763&r2=894764&view=diff
==============================================================================
--- incubator/libcloud/trunk/libcloud/base.py (original)
+++ incubator/libcloud/trunk/libcloud/base.py Thu Dec 31 02:31:18 2009
@@ -108,13 +108,14 @@
     """
     interface.implements(INodeImage)
     interface.classProvides(INodeImageFactory)
-    def __init__(self, id, name, country):
+    def __init__(self, id, name, country, driver):
         self.id = id
         self.name = name
         self.country = country
+        self.driver = driver
     def __repr__(self):
-        return (('<NodeLocation: id=%s, name=%s, driver=%s>')
-                % (self.id, self.name, self.driver.name))
+        return (('<NodeLocation: id=%s, name=%s, country=%s, driver=%s>')
+                % (self.id, self.name, self.country, self.driver.name))
 
 class Response(object):
     """