Enum json_gettext::JSONGetTextValue [−][src]
Represents any valid JSON value. Reference can also be wrapped.
Variants
Str(&'a str)
JSONValue(Value)
JSONValueRef(&'a Value)
Implementations
impl<'a> JSONGetTextValue<'a>
[src]
pub fn from_str<S: AsRef<str> + ?Sized>(s: &'a S) -> JSONGetTextValue<'a>
[src]
pub fn from_string<S: Into<String>>(s: S) -> JSONGetTextValue<'static>
[src]
pub fn from_json_str<S: AsRef<str>>(
s: S
) -> Result<JSONGetTextValue<'static>, JSONGetTextValueError>
[src]
s: S
) -> Result<JSONGetTextValue<'static>, JSONGetTextValueError>
pub fn from_bool(b: bool) -> JSONGetTextValue<'static>
[src]
pub fn from_i8(n: i8) -> JSONGetTextValue<'static>
[src]
pub fn from_i16(n: i16) -> JSONGetTextValue<'static>
[src]
pub fn from_i32(n: i32) -> JSONGetTextValue<'static>
[src]
pub fn from_i64(n: i64) -> JSONGetTextValue<'static>
[src]
pub fn from_i128(
n: i128
) -> Result<JSONGetTextValue<'static>, JSONGetTextValueError>
[src]
n: i128
) -> Result<JSONGetTextValue<'static>, JSONGetTextValueError>
pub fn from_isize(n: isize) -> JSONGetTextValue<'static>
[src]
pub fn from_u8(n: u8) -> JSONGetTextValue<'static>
[src]
pub fn from_u16(n: u16) -> JSONGetTextValue<'static>
[src]
pub fn from_u32(n: u32) -> JSONGetTextValue<'static>
[src]
pub fn from_u64(n: u64) -> JSONGetTextValue<'static>
[src]
pub fn from_u128(
n: u128
) -> Result<JSONGetTextValue<'static>, JSONGetTextValueError>
[src]
n: u128
) -> Result<JSONGetTextValue<'static>, JSONGetTextValueError>
pub fn from_usize(n: usize) -> JSONGetTextValue<'static>
[src]
pub fn from_f32(n: f32) -> JSONGetTextValue<'static>
[src]
pub fn from_f64(n: f64) -> JSONGetTextValue<'static>
[src]
pub fn from_json_value(v: Value) -> JSONGetTextValue<'static>
[src]
pub fn from_json_value_ref(v: &'a Value) -> JSONGetTextValue<'a>
[src]
pub fn from_serializable<T: Serialize>(
v: T
) -> Result<JSONGetTextValue<'static>, Error>
[src]
v: T
) -> Result<JSONGetTextValue<'static>, Error>
pub fn null() -> JSONGetTextValue<'static>
[src]
impl<'a> JSONGetTextValue<'a>
[src]
pub fn to_json_string(&self) -> String
[src]
Convert to a string for JSON format.
pub fn to_json(&self) -> String
[src]
👎 Deprecated since 3.2.0:
Please use the to_json_string
function instead
Convert to a string for JSON format.
pub fn as_str(&self) -> Option<&str>
[src]
Convert to a string slice if it is possible (if it is a string).
pub fn clone_borrowed(&self) -> JSONGetTextValue<'_>
[src]
Clone the reference of this JSONGetTextValue
instance.
impl<'a> JSONGetTextValue<'a>
[src]
pub fn parse_json<S: AsRef<str>>(
s: S
) -> Result<JSONGetTextValue<'static>, JSONGetTextValueError>
[src]
s: S
) -> Result<JSONGetTextValue<'static>, JSONGetTextValueError>
Trait Implementations
impl<'a> Clone for JSONGetTextValue<'a>
[src]
fn clone(&self) -> JSONGetTextValue<'a>
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<'a> Debug for JSONGetTextValue<'a>
[src]
impl<'de> Deserialize<'de> for JSONGetTextValue<'de>
[src]
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error> where
D: Deserializer<'de>,
[src]
D: Deserializer<'de>,
impl<'a> Display for JSONGetTextValue<'a>
[src]
impl<'a> From<&'a Value> for JSONGetTextValue<'a>
[src]
fn from(v: &'a Value) -> JSONGetTextValue<'a>
[src]
impl<'a> From<&'a str> for JSONGetTextValue<'a>
[src]
fn from(v: &'a str) -> JSONGetTextValue<'a>
[src]
impl From<String> for JSONGetTextValue<'static>
[src]
fn from(v: String) -> JSONGetTextValue<'static>
[src]
impl From<Value> for JSONGetTextValue<'static>
[src]
fn from(v: Value) -> JSONGetTextValue<'static>
[src]
impl From<bool> for JSONGetTextValue<'static>
[src]
fn from(v: bool) -> JSONGetTextValue<'static>
[src]
impl From<f32> for JSONGetTextValue<'static>
[src]
fn from(v: f32) -> JSONGetTextValue<'static>
[src]
impl From<f64> for JSONGetTextValue<'static>
[src]
fn from(v: f64) -> JSONGetTextValue<'static>
[src]
impl From<i16> for JSONGetTextValue<'static>
[src]
fn from(v: i16) -> JSONGetTextValue<'static>
[src]
impl From<i32> for JSONGetTextValue<'static>
[src]
fn from(v: i32) -> JSONGetTextValue<'static>
[src]
impl From<i64> for JSONGetTextValue<'static>
[src]
fn from(v: i64) -> JSONGetTextValue<'static>
[src]
impl From<i8> for JSONGetTextValue<'static>
[src]
fn from(v: i8) -> JSONGetTextValue<'static>
[src]
impl From<isize> for JSONGetTextValue<'static>
[src]
fn from(v: isize) -> JSONGetTextValue<'static>
[src]
impl From<u16> for JSONGetTextValue<'static>
[src]
fn from(v: u16) -> JSONGetTextValue<'static>
[src]
impl From<u32> for JSONGetTextValue<'static>
[src]
fn from(v: u32) -> JSONGetTextValue<'static>
[src]
impl From<u64> for JSONGetTextValue<'static>
[src]
fn from(v: u64) -> JSONGetTextValue<'static>
[src]
impl From<u8> for JSONGetTextValue<'static>
[src]
fn from(v: u8) -> JSONGetTextValue<'static>
[src]
impl From<usize> for JSONGetTextValue<'static>
[src]
fn from(v: usize) -> JSONGetTextValue<'static>
[src]
impl FromStr for JSONGetTextValue<'static>
[src]
type Err = ()
The associated error which can be returned from parsing.
fn from_str(s: &str) -> Result<Self, Self::Err>
[src]
impl<'a> PartialEq<JSONGetTextValue<'a>> for JSONGetTextValue<'a>
[src]
fn eq(&self, other: &JSONGetTextValue<'a>) -> bool
[src]
fn ne(&self, other: &JSONGetTextValue<'a>) -> bool
[src]
impl<'a> PartialEq<JSONGetTextValue<'a>> for str
[src]
fn eq(&self, other: &JSONGetTextValue<'_>) -> bool
[src]
#[must_use]pub fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
impl<'a> PartialEq<JSONGetTextValue<'a>> for &'a str
[src]
fn eq(&self, other: &JSONGetTextValue<'_>) -> bool
[src]
#[must_use]pub fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
impl<'a> PartialEq<str> for JSONGetTextValue<'a>
[src]
impl<'a> Serialize for JSONGetTextValue<'a>
[src]
impl<'a> StructuralPartialEq for JSONGetTextValue<'a>
[src]
impl TryFrom<i128> for JSONGetTextValue<'static>
[src]
type Error = JSONGetTextValueError
The type returned in the event of a conversion error.
fn try_from(v: i128) -> Result<JSONGetTextValue<'static>, JSONGetTextValueError>
[src]
impl TryFrom<u128> for JSONGetTextValue<'static>
[src]
type Error = JSONGetTextValueError
The type returned in the event of a conversion error.
fn try_from(v: u128) -> Result<JSONGetTextValue<'static>, JSONGetTextValueError>
[src]
Auto Trait Implementations
impl<'a> RefUnwindSafe for JSONGetTextValue<'a>
impl<'a> Send for JSONGetTextValue<'a>
impl<'a> Sync for JSONGetTextValue<'a>
impl<'a> Unpin for JSONGetTextValue<'a>
impl<'a> UnwindSafe for JSONGetTextValue<'a>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,