__init__.py 文件源码

python
阅读 23 收藏 0 点赞 0 评论 0

项目:girder_worker 作者: girder 项目源码 文件源码
def write(self, n=65536):
        """
        Called when it is detected the output side of this connector is ready
        to write. Reads (potentially blocks) at most n bytes and writes them to
        the output ends of this connector. If no bytes could be read, the connector
        is closed.

        :param n The maximum number of bytes to write.
        :type n int
        :returns: The actual number of bytes written.
        """
        buf = self.input.read(n)

        if buf:
            return self.output.write(buf)
        else:
            self.close()

        return 0
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号