[][src]Struct kagura::Attributes

pub struct Attributes {
    pub attributes: Attributes,
    // some fields omitted
}

Attributes for Html

Fields

attributes: Attributes

Methods

impl Attributes[src]

pub fn new() -> Self[src]

Creates new empty Attributs

pub fn string(self, name: impl Into<String>, value: impl Into<String>) -> Self[src]

Adds attribute having string value

pub fn nut(self, name: impl Into<String>, value: u64) -> Self[src]

Adds attribute having natural number

pub fn int(self, name: impl Into<String>, value: i64) -> Self[src]

Adds attribute having integer

pub fn flag(self, name: impl Into<String>) -> Self[src]

Adds attribute not hanving any value

pub fn delimit_with(self, dlm: impl Into<String>) -> Self[src]

Sets delimiter for last attribute

Example

/* This is creation of attribute: foo="x, y, z" */
Attributes::new()
    .string("foo", "x")
    .string("foo", "y")
    .string("foo", "z")
    .delimit_with(",");

pub fn checked(self) -> Self[src]

pub fn class(self, name: impl Into<String>) -> Self[src]

pub fn draggable(self, val: bool) -> Self[src]

pub fn hidden(self) -> Self[src]

pub fn href(self, uri: impl Into<String>) -> Self[src]

pub fn id(self, name: impl Into<String>) -> Self[src]

pub fn placeholder(self, value: impl Into<String>) -> Self[src]

pub fn selected(self) -> Self[src]

pub fn style(self, name: impl Into<String>, value: impl Into<String>) -> Self[src]

pub fn title(self, name: impl Into<String>) -> Self[src]

pub fn type_(self, name: impl Into<String>) -> Self[src]

pub fn value(self, value: impl Into<String>) -> Self[src]

Auto Trait Implementations

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,