pub struct UseBuilder { /* private fields */ }
Expand description
A convenience builder for constructing [UseDecl]s.
To use, call the constructor matching their capability type (UseBuilder::protocol, UseBuilder::directory, etc.), and then call methods to set properties. When done, call UseBuilder::build (or Into::into) to generate the [UseDecl].
Implementations§
Source§impl UseBuilder
impl UseBuilder
pub fn protocol() -> Self
pub fn service() -> Self
pub fn directory() -> Self
pub fn storage() -> Self
pub fn runner() -> Self
pub fn event_stream() -> Self
pub fn config() -> Self
pub fn config_type(self, type_: ConfigValueType) -> Self
pub fn name(self, name: &str) -> Self
pub fn path(self, path: &str) -> Self
pub fn target_name(self, name: &str) -> Self
pub fn from_dictionary(self, dictionary: &str) -> Self
pub fn source(self, source: UseSource) -> Self
pub fn source_static_child(self, source: &str) -> Self
pub fn availability(self, availability: Availability) -> Self
pub fn dependency(self, dependency: DependencyType) -> Self
pub fn rights(self, rights: Operations) -> Self
pub fn subdir(self, subdir: &str) -> Self
pub fn scope(self, scope: Vec<EventScope>) -> Self
pub fn filter(self, filter: BTreeMap<String, DictionaryValue>) -> Self
pub fn build(self) -> UseDecl
Trait Implementations§
Source§impl Debug for UseBuilder
impl Debug for UseBuilder
Source§impl From<UseBuilder> for UseDecl
impl From<UseBuilder> for UseDecl
Source§fn from(builder: UseBuilder) -> Self
fn from(builder: UseBuilder) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for UseBuilder
impl RefUnwindSafe for UseBuilder
impl Send for UseBuilder
impl Sync for UseBuilder
impl Unpin for UseBuilder
impl UnwindSafe for UseBuilder
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