MCPcopy Create free account
hub / github.com/PerroEngine/Perro / poll_frame_event

Method poll_frame_event

perro_source/api_modules/perro_networking/src/tcp.rs:185–197  ·  view source on GitHub ↗
(&mut self, max_frame_bytes: usize)

Source from the content-addressed store, hash-verified

183 }
184
185 pub fn write_all(&mut self, bytes: &[u8]) -> NetResult<()> {
186 if !bytes.is_empty() {
187 self.enqueue_write(bytes.to_vec())?;
188 }
189 self.flush_pending().map(|_| ())
190 }
191
192 pub fn write_frame(&mut self, bytes: &[u8]) -> NetResult<()> {
193 let frame = encode_frame(bytes)?;
194 self.enqueue_write(frame)?;
195 self.flush_pending().map(|_| ())
196 }
197
198 pub fn write_handshake(&mut self, handshake: &NetHandshake) -> NetResult<()> {
199 self.write_frame(&handshake.encode()?)
200 }

Calls 4

is_heartbeat_pingFunction · 0.85
is_heartbeat_pongFunction · 0.85
poll_frameMethod · 0.80
peer_stringMethod · 0.45