MCPcopy Create free account
hub / github.com/ChrisFeldmeier/OpenCodeRust / next_id

Method next_id

crates/opencode-lsp/src/lib.rs:273–277  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

271 }
272
273 async fn next_id(&self) -> u64 {
274 let mut id = self.request_id.lock().await;
275 *id += 1;
276 *id
277 }
278
279 pub async fn request(&self, method: &str, params: Value) -> Result<Value, LspError> {
280 let id = self.next_id().await;

Callers 1

requestMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected