Struct svd_rs::cluster::ClusterInfoBuilder
source · [−]pub struct ClusterInfoBuilder { /* private fields */ }
Expand description
Builder for ClusterInfo
Implementations
sourceimpl ClusterInfoBuilder
impl ClusterInfoBuilder
sourcepub fn description(self, value: Option<String>) -> Self
pub fn description(self, value: Option<String>) -> Self
Set the description of the cluster.
sourcepub fn alternate_cluster(self, value: Option<String>) -> Self
pub fn alternate_cluster(self, value: Option<String>) -> Self
Set the alternate cluster.
sourcepub fn header_struct_name(self, value: Option<String>) -> Self
pub fn header_struct_name(self, value: Option<String>) -> Self
Set the struct type name of the cluster. If not specified, the name of the cluster should be used.
sourcepub fn address_offset(self, value: u32) -> Self
pub fn address_offset(self, value: u32) -> Self
Set the address_offset of the cluster, relative to the baseAddress
of the peripheral.
sourcepub fn default_register_properties(self, value: RegisterProperties) -> Self
pub fn default_register_properties(self, value: RegisterProperties) -> Self
Set the default_register_properties of the cluster.
sourcepub fn children(self, value: Vec<RegisterCluster>) -> Self
pub fn children(self, value: Vec<RegisterCluster>) -> Self
Set the children of the cluster.
sourcepub fn derived_from(self, value: Option<String>) -> Self
pub fn derived_from(self, value: Option<String>) -> Self
Set the derived_from of the cluster.
sourcepub fn build(self, lvl: ValidateLevel) -> Result<ClusterInfo, SvdError>
pub fn build(self, lvl: ValidateLevel) -> Result<ClusterInfo, SvdError>
Validate and build a ClusterInfo
.
Trait Implementations
sourceimpl Clone for ClusterInfoBuilder
impl Clone for ClusterInfoBuilder
sourcefn clone(&self) -> ClusterInfoBuilder
fn clone(&self) -> ClusterInfoBuilder
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for ClusterInfoBuilder
impl Debug for ClusterInfoBuilder
sourceimpl Default for ClusterInfoBuilder
impl Default for ClusterInfoBuilder
sourcefn default() -> ClusterInfoBuilder
fn default() -> ClusterInfoBuilder
Returns the “default value” for a type. Read more
sourceimpl From<ClusterInfo> for ClusterInfoBuilder
impl From<ClusterInfo> for ClusterInfoBuilder
sourcefn from(c: ClusterInfo) -> Self
fn from(c: ClusterInfo) -> Self
Converts to this type from the input type.
sourceimpl PartialEq<ClusterInfoBuilder> for ClusterInfoBuilder
impl PartialEq<ClusterInfoBuilder> for ClusterInfoBuilder
sourcefn eq(&self, other: &ClusterInfoBuilder) -> bool
fn eq(&self, other: &ClusterInfoBuilder) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &ClusterInfoBuilder) -> bool
fn ne(&self, other: &ClusterInfoBuilder) -> bool
This method tests for !=
.
impl StructuralPartialEq for ClusterInfoBuilder
Auto Trait Implementations
impl RefUnwindSafe for ClusterInfoBuilder
impl Send for ClusterInfoBuilder
impl Sync for ClusterInfoBuilder
impl Unpin for ClusterInfoBuilder
impl UnwindSafe for ClusterInfoBuilder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more