Enum trust_dns::rr::dns_class::DNSClass [] [src]

pub enum DNSClass {
    IN,
    CH,
    HS,
    NONE,
    ANY,
    OPT(u16),
}

Variants

Methods

impl DNSClass
[src]

Convert from &str to DNSClass

use trust_dns::rr::dns_class::DNSClass;

let var: DNSClass = DNSClass::from_str("IN").unwrap();
assert_eq!(DNSClass::IN, var);

Convert from u16 to DNSClass

use trust_dns::rr::dns_class::DNSClass;

let var = DNSClass::from_u16(1).unwrap();
assert_eq!(DNSClass::IN, var);

Trait Implementations

impl Debug for DNSClass
[src]

Formats the value using the given formatter.

impl PartialEq for DNSClass
[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 DNSClass
[src]

impl Hash for DNSClass
[src]

Feeds this value into the state given, updating the hasher as necessary.

Feeds a slice of this type into the state provided.

impl Copy for DNSClass
[src]

impl Clone for DNSClass
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl BinSerializable<DNSClass> for DNSClass
[src]

impl PartialOrd<DNSClass> for DNSClass
[src]

This method returns an ordering between self and other values if one exists. Read more

This method tests less than (for self and other) and is used by the < operator. Read more

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more

This method tests greater than (for self and other) and is used by the > operator. Read more

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more

impl Ord for DNSClass
[src]

This method returns an Ordering between self and other. Read more