Struct hydrus_api::api_core::adding_urls::AddUrlRequestBuilder
source · [−]pub struct AddUrlRequestBuilder { /* private fields */ }
Expand description
A request builder that can be used to create a request for adding urls without having to fill a huge struct manually
Example:
use hydrus_api::api_core::adding_urls::AddUrlRequestBuilder;
use hydrus_api::api_core::common::ServiceIdentifier;
let request = AddUrlRequestBuilder::default()
.url("https://www.pixiv.net/member_illust.php?illust_id=83406361&mode=medium")
.add_tags(ServiceIdentifier::name("my tags"), vec!["ark mage".to_string(), "grinning".to_string()])
.show_destination_page(true)
.destination_page_name("Rusty Url Import")
.build();
Implementations
sourceimpl AddUrlRequestBuilder
impl AddUrlRequestBuilder
pub fn url<S: ToString>(self, url: S) -> Self
pub fn destination_page_key<S: ToString>(self, page_key: S) -> Self
pub fn destination_page_name<S: ToString>(self, page_name: S) -> Self
pub fn show_destination_page(self, show: bool) -> Self
pub fn build(self) -> AddUrlRequest
Trait Implementations
sourceimpl Default for AddUrlRequestBuilder
impl Default for AddUrlRequestBuilder
sourcefn default() -> AddUrlRequestBuilder
fn default() -> AddUrlRequestBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations
impl RefUnwindSafe for AddUrlRequestBuilder
impl Send for AddUrlRequestBuilder
impl Sync for AddUrlRequestBuilder
impl Unpin for AddUrlRequestBuilder
impl UnwindSafe for AddUrlRequestBuilder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
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
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more