class_docstr: Interface for stream protocol.
  
  The user should implement this interface.  They can inherit from
  this class but don't need to.  The implementations here do
  nothing (they don't raise exceptions).
  
  When the user wants to requests a transport, they pass a protocol
  factory to a utility function (e.g., EventLoop.create_connection()).
  
  When the connection is made successfully, connection_made() is
  called with a suitable transport object.  Then data_received()
  will be called 0 or more times with data (bytes) received from the
  transport; finally, connection_lost() will be called exactly once
  with either an exception object or None as an argument.
  
  State machine of calls:
  
    start -> CM [-> DR*] [-> ER?] -> CL -> end
  
  * CM: connection_made()
  * DR: data_received()
  * ER: eof_received()
  * CL: connection_lost()
class_docstr_tok: ["Interface","for","stream","protocol",".","The","user","should","implement","this","interface",".","They","can","inherit","from","this","class","but","do","n't","need","to",".","The","implementations","here","do","nothing","(","they","do","n't","raise","exceptions",")",".","When","the","user","wants","to","requests","a","transport",",","they","pass","a","protocol","factory","to","a","utility","function","(","e.g.",",","EventLoop.create_connection","(",")",")",".","When","the","connection","is","made","successfully",",","connection_made","(",")","is","called","with","a","suitable","transport","object",".","Then","data_received","(",")","will","be","called","0","or","more","times","with","data","(","bytes",")","received","from","the","transport",";","finally",",","connection_lost","(",")","will","be","called","exactly","once","with","either","an","exception","object","or","None","as","an","argument",".","State","machine","of","calls",":","start","-",">","CM","[","-",">","DR","*","]","[","-",">","ER","?","]","-",">","CL","-",">","end","*","CM",":","connection_made","(",")","*","DR",":","data_received","(",")","*","ER",":","eof_received","(",")","*","CL",":","connection_lost","(",")"]
docstr: Called when some data is received.
  
  The argument is a bytes object.
docstr_tok: ["Called","when","some","data","is","received",".","The","argument","is","a","bytes","object","."]
code: def data_received(self, data):
      """Called when some data is received.
  
      The argument is a bytes object.
      """
  
label_desc: Use image node_id 1 for calling the Protocol obj's underlying member method code with example usage: obj.data_received(data) without return types