[][src]Struct gemini_fetch::Page

pub struct Page {
    pub url: String,
    pub header: Header,
    pub body: Option<String>,
}

Single Gemini page

See https://gemini.circumlunar.space/docs/specification.html for more information.

Fields

url: String

Page's URL

header: Header

Page's single header

body: Option<String>

Page's optional body

Implementations

impl Page[src]

pub async fn fetch(
    full_url: String,
    tls_validation: Option<ServerTLSValidation>
) -> Result<Page>
[src]

Fetch the given Gemini link

Does not follow redirects or other status codes

pub async fn fetch_and_handle_redirects(full_url: String) -> Result<Page>[src]

Fetch the given Gemini link while following redirects

Trait Implementations

impl Debug for Page[src]

Auto Trait Implementations

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, 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.