MCPcopy Create free account
hub / github.com/MegEngine/MegFlow / wait_tx_closed

Method wait_tx_closed

flow-rs/src/channel/storage.rs:153–168  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

151 }
152
153 pub async fn wait_tx_closed(&self) {
154 let mut listener = None;
155 loop {
156 if self.is_closed() {
157 return;
158 }
159 match listener.take() {
160 None => {
161 listener = Some(self.tx_close_ops.listen());
162 }
163 Some(l) => {
164 l.await;
165 }
166 }
167 }
168 }
169}

Callers 2

test_closedFunction · 0.80
startMethod · 0.80

Calls 3

takeMethod · 0.80
listenMethod · 0.80
is_closedMethod · 0.45

Tested by 1

test_closedFunction · 0.64