pub struct Paint(pub HashMap<String, Value>);Expand description
Paint properties for a layer (flexible map of property name → JSON value).
Tuple Fields§
§0: HashMap<String, Value>Implementations§
Source§impl Paint
impl Paint
Sourcepub fn fill_color(&self) -> Option<PropertyValue<Color>>
pub fn fill_color(&self) -> Option<PropertyValue<Color>>
fill-color paint property.
Sourcepub fn fill_opacity(&self) -> Option<PropertyValue<f64>>
pub fn fill_opacity(&self) -> Option<PropertyValue<f64>>
fill-opacity paint property.
Sourcepub fn line_color(&self) -> Option<PropertyValue<Color>>
pub fn line_color(&self) -> Option<PropertyValue<Color>>
line-color paint property.
Sourcepub fn line_width(&self) -> Option<PropertyValue<f64>>
pub fn line_width(&self) -> Option<PropertyValue<f64>>
line-width paint property.
Sourcepub fn line_opacity(&self) -> Option<PropertyValue<f64>>
pub fn line_opacity(&self) -> Option<PropertyValue<f64>>
line-opacity paint property.
Sourcepub fn circle_color(&self) -> Option<PropertyValue<Color>>
pub fn circle_color(&self) -> Option<PropertyValue<Color>>
circle-color paint property.
Sourcepub fn circle_radius(&self) -> Option<PropertyValue<f64>>
pub fn circle_radius(&self) -> Option<PropertyValue<f64>>
circle-radius paint property.
Sourcepub fn raster_opacity(&self) -> Option<PropertyValue<f64>>
pub fn raster_opacity(&self) -> Option<PropertyValue<f64>>
raster-opacity paint property.
Sourcepub fn raster_hue_rotate(&self) -> Option<PropertyValue<f64>>
pub fn raster_hue_rotate(&self) -> Option<PropertyValue<f64>>
raster-hue-rotate paint property.
Sourcepub fn background_color(&self) -> Option<PropertyValue<Color>>
pub fn background_color(&self) -> Option<PropertyValue<Color>>
background-color paint property.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Paint
impl<'de> Deserialize<'de> for Paint
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
Auto Trait Implementations§
impl Freeze for Paint
impl RefUnwindSafe for Paint
impl Send for Paint
impl Sync for Paint
impl Unpin for Paint
impl UnsafeUnpin for Paint
impl UnwindSafe for Paint
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> 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 more