pub struct EChartOptions<X: AxisKindMarker, Y: AxisKindMarker> {
pub grid: Option<Grid>,
pub tooltip: Option<Tooltip>,
pub legend: Option<Legend>,
pub x_axis: Axis<X>,
pub y_axis: Axis<Y>,
pub extra: Option<Value>,
/* private fields */
}
Expand description
Root object for ECharts configuration
Fields§
§grid: Option<Grid>
Grid positioning and style options
tooltip: Option<Tooltip>
Tooltip options
legend: Option<Legend>
Legend options
x_axis: Axis<X>
X-axis options (Cartesian charts)
y_axis: Axis<Y>
Y-axis options (Cartesian charts)
extra: Option<Value>
Additional raw options not covered by this binding
Implementations§
Source§impl<X, Y> EChartOptions<X, Y>where
X: AxisKindMarker<AxisType = ValueAxis> + Serialize,
Y: AxisKindMarker<AxisType = ValueAxis> + Serialize,
trait that provides regression methods that are only supported when both x and y are numeric
impl<X, Y> EChartOptions<X, Y>where
X: AxisKindMarker<AxisType = ValueAxis> + Serialize,
Y: AxisKindMarker<AxisType = ValueAxis> + Serialize,
trait that provides regression methods that are only supported when both x and y are numeric
Sourcepub fn add_linear_regression_series<TData: Into<DatasetComponent<X, Y>>>(
self,
series_label: &str,
data: TData,
) -> Self
pub fn add_linear_regression_series<TData: Into<DatasetComponent<X, Y>>>( self, series_label: &str, data: TData, ) -> Self
Add a linear regression dataset
Source§impl<X, Y> EChartOptions<X, Y>
impl<X, Y> EChartOptions<X, Y>
pub fn new(x_axis: Axis<X>, y_axis: Axis<Y>) -> Self
pub fn enable_legend(self) -> Self
pub fn subtitle_str(self, subtitle: String) -> Self
pub fn title(self, title: Title) -> Self
pub fn x_axis_label(self, x: String) -> Self
pub fn y_axis_label(self, y: String) -> Self
pub fn add_dataset<TData: Into<DatasetComponent<X, Y>>>( self, data: TData, ) -> usize
Sourcepub fn add_dataset_visualisation(
self,
series_label: String,
series_type: SeriesType,
dataset_index: usize,
) -> Self
pub fn add_dataset_visualisation( self, series_label: String, series_type: SeriesType, dataset_index: usize, ) -> Self
Add visualization for a dataset. If no datasets exist, or dataset_index is out of range, no datasets will be added
pub fn add_series_direct(self, series: Series<X, Y>) -> Self
pub fn add_series<TData: Into<SeriesDataSource<X, Y>>>( self, series_type: SeriesType, series_label: String, data: TData, ) -> Self
pub fn build(self, width: Size, height: Size) -> ScriptTemplate<X, Y>
Trait Implementations§
Source§impl<X: Clone + AxisKindMarker, Y: Clone + AxisKindMarker> Clone for EChartOptions<X, Y>
impl<X: Clone + AxisKindMarker, Y: Clone + AxisKindMarker> Clone for EChartOptions<X, Y>
Source§fn clone(&self) -> EChartOptions<X, Y>
fn clone(&self) -> EChartOptions<X, Y>
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl<X: Debug + AxisKindMarker, Y: Debug + AxisKindMarker> Debug for EChartOptions<X, Y>
impl<X: Debug + AxisKindMarker, Y: Debug + AxisKindMarker> Debug for EChartOptions<X, Y>
Source§impl<X, Y> Default for EChartOptions<X, Y>
impl<X, Y> Default for EChartOptions<X, Y>
Source§impl<X, Y> Serialize for EChartOptions<X, Y>
impl<X, Y> Serialize for EChartOptions<X, Y>
Auto Trait Implementations§
impl<X, Y> Freeze for EChartOptions<X, Y>
impl<X, Y> RefUnwindSafe for EChartOptions<X, Y>where
X: RefUnwindSafe,
Y: RefUnwindSafe,
impl<X, Y> Send for EChartOptions<X, Y>
impl<X, Y> Sync for EChartOptions<X, Y>
impl<X, Y> Unpin for EChartOptions<X, Y>
impl<X, Y> UnwindSafe for EChartOptions<X, Y>where
X: UnwindSafe,
Y: UnwindSafe,
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