Skip to main content

ClientMessage

Enum ClientMessage 

Source
pub enum ClientMessage {
Show 62 variants KeepAlive, Register(RegistrationMessage), IpPort { rtp_port: u16, }, KeypadButton { button: Digit, line_instance: u32, call_reference: u32, wire_layout: Option<KeypadButtonWireLayout>, }, EnblocCall { called_party: String, line_instance: u32, }, Stimulus { stimulus: Stimulus, instance: u32, call_reference: u32, status: u32, }, OffHook { line_instance: u32, call_reference: u32, }, OnHook { line_instance: u32, call_reference: u32, }, OffHookWithCallingParty { calling_party_number: String, voice_mailbox: String, line_instance: u32, }, LineStatRequest { line_instance: u32, }, ConfigStatRequest, TimeDateRequest, ButtonTemplateRequest, VersionRequest, CapabilitiesResponse(Vec<MediaCapability>), MediaPortList(MediaPortList), CapabilitiesUpdate(CapabilityUpdate), OpenMultimediaReceiveChannelAck(OpenMultimediaReceiveChannelAck), ServerRequest, Alarm { severity: AlarmSeverity, text: String, parameters: Option<[u32; 2]>, }, MulticastMediaReceptionAck { status: MediaStatus, passthrough_party_id: PassthroughPartyId, call_reference: CallReference, }, OpenReceiveChannelAck { status: MediaStatus, address: IpAddr, port: u16, passthrough_party_id: u32, call_reference: u32, }, SoftKeySetRequest, SoftKeyTemplateRequest, SoftKeyEvent { event: u32, line_instance: u32, call_reference: u32, }, Unregister { reason: u32, }, RegisterToken(RegisterTokenMessage), SpcpRegisterToken(SpcpRegisterTokenMessage), HookFlash { line_instance: u32, call_reference: u32, }, ForwardStatusRequest { line_instance: u32, }, SpeedDialStatusRequest { speed_dial_instance: u32, }, ConnectionStatisticsResponse(ConnectionStatistics), HeadsetStatus { enabled: bool, }, MediaResourceNotification(MediaResourceNotification), MediaPathEvent { path: MediaPathId, event: MediaPathEvent, }, MediaPathCapability { path: MediaPathId, capability: MediaPathCapability, }, MediaTransmissionFailure { conference_id: u32, passthrough_party_id: u32, address: IpAddr, port: u16, call_reference: u32, status: MediaStatus, }, RegisterAvailableLines { lines: u32, }, ServiceUrlStatusRequest { index: u32, }, FeatureStatusRequest { index: u32, capabilities: u32, }, StartMediaTransmissionAck(MediaTransmissionAck), StartMultimediaTransmissionAck(StartMultimediaTransmissionAck), ExtensionDeviceCapabilities(ExtensionDeviceCapabilities), DeviceToUserData(UserDataMessage), DeviceToUserDataResponse(UserDataMessage), DeviceToUserDataV1(UserDataV1Message), DeviceToUserDataResponseV1(UserDataV1Message), PortResponse(PortEndpoint), SubscriptionStatusRequest(SubscriptionRequest), SubscribeDtmfPayloadResponse(DtmfPayloadIdentity), UnsubscribeDtmfPayloadResponse(DtmfPayloadIdentity), LocationInfo { xml: String, }, XmlAlarm(XmlAlarmMessage), CallCountRequest(CallCountRequestPayload), CreateConferenceResponse(CreateConferenceResponse), DeleteConferenceResponse { conference_id: ConferenceId, result: DeleteConferenceResult, }, ModifyConferenceResponse(ModifyConferenceResponse), AuditConferenceResponse(AuditConferenceResponse), AddParticipantResponse(AddParticipantResponse), AuditParticipantResponse(AuditParticipantResponse), KnownOpaque(KnownOpaqueMessage), Unknown(RawMessage),
}
Expand description

Typed messages accepted from a station connection.

Variants correspond to station-to-control identifiers in catalog::MessageId. KnownOpaque retains a known catalog entry without a typed payload, while Unknown retains an unrecognized identifier. Decode with Self::decode during registration and Self::decode_with_version after version negotiation.

Variants§

§

KeepAlive

Reports that the station connection remains active. Refreshes the server-side keepalive deadline.

§

Register(RegistrationMessage)

Introduces a station and its requested SCCP protocol characteristics. Starts registration and device authentication on the server.

§

IpPort

Reports the UDP port on which the station expects media. Supplies the station RTP port to server-side media setup.

Fields

§rtp_port: u16
§

KeypadButton

Reports a digit pressed on the station keypad. Associates the input with its line and call when the wire layout permits.

Fields

§button: Digit
§line_instance: u32
§call_reference: u32
§

EnblocCall

Submits a complete called-party number in one message. Requests call setup without sending digits individually.

Fields

