pub enum DataCodingScheme {
Standard {
compressed: bool,
class: MessageClass,
encoding: MessageEncoding,
},
Reserved,
MessageWaitingDiscard {
waiting: bool,
type_indication: MessageWaitingType,
},
MessageWaiting {
waiting: bool,
type_indication: MessageWaitingType,
ucs2: bool,
},
}Expand description
The data coding scheme of the message.
Basically, this enum is a decoded 8-bit field that has a bunch of different cases, which is
why there are so many options here.
The meanings explained in the Huawei spec are very confusing and sometimes overlapping.
Use the encoding method to figure out what encoding to use, which is probably the only real
use you’re going to have for this struct anyway.
Variants§
Standard
Standard coding scheme.
Fields
class: MessageClassThe message class (flash SMS, stored to SIM only, etc.)
encoding: MessageEncodingThe message encoding (7-bit, UCS-2, 8-bit)
Reserved
Reserved value.
MessageWaitingDiscard
Discard the message content, but display the message waiting indication to the user.
Fields
type_indication: MessageWaitingTypeType of message waiting.
MessageWaiting
Store the message content, and display the message waiting indication to the user.
Implementations§
Source§impl DataCodingScheme
impl DataCodingScheme
Sourcepub fn encoding(&self) -> MessageEncoding
pub fn encoding(&self) -> MessageEncoding
Determine which character encoding the message uses (i.e. GSM 7-bit, UCS-2, …)
(Some of these answers might be guesses.)
Trait Implementations§
Source§impl Clone for DataCodingScheme
impl Clone for DataCodingScheme
Source§fn clone(&self) -> DataCodingScheme
fn clone(&self) -> DataCodingScheme
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for DataCodingScheme
impl Debug for DataCodingScheme
Source§impl From<u8> for DataCodingScheme
impl From<u8> for DataCodingScheme
Source§impl Into<u8> for DataCodingScheme
impl Into<u8> for DataCodingScheme
Source§impl PartialEq for DataCodingScheme
impl PartialEq for DataCodingScheme
Source§fn eq(&self, other: &DataCodingScheme) -> bool
fn eq(&self, other: &DataCodingScheme) -> bool
self and other values to be equal, and is used by ==.