MCPcopy
hub / github.com/urllib3/urllib3 / sendall

Method sendall

src/urllib3/util/ssltransport.py:101–109  ·  view source on GitHub ↗
(self, data: bytes, flags: int = 0)

Source from the content-addressed store, hash-verified

99 return self.read(nbytes, buffer)
100
101 def sendall(self, data: bytes, flags: int = 0) -> None:
102 if flags != 0:
103 raise ValueError("non-zero flags not allowed in calls to sendall")
104 count = 0
105 with memoryview(data) as view, view.cast("B") as byte_view:
106 amount = len(byte_view)
107 while count < amount:
108 v = self.send(byte_view[count:])
109 count += v
110
111 def send(self, data: bytes, flags: int = 0) -> int:
112 if flags != 0:

Calls 1

sendMethod · 0.95