Struct RelativeTimeFormatPart

#[repr(transparent)]
pub struct RelativeTimeFormatPart { /* private fields */ }

A part of the formatted relative time returned by formatToParts().

MDN documentation

Implementations

impl RelativeTimeFormatPart

fn value(&self) -> JsString

The string value of this part.

impl RelativeTimeFormatPart

fn unit(&self) -> Option<JsString>

The unit used in this part (only for integer parts).

impl RelativeTimeFormatPart

fn type_(&self) -> RelativeTimeFormatPartType

The type of this part.

Trait Implementations

impl AsRef<JsValue> for RelativeTimeFormatPart

fn as_ref(&self) -> &JsValue

impl AsRef<Object> for RelativeTimeFormatPart

fn as_ref(&self) -> &Object

impl AsRef<RelativeTimeFormatPart> for RelativeTimeFormatPart

fn as_ref(&self) -> &RelativeTimeFormatPart

impl Clone for RelativeTimeFormatPart

fn clone(&self) -> Self

impl Debug for RelativeTimeFormatPart

fn fmt(&self, f: &mut Formatter<'_>) -> Result

impl Deref for RelativeTimeFormatPart

type Target = Object;
fn deref(&self) -> &Object

impl ErasableGeneric for RelativeTimeFormatPart

type Repr = JsValue;

impl From<JsValue> for RelativeTimeFormatPart

fn from(obj: JsValue) -> Self

impl FromWasmAbi for RelativeTimeFormatPart

type Abi = <JsValue as FromWasmAbi>::Abi;
unsafe fn from_abi(js: Self::Abi) -> Self

impl IntoJsGeneric for RelativeTimeFormatPart where RelativeTimeFormatPart: JsGeneric,

type JsCanon = RelativeTimeFormatPart;
fn to_js(self) -> RelativeTimeFormatPart

impl IntoWasmAbi for RelativeTimeFormatPart

type Abi = <JsValue as IntoWasmAbi>::Abi;
fn into_abi(self) -> Self::Abi

impl JsCast for RelativeTimeFormatPart

fn instanceof(val: &JsValue) -> bool
fn unchecked_from_js(val: JsValue) -> Self
fn unchecked_from_js_ref(val: &JsValue) -> &Self

impl LongRefFromWasmAbi for RelativeTimeFormatPart

type Abi = <JsValue as LongRefFromWasmAbi>::Abi;
type Anchor = RelativeTimeFormatPart;
unsafe fn long_ref_from_abi(js: Self::Abi) -> Self::Anchor

impl OptionFromWasmAbi for RelativeTimeFormatPart

fn is_none(abi: &Self::Abi) -> bool

impl OptionIntoWasmAbi for RelativeTimeFormatPart

fn none() -> Self::Abi

impl Promising for RelativeTimeFormatPart

type Resolution = RelativeTimeFormatPart;

impl RefFromWasmAbi for RelativeTimeFormatPart

type Abi = <JsValue as RefFromWasmAbi>::Abi;
type Anchor = ManuallyDrop<RelativeTimeFormatPart>;
unsafe fn ref_from_abi(js: Self::Abi) -> Self::Anchor

impl UpcastFrom<RelativeTimeFormatPart> for RelativeTimeFormatPart

impl WasmDescribe for RelativeTimeFormatPart

fn describe()

Auto Trait Implementations

impl Freeze for RelativeTimeFormatPart

impl RefUnwindSafe for RelativeTimeFormatPart

impl Send for RelativeTimeFormatPart

impl Sync for RelativeTimeFormatPart

impl Unpin for RelativeTimeFormatPart

impl UnsafeUnpin for RelativeTimeFormatPart

impl UnwindSafe for RelativeTimeFormatPart

Blanket Implementations

impl<P, T> Receiver for RelativeTimeFormatPart where P: Deref<Target = T> + ?Sized, T: ?Sized,

impl<S, T> Upcast<T> for RelativeTimeFormatPart where T: UpcastFrom<S> + ?Sized, S: ?Sized,

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

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

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

impl<T> CloneToUninit for RelativeTimeFormatPart where T: Clone,

impl<T> From<T> for RelativeTimeFormatPart

impl<T> JsGeneric for RelativeTimeFormatPart where T: ErasableGeneric<Repr = JsValue> + UpcastFrom<T> + Upcast<JsValue> + JsCast + 'static,

impl<T> ReturnWasmAbi for RelativeTimeFormatPart where T: IntoWasmAbi,

impl<T> ToOwned for RelativeTimeFormatPart where T: Clone,

impl<T> TryFromJsValue for RelativeTimeFormatPart where T: JsCast,

impl<T> VectorFromWasmAbi for RelativeTimeFormatPart where T: ErasableGeneric<Repr = JsValue> + WasmDescribe,

impl<T> VectorIntoWasmAbi for RelativeTimeFormatPart where T: ErasableGeneric<Repr = JsValue> + WasmDescribe,

impl<T> VectorRefIntoWasmAbi for RelativeTimeFormatPart where &'a T: for<'a> Into<JsValue>,

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

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

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