pub struct SourceBuilder { /* private fields */ }Expand description
Implementations§
Source§impl SourceBuilder
impl SourceBuilder
Sourcepub fn new() -> Self
pub fn new() -> Self
Build an empty SourceBuilder.
Sourcepub fn with_source(self, source: impl Into<String>) -> Self
pub fn with_source(self, source: impl Into<String>) -> Self
Set the loader name.
Sourcepub fn with_resource(self, resource: impl Into<String>) -> Self
pub fn with_resource(self, resource: impl Into<String>) -> Self
Set the resource address.
Sourcepub fn with_options(self, options: Options) -> Self
pub fn with_options(self, options: Options) -> Self
Replace the loader options.
Sourcepub fn with_option<K: Into<String>, V: Into<OptionValue>>(
self,
key: K,
value: V,
) -> Self
pub fn with_option<K: Into<String>, V: Into<OptionValue>>( self, key: K, value: V, ) -> Self
Set a single loader option.
Sourcepub fn with_resource_colon(self, resource_colon: bool) -> Self
pub fn with_resource_colon(self, resource_colon: bool) -> Self
Set whether the : separator is present before the resource.
Trait Implementations§
Source§impl Clone for SourceBuilder
impl Clone for SourceBuilder
Source§fn clone(&self) -> SourceBuilder
fn clone(&self) -> SourceBuilder
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 moreSource§impl Debug for SourceBuilder
impl Debug for SourceBuilder
Source§impl Default for SourceBuilder
impl Default for SourceBuilder
Source§fn default() -> SourceBuilder
fn default() -> SourceBuilder
Returns the “default value” for a type. Read more
Source§impl From<Source> for SourceBuilder
impl From<Source> for SourceBuilder
Source§impl PartialEq for SourceBuilder
impl PartialEq for SourceBuilder
impl StructuralPartialEq for SourceBuilder
Source§impl TryFrom<&String> for SourceBuilder
impl TryFrom<&String> for SourceBuilder
Source§impl TryFrom<&str> for SourceBuilder
impl TryFrom<&str> for SourceBuilder
Auto Trait Implementations§
impl Freeze for SourceBuilder
impl RefUnwindSafe for SourceBuilder
impl Send for SourceBuilder
impl Sync for SourceBuilder
impl Unpin for SourceBuilder
impl UnsafeUnpin for SourceBuilder
impl UnwindSafe for SourceBuilder
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