Struct stun_codec::rfc5389::attributes::ErrorCode[][src]

pub struct ErrorCode { /* fields omitted */ }

ERROR-CODE attribute.

See RFC 5389 -- 15.6. ERROR-CODE about this attribute.

Methods

impl ErrorCode
[src]

CODEPOINT: u16 = 9

The codepoint of the type of the attribute.

Makes a new ErrorCode instance.

Errors

Note that the value of code must be in range of 300..600. If the value is out-of-range this will return an ErrorKind::InvalidInput error.

Returns the code of this error.

Returns the reason phrase of this error.

Trait Implementations

impl Debug for ErrorCode
[src]

Formats the value using the given formatter. Read more

impl Clone for ErrorCode
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl PartialEq for ErrorCode
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Eq for ErrorCode
[src]

impl Hash for ErrorCode
[src]

Feeds this value into the given [Hasher]. Read more

Feeds a slice of this type into the given [Hasher]. Read more

impl Attribute for ErrorCode
[src]

The decoder of the value part of the attribute.

The encoder of the value part of the attribute.

Returns the type of the attribute.

This method is called before encoding the attribute. Read more

This method is called after decoding the attribute and before being appended to the given message. Read more

impl From<Error> for ErrorCode
[src]

Performs the conversion.

impl From<TryAlternate> for ErrorCode
[src]

Performs the conversion.

impl From<BadRequest> for ErrorCode
[src]

Performs the conversion.

impl From<Unauthorized> for ErrorCode
[src]

Performs the conversion.

impl From<UnknownAttribute> for ErrorCode
[src]

Performs the conversion.

impl From<StaleNonce> for ErrorCode
[src]

Performs the conversion.

impl From<ServerError> for ErrorCode
[src]

Performs the conversion.

impl From<ErrorCode> for Attribute
[src]

Performs the conversion.

impl TryAsRef<ErrorCode> for Attribute
[src]

Attempts to convert self to a reference to T. Read more

impl From<Forbidden> for ErrorCode
[src]

Performs the conversion.

impl From<AllocationMismatch> for ErrorCode
[src]

Performs the conversion.

impl From<WrongCredentials> for ErrorCode
[src]

Performs the conversion.

impl From<UnsupportedTransportProtocol> for ErrorCode
[src]

Performs the conversion.

impl From<AllocationQuotaReached> for ErrorCode
[src]

Performs the conversion.

impl From<InsufficientCapacity> for ErrorCode
[src]

Performs the conversion.

Auto Trait Implementations

impl Send for ErrorCode

impl Sync for ErrorCode