def METHOD_NAME(self, data):
    """Send data to remote."""
    # NB: socket.ssl needs a "sendall" method to match socket objects.
    bytecount = len(data)
    while bytecount > 0:
        sent = self.sslobj.write(data)
        if sent == bytecount:
            break  # avoid copy
        data = data[sent:]
        bytecount = bytecount - sent