pub struct Encoding {
pub x: Option<EncodingDef>,
pub y: Option<EncodingDef>,
pub color: Option<EncodingDef>,
pub size: Option<EncodingDef>,
pub shape: Option<EncodingDef>,
pub opacity: Option<EncodingDef>,
pub text: Option<EncodingDef>,
pub tooltip: Option<EncodingDef>,
pub detail: Option<EncodingDef>,
pub order: Option<EncodingDef>,
pub row: Option<EncodingDef>,
pub column: Option<EncodingDef>,
}Expand description
Chart encoding specification
Fields§
§x: Option<EncodingDef>§y: Option<EncodingDef>§color: Option<EncodingDef>§size: Option<EncodingDef>§shape: Option<EncodingDef>§opacity: Option<EncodingDef>§text: Option<EncodingDef>§tooltip: Option<EncodingDef>§detail: Option<EncodingDef>§order: Option<EncodingDef>§row: Option<EncodingDef>§column: Option<EncodingDef>Implementations§
Source§impl Encoding
impl Encoding
Sourcepub fn validate_for_mark(&self, mark: &MarkType) -> Result<(), ValidationError>
pub fn validate_for_mark(&self, mark: &MarkType) -> Result<(), ValidationError>
Validate encoding for mark type
Sourcepub fn complexity(&self) -> f64
pub fn complexity(&self) -> f64
Calculate encoding complexity
Source§impl Encoding
impl Encoding
Sourcepub fn get_field_encodings(&self) -> Vec<(String, &PositionEncoding)>
pub fn get_field_encodings(&self) -> Vec<(String, &PositionEncoding)>
Returns a vector of field encodings with their names
§Returns
Returns a vector of tuples containing field names and their position encodings
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Encoding
impl<'de> Deserialize<'de> for Encoding
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for Encoding
Auto Trait Implementations§
impl Freeze for Encoding
impl RefUnwindSafe for Encoding
impl Send for Encoding
impl Sync for Encoding
impl Unpin for Encoding
impl UnwindSafe for Encoding
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FromFormData for Twhere
T: DeserializeOwned,
impl<T> FromFormData for Twhere
T: DeserializeOwned,
Source§fn from_event(ev: &Event) -> Result<T, FromFormDataError>
fn from_event(ev: &Event) -> Result<T, FromFormDataError>
Tries to deserialize the data, given only the
submit event.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> Key for Twhere
T: Clone,
impl<T> Key for Twhere
T: Clone,
Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> SerializableKey for T
impl<T> SerializableKey for T
Source§impl<T> StorageAccess<T> for T
impl<T> StorageAccess<T> for T
Source§fn as_borrowed(&self) -> &T
fn as_borrowed(&self) -> &T
Borrows the value.
Source§fn into_taken(self) -> T
fn into_taken(self) -> T
Takes the value.