Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Yengas/rust-chat-server
/ functions
Functions
143 in github.com/Yengas/rust-chat-server
⨍
Functions
143
◇
Types & classes
57
↓ 6 callers
Method
write
Send a [crate::event::Event] to the backing [TcpStream] # Cancel Safety This method is not cancellation safe. If it is used as the event in a [tokio
comms/src/transport/server.rs:39
↓ 5 callers
Function
assert_event_serialization
given an event enum, and an expect string, asserts that event is serialized / deserialized appropiately
comms/src/event.rs:91
↓ 5 callers
Method
next
(&mut self)
server/examples/stress_test.rs:51
↓ 5 callers
Function
split_tcp_stream
Splits a TCP stream into a stream of commands and an event writer. # Arguments - `stream` - A [TcpStream] to split
comms/src/transport/server.rs:54
↓ 4 callers
Function
assert_command_serialization
given a command enum, and an expect string, asserts that command is serialized / deserialized appropiately
comms/src/command.rs:50
↓ 4 callers
Method
insert
Add a user to the room, returns true if the user is a new user
server/src/room_manager/room/user_registry.rs:23
↓ 4 callers
Method
recv
Recieve an event that may have originated from any of the rooms the user is actively participating in
server/src/session/chat_session.rs:126
↓ 3 callers
Method
get_room_data
(&self, name: &str)
tui/src/ui_management/pages/chat_page/chat_page.rs:93
↓ 3 callers
Method
is_empty
(&self)
tui/src/ui_management/components/input_box.rs:36
↓ 3 callers
Method
remove
Removes a given session from the participant list, returns true if the user is no longer in the room Does nothing and returns false if the user does n
server/src/room_manager/room/user_registry.rs:45
↓ 3 callers
Method
user_id
(&self)
server/src/room_manager/room/user_session_handle.rs:46
↓ 2 callers
Method
calculate_border_color
(&self, section: Section)
tui/src/ui_management/pages/chat_page/chat_page.rs:137
↓ 2 callers
Function
calculate_list_offset
(height: u16, items_len: usize)
tui/src/ui_management/pages/chat_page/chat_page.rs:236
↓ 2 callers
Method
clamp_cursor
(&self, new_cursor_pos: usize)
tui/src/ui_management/components/input_box.rs:78
↓ 2 callers
Method
cleanup_room
Cleanup the room by removing the user from the room and aborting the task that forwards broadcasted messages to the user
server/src/session/chat_session.rs:112
↓ 2 callers
Method
disable_section
(&mut self, section: &Section)
tui/src/ui_management/pages/chat_page/chat_page.rs:145
↓ 2 callers
Method
get_section_activation_for_section
( &'a mut self, section: &Section, )
tui/src/ui_management/pages/chat_page/chat_page.rs:111
↓ 2 callers
Function
key_to_span
(key: &String)
tui/src/ui_management/pages/chat_page/section/usage.rs:22
↓ 2 callers
Method
move_cursor_left
(&mut self)
tui/src/ui_management/components/input_box.rs:40
↓ 2 callers
Method
move_cursor_right
(&mut self)
tui/src/ui_management/components/input_box.rs:45
↓ 2 callers
Method
reset
(&mut self)
tui/src/ui_management/components/input_box.rs:31
↓ 2 callers
Method
rooms
(&self)
tui/src/ui_management/pages/chat_page/components/room_list.rs:95
↓ 2 callers
Method
session_id
(&self)
server/src/room_manager/room/user_session_handle.rs:42
↓ 2 callers
Method
text
(&self)
tui/src/ui_management/components/input_box.rs:22
↓ 2 callers
Method
to_usize
(&self)
tui/src/ui_management/pages/chat_page/chat_page.rs:30
↓ 1 callers
Method
activate
(&mut self)
tui/src/ui_management/pages/chat_page/components/room_list.rs:167
↓ 1 callers
Method
build
(self)
server/src/room_manager/mod.rs:44
↓ 1 callers
Method
chat_room_metadatas
(&self)
server/src/room_manager/room_manager.rs:32
↓ 1 callers
Method
connect_to_server
(&mut self)
tui/src/ui_management/pages/connect_page/connect_page.rs:40
↓ 1 callers
Method
create_room
Add a room to the room manager Will panic if a room with the same name already exists
server/src/room_manager/mod.rs:28
↓ 1 callers
Function
create_termination
create a broadcast channel for retrieving the application kill signal
tui/src/termination.rs:41
↓ 1 callers
Method
deactivate
(&mut self)
tui/src/ui_management/pages/chat_page/components/room_list.rs:179
↓ 1 callers
Method
delete_char
(&mut self)
tui/src/ui_management/components/input_box.rs:56
↓ 1 callers
Method
drop_user_session_handle
(&self, handle: UserSessionHandle)
server/src/room_manager/room_manager.rs:57
↓ 1 callers
Method
enter_char
(&mut self, new_char: char)
tui/src/ui_management/components/input_box.rs:50
↓ 1 callers
Method
get_active_page_component
(&self)
tui/src/ui_management/pages/mod.rs:42
↓ 1 callers
Method
get_active_page_component_mut
(&mut self)
tui/src/ui_management/pages/mod.rs:49
↓ 1 callers
Method
get_component_for_section_mut
(&'a mut self, section: &Section)
tui/src/ui_management/pages/chat_page/chat_page.rs:104
↓ 1 callers
Method
get_room_idx
(&self, name: &str)
tui/src/ui_management/pages/chat_page/components/room_list.rs:99
↓ 1 callers
Method
get_unique_user_ids
(&self)
server/src/room_manager/room/chat_room.rs:38
↓ 1 callers
Method
hover_next
(&mut self)
tui/src/ui_management/pages/chat_page/chat_page.rs:121
↓ 1 callers
Method
hover_previous
(&mut self)
tui/src/ui_management/pages/chat_page/chat_page.rs:127
↓ 1 callers
Method
join
Add a participant to the room and broadcast that they joined # Returns - A broadcast receiver for the user to receive messages from the room - A [Us
server/src/room_manager/room/chat_room.rs:48
↓ 1 callers
Method
join_room
Joins to a room given a user session
server/src/room_manager/room_manager.rs:37
↓ 1 callers
Method
leave
Remove a participant from the room and broadcast that they left Consume the [UserSessionHandle] to drop it
server/src/room_manager/room/chat_room.rs:77
↓ 1 callers
Method
move_with_state
(self, state: &State)
tui/src/ui_management/pages/mod.rs:71
↓ 1 callers
Method
move_with_state
(self, state: &State)
tui/src/ui_management/pages/chat_page/chat_page.rs:172
↓ 1 callers
Method
move_with_state
(self, state: &State)
tui/src/ui_management/pages/connect_page/connect_page.rs:71
↓ 1 callers
Method
next
(&mut self)
tui/src/ui_management/pages/chat_page/components/room_list.rs:66
↓ 1 callers
Method
previous
(&mut self)
tui/src/ui_management/pages/chat_page/components/room_list.rs:80
↓ 1 callers
Method
render
(&self, frame: &mut Frame<B>, props: ())
tui/src/ui_management/pages/mod.rs:94
↓ 1 callers
Function
restore_terminal
(terminal: &mut Terminal<CrosstermBackend<Stdout>>)
tui/src/ui_management/ui_manager.rs:102
↓ 1 callers
Method
room
(&self)
server/src/room_manager/room/user_session_handle.rs:38
↓ 1 callers
Method
send_message
Send a message to the room
server/src/room_manager/room/user_session_handle.rs:51
↓ 1 callers
Method
set_text
(&mut self, new_text: &str)
tui/src/ui_management/components/input_box.rs:26
↓ 1 callers
Function
setup_terminal
()
tui/src/ui_management/ui_manager.rs:92
↓ 1 callers
Function
spawn_single_user
(rooms_to_join: Vec<String>)
server/examples/stress_test.rs:71
↓ 1 callers
Function
spawn_single_user_raw
(rooms_to_join: Vec<String>)
server/examples/stress_test.rs:82
↓ 1 callers
Method
submit_message
(&mut self)
tui/src/ui_management/pages/chat_page/components/message_input_box.rs:41
↓ 1 callers
Method
terminate
(&mut self, interrupted: Interrupted)
tui/src/termination.rs:21
↓ 1 callers
Function
terminate_by_unix_signal
(mut terminator: Terminator)
tui/src/termination.rs:29
↓ 1 callers
Method
usage_info
(&self)
tui/src/ui_management/pages/chat_page/chat_page.rs:421
↓ 1 callers
Function
widget_usage_to_text
(usage: UsageInfo)
tui/src/ui_management/pages/chat_page/section/usage.rs:26
Method
activate
(&mut self)
tui/src/ui_management/pages/chat_page/components/message_input_box.rs:95
Function
assert_server_client_transport
()
comms/tests/e2e_server_and_client_transport.rs:12
Function
create_server_handle
(addr: &str)
tui/src/state_store/state_store.rs:38
Method
deactivate
(&mut self)
tui/src/ui_management/pages/chat_page/components/message_input_box.rs:97
Method
default
()
tui/src/state_store/state.rs:32
Function
execute_client
()
comms/tests/e2e_server_and_client_transport.rs:82
Function
execute_server
()
comms/tests/e2e_server_and_client_transport.rs:42
Method
from
(state: &State)
tui/src/ui_management/pages/mod.rs:24
Method
from
(state: &State)
tui/src/ui_management/pages/chat_page/chat_page.rs:62
Method
from
(state: &State)
tui/src/ui_management/pages/chat_page/components/message_input_box.rs:25
Method
from
(state: &State)
tui/src/ui_management/pages/chat_page/components/room_list.rs:34
Method
from
(state: &State)
tui/src/ui_management/pages/connect_page/connect_page.rs:16
Method
get_component_for_section
(&'a self, section: &Section)
tui/src/ui_management/pages/chat_page/chat_page.rs:97
Method
get_unique_user_ids
(&self)
server/src/room_manager/room/user_registry.rs:67
Method
handle_key_event
(&mut self, key: KeyEvent)
tui/src/ui_management/components/input_box.rs:103
Method
handle_key_event
(&mut self, key: KeyEvent)
tui/src/ui_management/pages/mod.rs:88
Method
handle_key_event
(&mut self, key: KeyEvent)
tui/src/ui_management/pages/chat_page/chat_page.rs:189
Method
handle_key_event
(&mut self, key: KeyEvent)
tui/src/ui_management/pages/chat_page/components/message_input_box.rs:79
Method
handle_key_event
(&mut self, key: KeyEvent)
tui/src/ui_management/pages/chat_page/components/room_list.rs:138
Method
handle_key_event
(&mut self, key: KeyEvent)
tui/src/ui_management/pages/connect_page/connect_page.rs:85
Method
handle_server_event
(&mut self, event: &event::Event)
tui/src/state_store/state.rs:89
Method
handle_user_command
Handle a user command related to room management such as; join, leave, send message
server/src/session/chat_session.rs:43
Function
handle_user_session
Given a tcp stream and a room manager, handles the user session until the user quits the session, or the tcp stream is closed for some reason, or the
server/src/session/mod.rs:20
Method
leave_all_rooms
TODO: optimize the performance of this function. leaving one by one may not be a good idea. Leave all the rooms the user is currently participating in
server/src/session/chat_session.rs:99
Function
main
()
tui/src/main.rs:12
Function
main
()
server/src/main.rs:16
Function
main
()
server/examples/stress_test.rs:134
Method
main_loop
( self, mut state_rx: UnboundedReceiver<State>, mut interrupt_rx: broadcast::Receiver<
tui/src/ui_management/ui_manager.rs:40
Method
main_loop
( self, mut terminator: Terminator, mut action_rx: UnboundedReceiver<Action>,
tui/src/state_store/state_store.rs:46
Method
mark_connection_request_start
(&mut self)
tui/src/state_store/state.rs:150
Method
move_with_state
(self, _state: &State)
tui/src/ui_management/components/input_box.rs:92
Method
move_with_state
(self, state: &State)
tui/src/ui_management/pages/chat_page/components/message_input_box.rs:65
Method
move_with_state
(self, state: &State)
tui/src/ui_management/pages/chat_page/components/room_list.rs:124
Method
name
(&self)
tui/src/ui_management/components/input_box.rs:99
Method
name
route all functions to the active page
tui/src/ui_management/pages/mod.rs:84
Method
name
(&self)
tui/src/ui_management/pages/chat_page/chat_page.rs:185
Method
name
(&self)
tui/src/ui_management/pages/chat_page/components/message_input_box.rs:75
next →
1–100 of 143, ranked by callers