aws_sdk_quicksight/types/_small_multiples_axis_properties.rs
1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2
3/// <p>Configures the properties of a chart's axes that are used by small multiples panels.</p>
4#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct SmallMultiplesAxisProperties {
7 /// <p>Determines whether scale of the axes are shared or independent. The default value is <code>SHARED</code>.</p>
8 pub scale: ::std::option::Option<crate::types::SmallMultiplesAxisScale>,
9 /// <p>Defines the placement of the axis. By default, axes are rendered <code>OUTSIDE</code> of the panels. Axes with <code>INDEPENDENT</code> scale are rendered <code>INSIDE</code> the panels.</p>
10 pub placement: ::std::option::Option<crate::types::SmallMultiplesAxisPlacement>,
11}
12impl SmallMultiplesAxisProperties {
13 /// <p>Determines whether scale of the axes are shared or independent. The default value is <code>SHARED</code>.</p>
14 pub fn scale(&self) -> ::std::option::Option<&crate::types::SmallMultiplesAxisScale> {
15 self.scale.as_ref()
16 }
17 /// <p>Defines the placement of the axis. By default, axes are rendered <code>OUTSIDE</code> of the panels. Axes with <code>INDEPENDENT</code> scale are rendered <code>INSIDE</code> the panels.</p>
18 pub fn placement(&self) -> ::std::option::Option<&crate::types::SmallMultiplesAxisPlacement> {
19 self.placement.as_ref()
20 }
21}
22impl SmallMultiplesAxisProperties {
23 /// Creates a new builder-style object to manufacture [`SmallMultiplesAxisProperties`](crate::types::SmallMultiplesAxisProperties).
24 pub fn builder() -> crate::types::builders::SmallMultiplesAxisPropertiesBuilder {
25 crate::types::builders::SmallMultiplesAxisPropertiesBuilder::default()
26 }
27}
28
29/// A builder for [`SmallMultiplesAxisProperties`](crate::types::SmallMultiplesAxisProperties).
30#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
31#[non_exhaustive]
32pub struct SmallMultiplesAxisPropertiesBuilder {
33 pub(crate) scale: ::std::option::Option<crate::types::SmallMultiplesAxisScale>,
34 pub(crate) placement: ::std::option::Option<crate::types::SmallMultiplesAxisPlacement>,
35}
36impl SmallMultiplesAxisPropertiesBuilder {
37 /// <p>Determines whether scale of the axes are shared or independent. The default value is <code>SHARED</code>.</p>
38 pub fn scale(mut self, input: crate::types::SmallMultiplesAxisScale) -> Self {
39 self.scale = ::std::option::Option::Some(input);
40 self
41 }
42 /// <p>Determines whether scale of the axes are shared or independent. The default value is <code>SHARED</code>.</p>
43 pub fn set_scale(mut self, input: ::std::option::Option<crate::types::SmallMultiplesAxisScale>) -> Self {
44 self.scale = input;
45 self
46 }
47 /// <p>Determines whether scale of the axes are shared or independent. The default value is <code>SHARED</code>.</p>
48 pub fn get_scale(&self) -> &::std::option::Option<crate::types::SmallMultiplesAxisScale> {
49 &self.scale
50 }
51 /// <p>Defines the placement of the axis. By default, axes are rendered <code>OUTSIDE</code> of the panels. Axes with <code>INDEPENDENT</code> scale are rendered <code>INSIDE</code> the panels.</p>
52 pub fn placement(mut self, input: crate::types::SmallMultiplesAxisPlacement) -> Self {
53 self.placement = ::std::option::Option::Some(input);
54 self
55 }
56 /// <p>Defines the placement of the axis. By default, axes are rendered <code>OUTSIDE</code> of the panels. Axes with <code>INDEPENDENT</code> scale are rendered <code>INSIDE</code> the panels.</p>
57 pub fn set_placement(mut self, input: ::std::option::Option<crate::types::SmallMultiplesAxisPlacement>) -> Self {
58 self.placement = input;
59 self
60 }
61 /// <p>Defines the placement of the axis. By default, axes are rendered <code>OUTSIDE</code> of the panels. Axes with <code>INDEPENDENT</code> scale are rendered <code>INSIDE</code> the panels.</p>
62 pub fn get_placement(&self) -> &::std::option::Option<crate::types::SmallMultiplesAxisPlacement> {
63 &self.placement
64 }
65 /// Consumes the builder and constructs a [`SmallMultiplesAxisProperties`](crate::types::SmallMultiplesAxisProperties).
66 pub fn build(self) -> crate::types::SmallMultiplesAxisProperties {
67 crate::types::SmallMultiplesAxisProperties {
68 scale: self.scale,
69 placement: self.placement,
70 }
71 }
72}