def getStreamTags(self, encoding, optimizeTags=False, optimizeCompression=False): stream = StringIO.StringIO() if optimizeTags: tagListOptimizer(self.tags) for tag in self.tags: tag.write(stream, encoding) self.streamData = stream.getvalue() stream.close() return LrfStreamBase.getStreamTags(self, optimize=optimizeCompression)
def getStreamTags(self, encoding, optimizeTags=False, optimizeCompression=False): stream = io.BytesIO() if optimizeTags: tagListOptimizer(self.tags) for tag in self.tags: tag.write(stream, encoding) self.streamData = stream.getvalue() stream.close() return LrfStreamBase.getStreamTags(self, optimize=optimizeCompression)