§called_party: String
§line_instance: u32
§

Stimulus

Reports a physical or logical station button stimulus. Identifies the affected instance, call, and stimulus status.

Fields

§stimulus: Stimulus
§instance: u32
§call_reference: u32
§status: u32
§

OffHook

Reports that the station handset or audio path went off hook. Starts or resumes call handling for the identified line and call.

Fields

§line_instance: u32
§call_reference: u32
§

OnHook

Reports that the station handset or audio path went on hook. Ends or releases call handling for the identified line and call.

Fields

§line_instance: u32
§call_reference: u32
§

OffHookWithCallingParty

Reports an off-hook transition with originating-party details. Carries the calling number, mailbox, and selected line instance.

Fields

§calling_party_number: String
§voice_mailbox: String
§line_instance: u32
§

LineStatRequest

Requests the configured status of one station line. Uses the line instance to select the directory number response.

Fields

§line_instance: u32
§

ConfigStatRequest

Requests the station’s current device configuration. Prompts the server to return its configuration status.

§

TimeDateRequest

Requests the server’s current date and time. Prompts synchronization of the station clock.

§

ButtonTemplateRequest

Requests the station’s provisioned button layout. Prompts one or more button-template chunks from the server.

§

VersionRequest

Requests the firmware or load version assigned to the station. Prompts the server’s version response during provisioning.

§

CapabilitiesResponse(Vec<MediaCapability>)

Reports the station’s supported media capabilities. Answers a server capability request with codec and media details.

§

MediaPortList(MediaPortList)

Reports the RTP ports the station has allocated for media streams. Carries up to sixteen port numbers for use by call control.

§

CapabilitiesUpdate(CapabilityUpdate)

Reports a changed set of station media capabilities. Lets the server refresh capabilities after initial negotiation.

§

OpenMultimediaReceiveChannelAck(OpenMultimediaReceiveChannelAck)

Acknowledges opening a multimedia receive channel. Reports the resulting endpoint and status for the requested stream.

§

ServerRequest

Requests the station’s configured signaling-server list. Prompts the server response used for failover discovery.

§

Alarm

Reports a station alarm or diagnostic condition. Carries severity, text, and optional vendor parameter words.

Fields

§severity: AlarmSeverity
§text: String
§parameters: Option<[u32; 2]>

Optional alarm parameter words. None preserves the shorter wire layout exactly.

§

MulticastMediaReceptionAck

Acknowledges starting multicast media reception. Reports status for the passthrough party and call.

Fields

§passthrough_party_id: PassthroughPartyId
§call_reference: CallReference
§

OpenReceiveChannelAck

Acknowledges opening an audio receive channel. Reports status and the station’s selected media endpoint.

Fields

§address: IpAddr
§port: u16
§passthrough_party_id: u32
§call_reference: u32
§

SoftKeySetRequest

Requests the soft-key sets available to the station. Prompts the server to send the active soft-key profile.

§

SoftKeyTemplateRequest

Requests the station’s soft-key action template. Prompts the server to enumerate supported soft-key actions.

§

SoftKeyEvent

Reports activation of a station soft key. Associates the action with its line and call context.

Fields

§event: u32
§line_instance: u32
§call_reference: u32
§

Unregister

Requests removal of the station registration. Carries the station-provided reason for ending the session.

Fields

§reason: u32
§

RegisterToken(RegisterTokenMessage)

Requests a registration token before full station registration. Supplies the station identity used for token admission control.

§

SpcpRegisterToken(SpcpRegisterTokenMessage)

Requests an SPCP registration token before full station registration. Supplies the station identity, address, device type, and stream capacity.

§

HookFlash

Reports a hook-flash action on an analog-style call. Associates the flash with its line and call context.

Fields

§line_instance: u32
§call_reference: u32
§

ForwardStatusRequest

Requests call-forwarding state for one line. Prompts the server to return configured forwarding destinations.

Fields

§line_instance: u32
§

SpeedDialStatusRequest

Requests the contents of one speed-dial entry. Uses the speed-dial instance to select the response.

Fields

§speed_dial_instance: u32
§

ConnectionStatisticsResponse(ConnectionStatistics)

Returns media connection statistics collected by the station. Carries packet, jitter, latency, and quality data for a call.

§

HeadsetStatus

Reports whether the station headset is enabled. Updates the server’s view of the station audio accessory state.

Fields

§enabled: bool
§

MediaResourceNotification(MediaResourceNotification)

Reports a station media-resource state change. Carries the resource type, direction, and availability details.

§

MediaPathEvent

Reports an event on a particular station media path. Identifies both the media path and the observed event.

§

MediaPathCapability

Reports a capability of a particular station media path. Identifies the path and its supported media behavior.

Fields

§

MediaTransmissionFailure

Reports failure of an active media transmission. Identifies the stream endpoint, call, and failure status.

Fields

