pub struct DataSm<'a, const N: usize> {
pub service_type: ServiceType<'a>,
pub source_addr_ton: Ton,
pub source_addr_npi: Npi,
pub source_addr: COctetString<'a, 1, 21>,
pub dest_addr_ton: Ton,
pub dest_addr_npi: Npi,
pub destination_addr: COctetString<'a, 1, 21>,
pub esm_class: EsmClass,
pub registered_delivery: RegisteredDelivery,
pub data_coding: DataCoding,
/* private fields */
}Expand description
The data_sm operation is similar to the submit_sm in that it provides a means to submit a mobile-terminated message. However, data_sm is intended for packet-based applications such as WAP in that it features a reduced PDU body containing fields relevant to WAP or packet-based applications.
Fields§
§service_type: ServiceType<'a>The service_type parameter can be used to indicate the SMS Application service associated with the message. Specifying the service_type allows the ESME to avail of enhanced messaging services such as “replace by service_type” or control the teleservice used on the air interface.
Set to NULL for default MC settings.
source_addr_ton: TonType of Number for source address.
If not known, set to NULL (Unknown).
source_addr_npi: NpiNumbering Plan Indicator for source address.
If not known, set to NULL (Unknown).
source_addr: COctetString<'a, 1, 21>Address of SME which originated this message.
If not known, set to NULL (Unknown).
dest_addr_ton: TonType of Number for destination.
dest_addr_npi: NpiNumbering Plan Indicator for destination.
destination_addr: COctetString<'a, 1, 21>Destination address of this short message For mobile terminated messages, this is the directory number of the recipient MS.
esm_class: EsmClassIndicates Message Mode and Message Type.
registered_delivery: RegisteredDeliveryIndicator to signify if a MC delivery receipt or an SME acknowledgement is required.
data_coding: DataCodingDefines the encoding scheme of the short message user data.
Implementations§
Source§impl<'a, const N: usize> DataSm<'a, N>
impl<'a, const N: usize> DataSm<'a, N>
Sourcepub fn into_parts(self) -> DataSmParts<'a, N>
pub fn into_parts(self) -> DataSmParts<'a, N>
Converts Self into its parts.
Sourcepub fn from_parts(parts: DataSmParts<'a, N>) -> Self
pub fn from_parts(parts: DataSmParts<'a, N>) -> Self
Source§impl<'a, const N: usize> DataSm<'a, N>
impl<'a, const N: usize> DataSm<'a, N>
pub fn new( service_type: ServiceType<'a>, source_addr_ton: Ton, source_addr_npi: Npi, source_addr: COctetString<'a, 1, 21>, dest_addr_ton: Ton, dest_addr_npi: Npi, destination_addr: COctetString<'a, 1, 21>, esm_class: EsmClass, registered_delivery: RegisteredDelivery, data_coding: DataCoding, tlvs: Vec<MessageSubmissionRequestTlvValue<'a>, N>, ) -> Self
pub fn tlvs(&self) -> &[Tlv<'_>]
pub fn set_tlvs(&mut self, tlvs: Vec<MessageSubmissionRequestTlvValue<'a>, N>)
pub fn clear_tlvs(&mut self)
pub fn push_tlv( &mut self, tlv: impl Into<MessageSubmissionRequestTlvValue<'a>>, ) -> Result<(), Tlv<'a>>
pub fn builder() -> DataSmBuilder<'a, N>
Trait Implementations§
Source§impl<'a, 'arbitrary: 'a, const N: usize> Arbitrary<'arbitrary> for DataSm<'a, N>
impl<'a, 'arbitrary: 'a, const N: usize> Arbitrary<'arbitrary> for DataSm<'a, N>
Source§fn arbitrary(u: &mut Unstructured<'arbitrary>) -> Result<Self>
fn arbitrary(u: &mut Unstructured<'arbitrary>) -> Result<Self>
Self from the given unstructured data. Read moreSource§fn arbitrary_take_rest(u: Unstructured<'arbitrary>) -> Result<Self>
fn arbitrary_take_rest(u: Unstructured<'arbitrary>) -> Result<Self>
Self from the entirety of the given
unstructured data. Read moreSource§fn size_hint(depth: usize) -> (usize, Option<usize>)
fn size_hint(depth: usize) -> (usize, Option<usize>)
Unstructured this type
needs to construct itself. Read moreSource§fn try_size_hint(
depth: usize,
) -> Result<(usize, Option<usize>), MaxRecursionReached>
fn try_size_hint( depth: usize, ) -> Result<(usize, Option<usize>), MaxRecursionReached>
Unstructured this type
needs to construct itself. Read moreSource§impl<'a, const N: usize> DecodeWithLength<'a> for DataSm<'a, N>
impl<'a, const N: usize> DecodeWithLength<'a> for DataSm<'a, N>
Source§impl<'a, const N: usize> Ord for DataSm<'a, N>
impl<'a, const N: usize> Ord for DataSm<'a, N>
Source§impl<'a, const N: usize> PartialOrd for DataSm<'a, N>
impl<'a, const N: usize> PartialOrd for DataSm<'a, N>
impl<'a, const N: usize> Eq for DataSm<'a, N>
impl<'a, const N: usize> StructuralPartialEq for DataSm<'a, N>
Auto Trait Implementations§
impl<'a, const N: usize> Freeze for DataSm<'a, N>
impl<'a, const N: usize> RefUnwindSafe for DataSm<'a, N>
impl<'a, const N: usize> Send for DataSm<'a, N>
impl<'a, const N: usize> Sync for DataSm<'a, N>
impl<'a, const N: usize> Unpin for DataSm<'a, N>
impl<'a, const N: usize> UnwindSafe for DataSm<'a, N>
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
clone_to_uninit)