Skip to main content

UserRequest

Struct UserRequest 

Source
pub struct UserRequest(pub Message);
Expand description

UserRequest (35=BE).

Tuple Fields§

§0: Message

Implementations§

Source§

impl UserRequest

Source

pub const MSG_TYPE: &'static str = "BE"

Source

pub fn new( user_request_id: impl Into<String>, user_request_type: i64, username: impl Into<String>, ) -> Self

Source

pub fn from_message(msg: Message) -> Result<Self, Message>

Wrap a generic message; fails unless 35=“BE”.

Source

pub fn user_request_id(&self) -> Result<String, ConversionError>

Source

pub fn set_user_request_id(&mut self, v: impl Into<String>)

Source

pub fn has_user_request_id(&self) -> bool

Source

pub fn user_request_type(&self) -> Result<i64, ConversionError>

Source

pub fn set_user_request_type(&mut self, v: i64)

Source

pub fn has_user_request_type(&self) -> bool

Source

pub fn username(&self) -> Result<String, ConversionError>

Source

pub fn set_username(&mut self, v: impl Into<String>)

Source

pub fn has_username(&self) -> bool

Source

pub fn password(&self) -> Result<String, ConversionError>

Source

pub fn set_password(&mut self, v: impl Into<String>)

Source

pub fn has_password(&self) -> bool

Source

pub fn new_password(&self) -> Result<String, ConversionError>

Source

pub fn set_new_password(&mut self, v: impl Into<String>)

Source

pub fn has_new_password(&self) -> bool

Source

pub fn raw_data_length(&self) -> Result<i64, ConversionError>

Source

pub fn set_raw_data_length(&mut self, v: i64)

Source

pub fn has_raw_data_length(&self) -> bool

Source

pub fn raw_data(&self) -> Result<Vec<u8>, ConversionError>

Source

pub fn set_raw_data(&mut self, v: impl Into<Vec<u8>>)

Source

pub fn has_raw_data(&self) -> bool

Methods from Deref<Target = Message>§

Source

pub fn msg_type(&self) -> Result<String>

Source

pub fn is_admin(&self) -> bool

Source

pub fn seq_num(&self) -> Result<u64>

Source

pub fn poss_dup(&self) -> bool

Source

pub fn structure_error(&self) -> Option<Tag>

First tag found out of section order during parse, if any.

Source

pub fn to_bytes(&self) -> Vec<u8>

Serialize, computing BodyLength(9) and CheckSum(10).

Header order matches the reference engines: 8, 9, 35, then remaining header fields in ascending tag order. Body keeps insertion (wire) order. Trailer: descending tag order (SignatureLength before Signature), CheckSum last.

Source

pub fn set_header(&mut self, tag: Tag, value: impl FixEncode)

Set a header field (helper).

Source

pub fn set(&mut self, tag: Tag, value: impl FixEncode)

Set a body field (helper).

Source

pub fn stamp_sending_time(&mut self, ts: UtcTimestamp)

Stamp SendingTime(52) with now at the given precision.

Trait Implementations§

Source§

impl Clone for UserRequest

Source§

fn clone(&self) -> UserRequest

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 UserRequest

Source§

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

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

impl Deref for UserRequest

Source§

type Target = Message

The resulting type after dereferencing.
Source§

fn deref(&self) -> &Message

Dereferences the value.
Source§

impl DerefMut for UserRequest

Source§

fn deref_mut(&mut self) -> &mut Message

Mutably dereferences the value.
Source§

impl From<UserRequest> for Message

Source§

fn from(m: UserRequest) -> Message

Converts to this type from the input type.

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<P, T> Receiver for P
where P: Deref<Target = T> + ?Sized, T: ?Sized,

Source§

type Target = T

🔬This is a nightly-only experimental API. (arbitrary_self_types)
The target type on which the method may be called.
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 = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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