Struct inth_oauth2::client::response::JsonObjectHelper [] [src]

pub struct JsonObjectHelper<'a>(pub &'a Object);

JSON object helper for response parsing.

Methods

impl<'a> JsonObjectHelper<'a>

fn get_string_option(&self, key: &'static str) -> Option<&'a str>

Gets a field as a string or returns None.

fn get_string(&self, key: &'static str) -> Result<&'a str, ParseError>

Gets a field as a string or fails with ParseError::ExpectedFieldType.

fn get_i64_option(&self, key: &'static str) -> Option<i64>

Gets a field as an i64 or returns None.

fn get_i64(&self, key: &'static str) -> Result<i64, ParseError>

Gets a field as an i64 or fails with ParseError::ExpectedFieldType.

Trait Implementations

Derived Implementations

impl<'a> PartialEq for JsonObjectHelper<'a>

fn eq(&self, __arg_0: &JsonObjectHelper<'a>) -> bool

fn ne(&self, __arg_0: &JsonObjectHelper<'a>) -> bool

impl<'a> Copy for JsonObjectHelper<'a>

impl<'a> Clone for JsonObjectHelper<'a>

fn clone(&self) -> JsonObjectHelper<'a>

1.0.0fn clone_from(&mut self, source: &Self)

impl<'a> Debug for JsonObjectHelper<'a>

fn fmt(&self, __arg_0: &mut Formatter) -> Result