[][src]Struct wikibase::Configuration

pub struct Configuration { /* fields omitted */ }

Configurations for Wikibase RS

The Configuration struct holds all the parameters that can can be customized. The api_url is the api endpoint or a particular Wikibase instance. It defaults to Wikidata.


impl Configuration[src]

pub fn new(user_agent_prefix: &str) -> Result<Configuration, WikibaseError>[src]

pub fn api_url(&self) -> &str[src]

pub fn set_api_url<S: Into<String>>(&mut self, api_url: S)[src]

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

Returns the complete user agent that is used for requests

The full user agent is a combination of the user agent prefix, that is set by a library and the Wikibase RS user agent. For example: my_bot/0.2 Wikibase-RS/1.0.2.

pub fn user_agent_prefix(&self) -> &str[src]

Trait Implementations

impl Debug for Configuration[src]

Auto Trait Implementations

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 

type Error = Infallible

The type returned in the event of a conversion error.

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

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

impl<T, U> TryInto for T where
    U: TryFrom<T>, 

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

The type returned in the event of a conversion error.

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