§conference_id: u32
§passthrough_party_id: u32
§address: IpAddr
§port: u16
§call_reference: u32
§

RegisterAvailableLines

Reports how many line appearances the station can register. Lets the server constrain provisioning to the station’s capacity.

Fields

§lines: u32
§

ServiceUrlStatusRequest

Requests the configured service URL at an index. Prompts the server to return its URL, label, and extension text.

Fields

§index: u32
§

FeatureStatusRequest

Requests the state of a provisioned feature button. Carries the feature index and station capability bits.

Fields

§index: u32
§capabilities: u32

Station feature-capability bits included in the request layout.

§

StartMediaTransmissionAck(MediaTransmissionAck)

Acknowledges a request to start audio transmission. Reports the station’s result for the requested media stream.

§

StartMultimediaTransmissionAck(StartMultimediaTransmissionAck)

Acknowledges a request to start multimedia transmission. Reports the station’s result for the requested video or data stream.

§

ExtensionDeviceCapabilities(ExtensionDeviceCapabilities)

Reports capabilities supplied by an attached extension device. Lets the server account for expansion-module and accessory features.

§

DeviceToUserData(UserDataMessage)

Carries legacy application data from the station to the server. Uses the fixed-format device-to-user data layout.

§

DeviceToUserDataResponse(UserDataMessage)

Returns a legacy station response to server application data. Uses the fixed-format device-to-user response layout.

§

DeviceToUserDataV1(UserDataV1Message)

Carries version-one application data from the station. Supports the extended variable-length user-data layout.

§

DeviceToUserDataResponseV1(UserDataV1Message)

Returns a version-one station response to application data. Supports the extended variable-length response layout.

§

PortResponse(PortEndpoint)

Returns endpoint information requested for a station port. Identifies the address and port selected by the station.

§

SubscriptionStatusRequest(SubscriptionRequest)

Requests status for a station feature subscription. Carries the transaction and feature identifiers being queried.

§

SubscribeDtmfPayloadResponse(DtmfPayloadIdentity)

Acknowledges subscription to an RTP DTMF payload. Identifies the negotiated payload associated with the subscription.

§

UnsubscribeDtmfPayloadResponse(DtmfPayloadIdentity)

Acknowledges removal of an RTP DTMF payload subscription. Identifies the payload whose subscription was removed.

§

LocationInfo

Reports the station’s location information as XML. Provides location metadata for routing and emergency services.

Fields

§xml: String

Location XML limited to 2,400 bytes before its required terminator.

§

XmlAlarm(XmlAlarmMessage)

Reports a structured station alarm encoded as XML. Carries the alarm payload and its associated station metadata.

§

CallCountRequest(CallCountRequestPayload)

Requests the server’s current call-count information.

§

CreateConferenceResponse(CreateConferenceResponse)

Returns the result of creating a conference. Correlates the station outcome with the requested conference.

§

DeleteConferenceResponse

Returns the result of deleting a conference. Identifies the conference and its deletion result.

Fields

§conference_id: ConferenceId
§

ModifyConferenceResponse(ModifyConferenceResponse)

Returns the result of modifying a conference. Carries the station outcome for the requested conference changes.

§

AuditConferenceResponse(AuditConferenceResponse)

Returns station state for a conference audit. Reports the conference details requested by the server.

§

AddParticipantResponse(AddParticipantResponse)

Returns the result of adding a conference participant. Identifies the conference participant and operation outcome.

§

AuditParticipantResponse(AuditParticipantResponse)

Returns station state for a participant audit. Reports the participant details requested by the server.

§

KnownOpaque(KnownOpaqueMessage)

Preserves a recognized station-to-server message without typed decoding. Retains its catalog identifier and payload bytes for lossless handling.

§

Unknown(RawMessage)

Preserves an unrecognized station-to-server message. Retains the unknown identifier and raw payload for diagnostics or forwarding.

Implementations§

Source§

impl ClientMessage

Source

pub fn decode_with_version( frame: Frame, protocol: ProtocolVersion, ) -> Result<Self, CodecError>

Decodes a station-originated frame with an explicit negotiated version.

Use this after registration when the session version is authoritative, especially for layouts whose header version is zero or ambiguous.

Source

pub fn decode(frame: Frame) -> Result<Self, CodecError>

Decodes a station-originated frame using its header version.

This is suitable for initial messages that carry a meaningful header version. Established sessions should prefer Self::decode_with_version.

Source

pub fn encode(&self, protocol: ProtocolVersion) -> Result<Vec<u8>, CodecError>

Canonically encode a phone-to-server message.

Trait Implementations§

Source§

impl Clone for ClientMessage

Source§

fn clone(&self) -> ClientMessage

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for ClientMessage

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for ClientMessage

Source§

impl PartialEq for ClientMessage

Source§

fn eq(&self, other: &ClientMessage) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for ClientMessage

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more