def __SendDataPart(data, connection):
 deprecated('call to deprecated function __SendDataPart')
 if isinstance(data, str):
  connection.send(data)
  return
 elif ElementTree.iselement(data):
  connection.send(ElementTree.tostring(data))
  return
 elif hasattr(data, 'read'):
  while 1:
   binarydata = data.read(100000)
   if (binarydata == ''):
    break
   connection.send(binarydata)
  return
 else:
  connection.send(str(data))
  return

def __SendDataPart ( data , connection ) : deprecated ( 'call to deprecated function __SendDataPart' ) if isinstance ( data , str ) : connection . send ( data ) return elif ElementTree . iselement ( data ) : connection . send ( ElementTree . tostring ( data ) ) return elif hasattr ( data , 'read' ) : while 1 : binarydata = data . read ( 100000 ) if ( binarydata == '' ) : break connection . send ( binarydata ) return else : connection . send ( str ( data ) ) return
this method is deprecated .