|
@@ -627,6 +627,10 @@ impl Data {
|
|
|
pub fn is_string(&self) -> bool {
|
|
|
matches!(self, Self::String(_))
|
|
|
}
|
|
|
+ /// Is Data a bool
|
|
|
+ pub fn is_bool(&self) -> bool {
|
|
|
+ matches!(self, Self::Bool(_))
|
|
|
+ }
|
|
|
/// Is Data a signed/unsigned integer or float
|
|
|
///
|
|
|
/// JSON Number's can hold both a whole number (i.e. signed/unsigned integers) and floats
|