Struct valgrind::VitStationRestClient
source · pub struct VitStationRestClient {
path_builder: RestPathBuilder,
api_token: Option<String>,
logger: RestClientLogger,
client: Client,
}
Fields§
§path_builder: RestPathBuilder
§api_token: Option<String>
§logger: RestClientLogger
§client: Client
Implementations§
source§impl VitStationRestClient
impl VitStationRestClient
pub fn new(address: String) -> Self
pub fn disable_logs(&mut self)
pub fn enable_logs(&mut self)
pub fn health(&self) -> Result<(), RestError>
pub fn health_raw(&self) -> Result<Response, RestError>
pub fn funds(&self) -> Result<Fund, RestError>
pub fn funds_raw(&self) -> Result<Response, RestError>
pub fn path_builder(&self) -> &RestPathBuilder
pub fn proposals(&self) -> Result<Vec<Proposal>, RestError>
pub fn review( &self, id: &str ) -> Result<HashMap<String, Vec<AdvisorReview>>, RestError>
pub fn review_raw(&self, id: &str) -> Result<Response, RestError>
pub fn challenge_raw(&self, id: &str) -> Result<Response, RestError>
pub fn proposals_raw(&self) -> Result<Response, RestError>
pub fn proposal(&self, id: &str) -> Result<Proposal, RestError>
pub fn proposal_raw(&self, id: &str) -> Result<Response, RestError>
pub fn challenges_raw(&self) -> Result<Response, RestError>
pub fn challenges(&self) -> Result<Vec<Challenge>, RestError>
pub fn fund(&self, id: &str) -> Result<Fund, RestError>
pub fn fund_raw(&self, id: &str) -> Result<Response, RestError>
pub fn genesis(&self) -> Result<Vec<u8>, RestError>
pub fn version(&self) -> Result<VitVersion, RestError>
pub fn version_raw(&self) -> Result<Response, RestError>
pub fn genesis_raw(&self) -> Result<Response, RestError>
pub fn get(&self, path: &str) -> Result<Response, Error>
fn get_and_verify_status_code(&self, path: &str) -> Result<Response, RestError>
fn verify_status_code(&self, response: &Response) -> Result<(), RestError>
pub fn disable_log(&mut self)
pub fn set_api_token(&mut self, token: String)
pub fn post(&self, path: &str, data: String) -> Result<Value, RestError>
Trait Implementations§
source§impl Clone for VitStationRestClient
impl Clone for VitStationRestClient
source§fn clone(&self) -> VitStationRestClient
fn clone(&self) -> VitStationRestClient
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl !RefUnwindSafe for VitStationRestClient
impl Send for VitStationRestClient
impl Sync for VitStationRestClient
impl Unpin for VitStationRestClient
impl !UnwindSafe for VitStationRestClient
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> Fake for T
impl<T> Fake for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request