added a name request to the standard

This commit is contained in:
Nickiel12 2024-09-01 00:44:45 +00:00
parent a89e970be3
commit c5e733b71d

View file

@ -16,8 +16,13 @@ use webrtc::ice_transport::ice_candidate::{RTCIceCandidate, RTCIceCandidateInit}
static MAX_MESSAGE: usize = 50;
/// Standardized messages that can be sent between the controller
/// and satellites
#[derive(Serialize, Deserialize, Clone)]
pub enum ApplicationMessage {
/// Ask for the satellite's name. If it is None, it is a name request
/// if it is Some, it is a response to a name request
NameRequest(Option<String>),
WebRTCPacket(RTCSessionDescription),
WebRTCIceCandidate(RTCIceCandidate),
WebRTCIceCandidateInit(RTCIceCandidateInit),