示例#1
0
	def write(self, str):
		if len(str) == 0: return
		if str[-1] != '\n':
			self.buf.append (str)
		else:
			self.buf.append (str[0:-1])
			host.log("".join (self.buf))
			self.buf = [] 
示例#2
0
 def write(self, str):
     if len(str) == 0: return
     if str[-1] != '\n':
         self.buf.append(str)
     else:
         self.buf.append(str[0:-1])
         host.log("".join(self.buf))
         self.buf = []
示例#3
0
	def write(self, str):
		if len(str) == 0: return
		self.buf += str
		if str[-1] == '\n':
			host.log(self.name + ': ' + self.buf[0:-1])
			self.buf = ''
示例#4
0
 def write(self, str):
     if len(str) == 0: return
     self.buf += str
     if str[-1] == '\n':
         host.log(self.name + ': ' + self.buf[0:-1])
         self.buf = ''