[][src]Struct enqueuemail::Parts

pub struct Parts {
    pub url: Url,
    pub host: Host<String>,
    pub port: u16,
    pub addr: SocketAddr,
    pub domain: String,
    pub path: String,
    pub query: String,
    pub fragment: String,
}

The hierarchical sequence of components of a URI.

Each URI begins with a scheme name that refers to a specification for assigning identifiers within that scheme. As such, the URI syntax is a federated and extensible naming system wherein each scheme's specification may further restrict the syntax and semantics of identifiers using that scheme. The URI generic syntax is a superset of the syntax of all URI schemes. It was first defined in RFC 2396, published in August 1998, and finalized in RFC 3986, published in January 2005.

URI syntax

Fields

url: Url

A Uniform Resource Locator (URL), colloquially termed a web address, is a reference to a web resource that specifies its location on a computer network and a mechanism for retrieving it. A URL is a specific type of Uniform Resource Identifier (URI).

host: Host<String>

The registered host name of an URL.

port: u16

The port number of the URL.

addr: SocketAddr

An internet socket address, either IPv4 or IPv6.

domain: String

The domain name (not an IP address) of the given host.

path: String

the path for this URL, as a percent-encoded ASCII string. For cannot-be-a-base URLs, this is an arbitrary string that doesn’t start with '/'. For other URLs, this starts with a '/' slash and continues with slash-separated path segments.

query: String

The URL's query string, if any, as a percent-encoded ASCII string.

fragment: String

A fragment is the part of the URL after the # symbol. The fragment is optional and, if present, contains a fragment identifier that identifies a secondary resource, such as a section heading of a document.

In HTML, the fragment identifier is usually the id attribute of a an element that is scrolled to on load. Browsers typically will not send the fragment portion of a URL to the server.

Implementations

impl Parts[src]

pub fn http_request(&self) -> String[src]

Create a bare bones HTTP GET request.

The reference is the RFC7230

Trait Implementations

impl Clone for Parts[src]

impl Debug for Parts[src]

impl<'_> TryFrom<&'_ Options> for Parts[src]

type Error = Box<dyn Error>

The type returned in the event of a conversion error.

impl<'_> TryFrom<&'_ Url> for Parts[src]

type Error = Box<dyn Error>

The type returned in the event of a conversion error.

impl<'_> TryFrom<&'_ str> for Parts[src]

type Error = Box<dyn Error>

The type returned in the event of a conversion error.

Auto Trait Implementations

impl RefUnwindSafe for Parts

impl Send for Parts

impl Sync for Parts

impl Unpin for Parts

impl UnwindSafe for Parts

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> Sealed<T> for T where
    T: ?Sized

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,