Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/casouri/collab-mode
/ functions
Functions
852 in github.com/casouri/collab-mode
⨍
Functions
852
◇
Types & classes
667
↓ 5 callers
Method
mark_to_ins_or_del
If `live` is true, convert mark_live at `pos` with `text` to a ins op for the editor; if false, convert mark_dead at `pos` with `text` to a del op for
collab_mode/src/engine.rs:867
↓ 5 callers
Method
move_to_beg
Move cursor to the beginning of `iter`.
collab_mode/src/engine.rs:113
↓ 5 callers
Function
signIdentity
( keyCert: KeyCert, timestampOverride?: number, )
worker/src/auth.test.ts:48
↓ 5 callers
Method
site
(&self)
collab_mode/src/engine.rs:31
↓ 5 callers
Method
transform
* Apply transform next, returning a transform handle. * You can then apply more transformations, draw, or retrieve the output. * @param tran
worker/worker-configuration.d.ts:11672
↓ 5 callers
Method
write_allowed
Check if a host has write permission Always returns true for ourselves.
collab_mode/src/config_man.rs:337
↓ 4 callers
Method
apply_edit_instruction
Apply an EditInstruction to this mock document.
collab_mode/src/server/transcript_tests.rs:101
↓ 4 callers
Method
clear
* The **`console.clear()`** static method clears the console if possible. * * [MDN Reference](https://developer.mozilla.org/docs/Web/API/con
worker/worker-configuration.d.ts:111
↓ 4 callers
Method
contract_affected_range_right
(&mut self)
collab_mode/src/engine.rs:186
↓ 4 callers
Method
current_seq
Return the current global sequence number.
collab_mode/src/engine.rs:1341
↓ 4 callers
Method
extend_affected_range_right
(&mut self)
collab_mode/src/engine.rs:182
↓ 4 callers
Method
generate_undo_op_1
Generate undo or redo ops from the current undo tip. Although this function returns [FatOp]s, most of the field of the [FatOp] (seq, site_seq, etc) ar
collab_mode/src/engine.rs:1678
↓ 4 callers
Method
get_channel
( &self, host_id: ServerId, msg_tx: mpsc::Sender<webchannel::Message>, self_tx
collab_mode/src/server/tests/mod.rs:59
↓ 4 callers
Function
hash_der
Hash the binary DER file and return the hash in fingerprint format: each byte in uppercase hex, separated by colons. (ref:rcgen-cert-searlize)
collab_mode/src/config_man.rs:71
↓ 4 callers
Function
header_str
Pull the named header out of `headers` as an owned String. Errors if the header is missing or its value isn’t valid UTF-8.
collab_mode/src/signaling/server.rs:139
↓ 4 callers
Function
insert_handle
Insert a new `RemoteHandle` for `peer` in `map`, wrapping a `DropGuard` over the per-peer cancel token. If a live handle already exists, returns [`Web
collab_mode/src/webchannel.rs:234
↓ 4 callers
Function
make_str
(n: usize)
collab_mode/src/engine.rs:2207
↓ 4 callers
Method
matches
Return `true` if this doc matches `path`. Owned docs match by PathId. Because, eg, editor could try to share a single file which actually is inside a
collab_mode/src/server.rs:636
↓ 4 callers
Method
path_id_from_file_desc
(&self, file_desc: &FileDesc)
collab_mode/src/server.rs:1171
↓ 4 callers
Method
resend_watch_files
Send the currently opened files to the filewatch receptor.
collab_mode/src/server.rs:1132
↓ 4 callers
Function
run
Run the filewatch receptor. Returns when either channel closes. Normally this should never return; notifies `shutdown` on exit which the whole program
collab_mode/src/filewatch_receptor.rs:35
↓ 4 callers
Method
run
Run select! in a loop, once the loop exits, send `ConnectionBroke`. Async teardown of SCTP/DTLS/ICE happens in Drop handler, so cleanup runs always ru
collab_mode/src/webchannel.rs:725
↓ 4 callers
Function
run_signaling_server
Run the signaling server on `addr` (form: `"ip:port"`).
collab_mode/src/signaling/server.rs:60
↓ 4 callers
Method
send_candidate
Send ICE candidate to peer.
collab_mode/src/signaling/client.rs:351
↓ 4 callers
Function
send_connection_broke
( tx: &mpsc::Sender<Message>, peer_id: &ServerId, connection_id: u128, )
collab_mode/src/webchannel/ssh_remote.rs:160
↓ 4 callers
Function
send_notification
( editor_tx: &mpsc::Sender<lsp_server::Message>, method: T, params: impl Serialize, )
collab_mode/src/server.rs:5073
↓ 4 callers
Method
shift
Shift the editor position and range idx.
collab_mode/src/engine.rs:127
↓ 4 callers
Function
spawn_receptor
Spawn the receptor on a system thread and return the channel endpoints the test side keeps: a crossbeam `Sender` to feed WatchFiles, a tokio `Receiver
collab_mode/src/filewatch_receptor.rs:185
↓ 4 callers
Method
spawn_uncancelled
Spawn a tracked task that does *not* respond to cancellation.
collab_mode/src/cancel.rs:83
↓ 4 callers
Method
to_bytes
Serialize to bytes for signing. Use a custom format (<timestamp>:<cert>) instead of json to keep it simple and predictable.
collab_mode/src/signaling.rs:116
↓ 4 callers
Function
truncate_for_log
Truncate string for logging: show head…tail (N chars) if too long.
collab_mode/src/types.rs:24
↓ 3 callers
Method
bumpReject
(ws: WebSocket, att: Attachment)
worker/src/index.ts:319
↓ 3 callers
Method
child
Create a child. Cancelling the parent cancels the child; cancelling the child doesn’t cancel the parent. The tracker is shared so child can’t close.
collab_mode/src/cancel.rs:40
↓ 3 callers
Function
decodeTrustedHeader
(value: string)
worker/src/auth.ts:107
↓ 3 callers
Method
disconnect
(&self, peer: &ServerId)
collab_mode/src/webchannel.rs:640
↓ 3 callers
Method
get_remote_doc_mut
Get a remote doc by `EditorFileDesc`. Returns the remote doc id and a mutable reference to the doc if found.
collab_mode/src/server.rs:3305
↓ 3 callers
Function
id_name
Returns the name portion of a [`ServerId`], or `None` if there isn't one.
collab_mode/src/types.rs:57
↓ 3 callers
Method
json
()
worker/worker-configuration.d.ts:2056
↓ 3 callers
Method
mark_remote_disconnected
(&mut self, peer: &ServerId)
collab_mode/src/server.rs:399
↓ 3 callers
Method
mark_signaling_failed
(&mut self, addr: &str, reason: String)
collab_mode/src/server.rs:465
↓ 3 callers
Method
move_left
Move to the left by one, return the currently range. Caller must make sure this doesn’t overflow.
collab_mode/src/engine.rs:197
↓ 3 callers
Method
move_to_cursor
Move cursor to the position of `cursor`.
collab_mode/src/engine.rs:120
↓ 3 callers
Function
normalize_signaling_addr
If `addr` has no URL scheme, prepend `wss://`. Existing schemes (`wss://`, `ws://`, `https://`, etc) are preserved.
collab_mode/src/types.rs:16
↓ 3 callers
Function
now_secs
Unix-epoch seconds. Timebase for the ping liveness counters so we can stuff them into an `AtomicU64`.
collab_mode/src/webchannel.rs:51
↓ 3 callers
Method
nth_in_undo_queue
Return the op referenced by the `idxidx`th pointer in the undo queue.
collab_mode/src/engine.rs:1129
↓ 3 callers
Function
pair
Build two test WebChannels bound to a shared `TestFactory`, drain their dual receivers for the caller.
collab_mode/src/webchannel.rs:1406
↓ 3 callers
Method
replace
(content: string | ReadableStream | Response, options?: ContentOptions)
worker/worker-configuration.d.ts:1570
↓ 3 callers
Method
request_expect
Helper: Send request and wait for response with custom timeout.
collab_mode/src/server/tests/mod.rs:402
↓ 3 callers
Method
run
( &mut self, editor_tx: mpsc::Sender<lsp_server::Message>, mut editor_rx: mpsc::Receiv
collab_mode/src/server.rs:953
↓ 3 callers
Method
save_to_disk
Save buffer content to file.
collab_mode/src/server.rs:616
↓ 3 callers
Method
send_info
( &mut self, file: serde_json::Value, info: serde_json::Value, )
collab_mode/src/server/tests/mod.rs:526
↓ 3 callers
Method
send_sdp
Send SDP to peer.
collab_mode/src/signaling/client.rs:330
↓ 3 callers
Method
serializeAttachment
(attachment: any)
worker/worker-configuration.d.ts:3148
↓ 3 callers
Method
site
Return the site of the op.
collab_mode/src/op.rs:57
↓ 3 callers
Function
spawn_hub_filewatch_receptor
Move the hub’s filewatch channels out of the setup and spawn a real `filewatch_receptor::run` on a system thread, wired to the hub’s `Server`. After t
collab_mode/src/server/tests/filewatch.rs:17
↓ 3 callers
Method
total_len
Return the total length of global history + local history.
collab_mode/src/engine.rs:1102
↓ 3 callers
Function
tryClose
(ws: WebSocket, code: number, reason: string)
worker/src/index.ts:337
↓ 3 callers
Function
unix_epoch_secs
Get current unix epoch in seconds.
collab_mode/src/server.rs:187
↓ 3 callers
Method
values
(options?: ReadableStreamValuesOptions)
worker/worker-configuration.d.ts:2258
↓ 2 callers
Method
accept
(options?: WebSocketAcceptOptions)
worker/worker-configuration.d.ts:3135
↓ 2 callers
Method
apply_edit_instruction_unchecked
Apply an EditInstruction to the buffer without checking engine/buffer sync. Use `verify_buffer_engine_sync` after applying all instructions from a sin
collab_mode/src/server.rs:647
↓ 2 callers
Method
apply_op
Apply `op` to the document.
collab_mode/src/server.rs:566
↓ 2 callers
Method
body
()
worker/worker-configuration.d.ts:2051
↓ 2 callers
Method
broadcast
Broadcasts a message to all connected peers. Doesn't block.
collab_mode/src/webchannel.rs:612
↓ 2 callers
Method
broadcast_info
Broadcast `info`, excluding the sender of it.
collab_mode/src/server.rs:4615
↓ 2 callers
Method
check_cursor_positions
Check that the position of each cursor is correct. Only use this for debugging.
collab_mode/src/engine.rs:258
↓ 2 callers
Function
check_id
If `provided_id` doesn’t match `recorded_id`, return an error.
collab_mode/src/signaling/server.rs:431
↓ 2 callers
Method
cleanup
(ws: WebSocket)
worker/src/index.ts:308
↓ 2 callers
Function
connect_envoy_via_ssh
Spin up a host `Server`, mock editor, and create a real ssh connection to `yuan@localhost` running this same crate's envoy binary. Returns once the ho
collab_mode/src/server/tests/envoy.rs:23
↓ 2 callers
Method
convert_internal_ops_dont_apply
Convert `ops` from an internal op to an editor op, but don’t apply `ops` to the internal doc.
collab_mode/src/engine.rs:1463
↓ 2 callers
Function
create_bound_signaling_client
Create a SignalingChannel, bind it for an endpoint, and wait for Bound. Returns the channel plus the receiver the server would normally read from.
collab_mode/src/webchannel/e2e_tests.rs:156
↓ 2 callers
Function
create_test_id
(prefix: &str)
collab_mode/src/server/tests/mod.rs:180
↓ 2 callers
Method
current_gseq
Return the current global sequence number.
collab_mode/src/engine.rs:1661
↓ 2 callers
Method
editor_len
Return the total length of the editor document. Note that this function doesn't use any optimization and goes through every range front-to-back.
collab_mode/src/engine.rs:290
↓ 2 callers
Method
expect_connected_notification
Helper: Wait for Connected notification and extract fields.
collab_mode/src/server/tests/mod.rs:433
↓ 2 callers
Method
fetch
(request: Request)
worker/worker-configuration.d.ts:500
↓ 2 callers
Function
frame_write
Write a length-prefixed serialized [`Message`] to `writer`. Format is `[8-byte big-endian length][serde_json payload]`.
collab_mode/src/webchannel/byte_stream.rs:83
↓ 2 callers
Method
generate_undo_op
Generate an undo op from the current undo tip. Return an empty vector if there's no more op to undo. Also return the current global seq as context. Wh
collab_mode/src/engine.rs:1739
↓ 2 callers
Method
get_by_editor_desc
Get a remote doc by EditorFileDesc.
collab_mode/src/server.rs:747
↓ 2 callers
Method
handle_close_file_from_editor
( &mut self, next: &Next<'a>, params: DeleteFileParams, delete: bool, )
collab_mode/src/server.rs:4364
↓ 2 callers
Method
handle_close_file_locally
( &mut self, next: &Next<'a>, file: &FileDesc, delete: bool, )
collab_mode/src/server.rs:4490
↓ 2 callers
Method
handle_tx
(&self, signaling_addr: &str)
collab_mode/src/signaling/client.rs:133
↓ 2 callers
Function
hex_of
(bytes: &[u8])
collab_mode/src/bin/test_hash_speed.rs:167
↓ 2 callers
Function
hey
()
collab_mode/src/webchannel/io_remote.rs:106
↓ 2 callers
Function
idHash
(id: string)
worker/src/messages.ts:43
↓ 2 callers
Method
internal_doc
Return the internal document.
collab_mode/src/engine.rs:1352
↓ 2 callers
Function
isTrustedBy
( db: D1Database, endpointId: EndpointId, candidate: EndpointId, )
worker/src/d1.ts:75
↓ 2 callers
Function
is_stale_connection_attempt
Return true if `msg_connection_id` does not match the peer's current `connection_id` (the message is from a different connect attempt and should be dr
collab_mode/src/server.rs:310
↓ 2 callers
Function
key_cert
()
collab_mode/src/webchannel/io_remote.rs:116
↓ 2 callers
Method
list_files_from_disk
( &self, dir: Option<FileDesc>, )
collab_mode/src/server.rs:2646
↓ 2 callers
Method
list_files_from_editor
If host_id is not us, delegate to remote, if it’s us, read files from disk. If dir is None, list top-level projects and docs, if dir non-nil, list fil
collab_mode/src/server.rs:2594
↓ 2 callers
Function
listen_for_signal
Install SIGINT/SIGTERM handlers and cancel `shutdown` when either signal arrives. Caller is responsible for owning the `CancelManager` and for spawnin
collab_mode/src/server.rs:5010
↓ 2 callers
Function
main_loop
Starts sync threads carring messages between the editor and the collab peer, blocks on errors. Return when fatal error occurs.
collab_mode/src/editor_receptor.rs:40
↓ 2 callers
Method
make_directory_on_disk
( &self, project_id: &ProjectId, rel_path: &str, )
collab_mode/src/server.rs:3085
↓ 2 callers
Method
move_file_on_disk
( &mut self, project_id: &ProjectId, old_path: &str, new_path: &str, )
collab_mode/src/server.rs:4146
↓ 2 callers
Function
next_stride
(cur: u64)
collab_mode/src/server.rs:295
↓ 2 callers
Method
open_file_from_disk
Read file from disk and return the content as string. Return (content, file object, abs_path).
collab_mode/src/server.rs:2841
↓ 2 callers
Method
ops_after
Get the global ops with sequence number larger than `seq`.
collab_mode/src/engine.rs:1107
↓ 2 callers
Function
pair
Build two WebChannels connected via a `tokio::io::duplex` and hand back each side’s `DualReceiver` for inbound assertions.
collab_mode/src/webchannel/io_remote.rs:122
↓ 2 callers
Function
parseMsg
(raw: string)
worker/src/messages.ts:19
← previous
next →
101–200 of 852, ranked by callers