Struct ServerNonInviteTransaction

Source
pub struct ServerNonInviteTransaction { /* private fields */ }
Expand description

Server non-INVITE transaction (RFC 3261 Section 17.2.2)

Implementations§

Source§

impl ServerNonInviteTransaction

Source

pub fn new( id: TransactionKey, request: Request, remote_addr: SocketAddr, transport: Arc<dyn Transport>, events_tx: Sender<TransactionEvent>, timer_config_override: Option<TimerSettings>, ) -> Result<Self>

Create a new server non-INVITE transaction.

Trait Implementations§

Source§

impl Clone for ServerNonInviteTransaction

Source§

fn clone(&self) -> ServerNonInviteTransaction

Returns a duplicate of the value. Read more
1.0.0 · Source§

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

Performs copy-assignment from source. Read more
Source§

impl CommonServerTransaction for ServerNonInviteTransaction

Source§

fn data(&self) -> &Arc<ServerTransactionData>

Returns the shared transaction data. Read more
Source§

impl Debug for ServerNonInviteTransaction

Source§

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

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

impl ServerTransaction for ServerNonInviteTransaction

Source§

fn process_request( &self, request: Request, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + '_>>

Processes an incoming request associated with this transaction. Read more
Source§

fn send_response( &self, response: Response, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + '_>>

Sends a response for this transaction, triggering appropriate state transitions. Read more
Source§

fn last_response(&self) -> Option<Response>

Returns the last response sent by this transaction. Read more
Source§

fn original_request_sync(&self) -> Option<Request>

Synchronous accessor for the original request if it’s available without async operations. This is an internal helper method that should be implemented by transaction types that can provide synchronous access to the original request. Read more
Source§

fn original_request_call_id(&self) -> Option<String>

Gets the Call-ID from the original request that created this transaction. Read more
Source§

fn original_request_from_tag(&self) -> Option<String>

Gets the From tag from the original request that created this transaction. Read more
Source§

fn original_request_to_tag(&self) -> Option<String>

Gets the To tag from the original request that created this transaction. Read more
Source§

impl Transaction for ServerNonInviteTransaction

Source§

fn id(&self) -> &TransactionKey

Returns the unique key identifying this transaction. The key is typically derived from the branch parameter of the Via header, the method, and directionality.
Source§

fn kind(&self) -> TransactionKind

Returns the TransactionKind of this transaction (e.g., InviteClient, InviteServer).
Source§

fn state(&self) -> TransactionState

Returns the current TransactionState of this transaction (e.g., Trying, Proceeding, Completed).
Source§

fn remote_addr(&self) -> SocketAddr

Returns the network SocketAddr of the remote party involved in this transaction. For client transactions, this is the destination address. For server transactions, it’s the source address.
Source§

fn matches(&self, message: &Message) -> bool

Checks if the given SIP Message (request or response) matches this transaction according to the rules in RFC 3261, Section 17.1.3 (client) and 17.2.3 (server). This involves comparing Via branch, CSeq method and number, From/To tags, Call-ID, etc.
Source§

fn as_any(&self) -> &dyn Any

Provides a way to downcast this transaction object to its concrete type if needed. This is a standard Rust pattern for trait objects.
Source§

impl TransactionAsync for ServerNonInviteTransaction

Source§

fn process_event<'a>( &'a self, event_type: &'a str, message: Option<Message>, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'a>>

Asynchronously processes a significant event relevant to the transaction. Read more
Source§

fn send_command<'a>( &'a self, cmd: InternalTransactionCommand, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'a>>

Sends an InternalTransactionCommand to this transaction for asynchronous processing. Read more
Source§

fn original_request<'a>( &'a self, ) -> Pin<Box<dyn Future<Output = Option<Request>> + Send + 'a>>

Asynchronously retrieves the original SIP request that initiated this transaction. Read more
Source§

fn last_response<'a>( &'a self, ) -> Pin<Box<dyn Future<Output = Option<Response>> + Send + 'a>>

Asynchronously retrieves the last SIP response that was either sent (for server transactions) or received (for client transactions) by this transaction. Read more

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> Same for T

Source§

type Output = T

Should always be Self
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> TransactionExt for T
where T: Transaction + ?Sized,

Source§

fn as_client_transaction(&self) -> Option<&(dyn ClientTransaction + 'static)>

Attempts to downcast to a ClientTransaction reference. Read more
Source§

impl<T> TransactionExt for T
where T: Transaction + ?Sized,

Source§

fn as_server_transaction(&self) -> Option<&(dyn ServerTransaction + 'static)>

Attempts to downcast to a ServerTransaction reference. 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<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

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
Source§

impl<T> ErasedDestructor for T
where T: 'static,