" )
===== tools/python/xen/sv/util.py 1.10 vs edited =====
--- 1.10/tools/python/xen/sv/util.py 2004-08-16 22:04:37 +09:00
+++ edited/tools/python/xen/sv/util.py 2005-05-19 02:45:57 +09:00
@@ -10,14 +10,14 @@ def getDomInfoHash( domain ):
domInfoHash = sxp2hash( server.xend_domain( domain ) )
domInfoHash['dom'] = domain
except:
- domInfoHash['name'] = "Error getting domain details"
+ domInfoHash['name'] = "Error getting domain details"
return domInfoHash
def sxp2hash( s ):
sxphash = {}
for child in sxp.children( s ):
- if isinstance( child, types.ListType ) and len( child ) > 1:
+ if isinstance( child, types.ListType ) and len( child ) > 1:
if isinstance( child[1], types.ListType ) and len( child ) > 1:
sxphash[ child[0] ] = sxp2hash( child[1] )
else:
@@ -38,7 +38,7 @@ def hash2sxp( h ):
hashsxp = []
for (key, item) in h.items():
- hashsxp.append( [key, item] )
+ hashsxp.append( [key, item] )
return hashsxp
===== tools/python/xen/web/SrvBase.py 1.3 vs edited =====
--- 1.3/tools/python/xen/web/SrvBase.py 2005-04-27 23:04:43 +09:00
+++ edited/tools/python/xen/web/SrvBase.py 2005-05-19 02:47:31 +09:00
@@ -15,7 +15,7 @@ import httpserver
def uri_pathlist(p):
"""Split a path into a list.
- p path
+ p path
return list of path elements
"""
l = []
@@ -36,7 +36,7 @@ class SrvBase(resource.Resource):
"""Get the method for an operation.
For operation 'foo' looks for 'op_foo'.
- op operation name
+ op operation name
returns method or None
"""
op_method_name = 'op_' + op
@@ -52,7 +52,7 @@ class SrvBase(resource.Resource):
and an HTML string otherwise (or list).
Methods may also return a ThreadRequest (for incomplete processing).
- req request
+ req request
"""
op = req.args.get('op')
if op is None or len(op) != 1:
===== tools/python/xen/web/SrvDir.py 1.3 vs edited =====
--- 1.3/tools/python/xen/web/SrvDir.py 2005-04-27 23:04:43 +09:00
+++ edited/tools/python/xen/web/SrvDir.py 2005-05-19 02:47:54 +09:00
@@ -22,7 +22,7 @@ class SrvConstructor:
"""Create a constructor. It is assumed that the class
should be imported as 'from xen.xend.server.klass import klass'.
- klass name of its class
+ klass name of its class
"""
self.klass = klass
self.obj = None
===== tools/python/xen/xend/EventServer.py 1.9 vs edited =====
--- 1.9/tools/python/xen/xend/EventServer.py 2005-04-23 02:07:04 +09:00
+++ edited/tools/python/xen/xend/EventServer.py 2005-05-19 03:02:47 +09:00
@@ -71,7 +71,7 @@ class EventServer:
for the '?'. A subscription like 'a.b.c.*' ending in '*' matches
any event type with the same prefix, 'a.b.c' in this case.
- event event name
+ event event name
handler event handler fn(event, val)
"""
try:
@@ -87,7 +87,7 @@ class EventServer:
def unsubscribe_all(self, event=None):
"""Unsubscribe all handlers for a given event, or all handlers.
- event event (optional)
+ event event (optional)
"""
try:
self.lock.acquire()
@@ -101,7 +101,7 @@ class EventServer:
def unsubscribe(self, event, handler):
"""Unsubscribe a given event and handler.
- event event
+ event event
handler handler
"""
try:
@@ -118,8 +118,8 @@ class EventServer:
"""Inject an event. Handlers for it are called if running, otherwise
it is queued.
- event event type
- val event value
+ event event type
+ val event value
"""
try:
self.lock.acquire()
@@ -146,9 +146,9 @@ class EventServer:
"""Call the handlers for an event.
It is safe for handlers to subscribe or unsubscribe.
- key key for handler list
- event event type
- val event value
+ key key for handler list
+ event event type
+ val event value
"""
try:
self.lock.acquire()
@@ -171,8 +171,8 @@ class EventServer:
def call_query_handlers(self, event, val):
"""Call regex handlers for events matching 'event' that end in '?'.
- event event type
- val event value
+ event event type
+ val event value
"""
dot_idx = event.rfind(self.DOT)
if dot_idx == -1:
@@ -184,8 +184,8 @@ class EventServer:
def call_star_handlers(self, event, val):
"""Call regex handlers for events matching 'event' that end in '*'.
- event event type
- val event value
+ event event type
+ val event value
"""
etype = string.split(event, self.DOT)
for i in range(len(etype), 0, -1):
===== tools/python/xen/xend/PrettyPrint.py 1.6 vs edited =====
--- 1.6/tools/python/xen/xend/PrettyPrint.py 2005-05-17 18:03:48 +09:00
+++ edited/tools/python/xen/xend/PrettyPrint.py 2005-05-19 02:59:42 +09:00
@@ -273,9 +273,9 @@ class SXPPrettyPrinter(PrettyPrinter):
def prettyprint(sxpr, out=sys.stdout, width=80):
"""Prettyprint an SXP form.
- sxpr s-expression
- out destination
- width maximum output width
+ sxpr s-expression
+ out destination
+ width maximum output width
"""
if isinstance(sxpr, types.ListType):
pp = SXPPrettyPrinter(width=width)
===== tools/python/xen/xend/XendClient.py 1.48 vs edited =====
--- 1.48/tools/python/xen/xend/XendClient.py 2005-05-13 00:04:55 +09:00
+++ edited/tools/python/xen/xend/XendClient.py 2005-05-19 02:58:16 +09:00
@@ -256,9 +256,9 @@ class Xend:
{'op' : 'cpu_sedf_set',
'period' : period,
'slice' : slice,
- 'latency' : latency,
- 'extratime' : extratime,
- 'weight' : weight })
+ 'latency' : latency,
+ 'extratime' : extratime,
+ 'weight' : weight })
def xend_domain_maxmem_set(self, id, memory):
return self.xendPost(self.domainurl(id),
===== tools/python/xen/xend/XendDomain.py 1.75 vs edited =====
--- 1.75/tools/python/xen/xend/XendDomain.py 2005-05-19 00:33:39 +09:00
+++ edited/tools/python/xen/xend/XendDomain.py 2005-05-19 03:13:20 +09:00
@@ -164,7 +164,7 @@ class XendDomain:
def sync_domain(self, dom):
"""Sync info for a domain to disk.
- dom domain id (string)
+ dom domain id (string)
"""
self.db.save(dom, self.domain_db[dom])
@@ -658,7 +658,7 @@ class XendDomain:
def domain_cpu_sedf_set(self, id, period, slice, latency, extratime, weight):
"""Set Simple EDF scheduler parameters for a domain.
"""
- dominfo = self.domain_lookup(id)
+ dominfo = self.domain_lookup(id)
try:
return xc.sedf_domain_set(dominfo.dom, period, slice, latency, extratime, weight)
except Exception, ex:
===== tools/python/xen/xend/encode.py 1.7 vs edited =====
--- 1.7/tools/python/xen/xend/encode.py 2005-05-18 07:28:24 +09:00
+++ edited/tools/python/xen/xend/encode.py 2005-05-19 02:54:54 +09:00
@@ -82,7 +82,7 @@ def encode_data(d):
"""Encode some data for HTTP transport.
The encoding used is stored in 'Content-Type' in the headers.
- d data - sequence of tuples or dictionary
+ d data - sequence of tuples or dictionary
returns a 2-tuple of the headers and the encoded data
"""
val = ({}, None)
===== tools/python/xen/xend/sxp.py 1.16 vs edited =====
--- 1.16/tools/python/xen/xend/sxp.py 2005-05-18 07:28:24 +09:00
+++ edited/tools/python/xen/xend/sxp.py 2005-05-19 02:54:13 +09:00
@@ -707,7 +707,7 @@ def all_from_string(str):
def parse(io):
"""Completely parse all input from 'io'.
- io input file object
+ io input file object
returns list of values, None if incomplete
raises ParseError on parse error
"""
===== tools/python/xen/xend/server/SrvDomain.py 1.38 vs edited =====
--- 1.38/tools/python/xen/xend/server/SrvDomain.py 2005-05-13 00:04:55 +09:00
+++ edited/tools/python/xen/xend/server/SrvDomain.py 2005-05-19 02:49:18 +09:00
@@ -110,9 +110,9 @@ class SrvDomain(SrvDir):
[['dom', 'str'],
['period', 'int'],
['slice', 'int'],
- ['latency', 'int'],
- ['extratime', 'int'],
- ['weight', 'int']])
+ ['latency', 'int'],
+ ['extratime', 'int'],
+ ['weight', 'int']])
val = fn(req.args, {'dom': self.dom.id})
return val
===== tools/python/xen/xm/main.py 1.52 vs edited =====
--- 1.52/tools/python/xen/xm/main.py 2005-05-13 00:04:56 +09:00
+++ edited/tools/python/xen/xm/main.py 2005-05-19 02:53:11 +09:00
@@ -142,8 +142,8 @@ class Xm:
"""
self.name = args[0]
if len(args) < 2:
- args.append('help')
- help = self.helparg(args)
+ args.append('help')
+ help = self.helparg(args)
p = self.getprog(args[1], self.unknown)
if help or len(args) < 2:
p.help(args[1:])
@@ -646,10 +646,10 @@ class ProgSedf(Prog):
print "\nSet simple EDF parameters."
def main(self, args):
- if len(args) != 7: self.err("%s: Invalid argument(s)" % args[0])
- dom = args[1]
- v = map(int, args[2:7])
- server.xend_domain_cpu_sedf_set(dom, *v)
+ if len(args) != 7: self.err("%s: Invalid argument(s)" % args[0])
+ dom = args[1]
+ v = map(int, args[2:7])
+ server.xend_domain_cpu_sedf_set(dom, *v)
xm.prog(ProgSedf)