def close(self):
if self.pinger:<EOL><INDENT>self.pinger.cancel()<EOL>self.pinger = None<EOL><DEDENT>if getattr(self, '<STR_LIT>', None):<EOL><INDENT>self.protocol.close()<EOL><DEDENT>
Close the connection