pub struct UsageBuilder { /* private fields */ }Expand description
Builder for Usage.
Implementations§
Source§impl UsageBuilder
impl UsageBuilder
pub fn name(self, value: impl Into<String>) -> Self
pub fn description(self, value: impl Into<String>) -> Self
pub fn derived_from(self, values: impl IntoIterator<Item = Resource>) -> Self
pub fn add_derived_from(self, value: Resource) -> Self
pub fn generated_by(self, values: impl IntoIterator<Item = Resource>) -> Self
pub fn add_generated_by(self, value: Resource) -> Self
pub fn measures(self, values: impl IntoIterator<Item = Resource>) -> Self
pub fn add_measure(self, value: Resource) -> Self
Sourcepub fn extension(self, predicate: Iri, value: Term) -> Self
pub fn extension(self, predicate: Iri, value: Term) -> Self
Attach a non-SBOL annotation triple. The predicate must be outside the SBOL, PROV, and OM vocabularies; predicates inside those vocabularies belong on dedicated setters and are emitted twice if pushed here.
pub fn entity(self, value: Resource) -> Self
pub fn had_role(self, values: impl IntoIterator<Item = Iri>) -> Self
pub fn add_had_role(self, value: Iri) -> Self
pub fn build(self) -> Result<Usage, BuildError>
Trait Implementations§
Source§impl Clone for UsageBuilder
impl Clone for UsageBuilder
Source§fn clone(&self) -> UsageBuilder
fn clone(&self) -> UsageBuilder
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for UsageBuilder
impl RefUnwindSafe for UsageBuilder
impl Send for UsageBuilder
impl Sync for UsageBuilder
impl Unpin for UsageBuilder
impl UnsafeUnpin for UsageBuilder
impl UnwindSafe for UsageBuilder
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