pub struct ScaleOrdinal<D, R> { /* private fields */ }Implementations§
Source§impl<D, R> ScaleOrdinal<D, R>
impl<D, R> ScaleOrdinal<D, R>
pub fn new(domain: Vec<D>, range: Vec<R>) -> ScaleOrdinal<D, R>
Sourcepub fn domain(self, domain: Vec<D>) -> ScaleOrdinal<D, R>
pub fn domain(self, domain: Vec<D>) -> ScaleOrdinal<D, R>
Set the domain to the specified array of values.
Sourcepub fn range(self, range: Vec<R>) -> ScaleOrdinal<D, R>
pub fn range(self, range: Vec<R>) -> ScaleOrdinal<D, R>
Set the range of the ordinal scale to the specified array of values.
Sourcepub fn unknown(self, unknown: R) -> ScaleOrdinal<D, R>
pub fn unknown(self, unknown: R) -> ScaleOrdinal<D, R>
Set the output value of the scale for unknown input values and returns this scale.
Trait Implementations§
Source§impl<D, R> Clone for ScaleOrdinal<D, R>
impl<D, R> Clone for ScaleOrdinal<D, R>
Source§fn clone(&self) -> ScaleOrdinal<D, R>
fn clone(&self) -> ScaleOrdinal<D, R>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<D, R> Default for ScaleOrdinal<D, R>
impl<D, R> Default for ScaleOrdinal<D, R>
Source§fn default() -> ScaleOrdinal<D, R>
fn default() -> ScaleOrdinal<D, R>
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl<D, R> Freeze for ScaleOrdinal<D, R>
impl<D, R> RefUnwindSafe for ScaleOrdinal<D, R>
impl<D, R> Send for ScaleOrdinal<D, R>
impl<D, R> Sync for ScaleOrdinal<D, R>
impl<D, R> Unpin for ScaleOrdinal<D, R>
impl<D, R> UnsafeUnpin for ScaleOrdinal<D, R>
impl<D, R> UnwindSafe for ScaleOrdinal<D, R>
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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian().