Struct keeshond_datapack::source::SourceManager [−][src]
pub struct SourceManager { /* fields omitted */ }
Expand description
Holds a list of Source objects and selects one to use when loading a package
Implementations
impl SourceManager
[src]
impl SourceManager
[src]pub fn new() -> SourceManager
[src]
pub fn new() -> SourceManager
[src]Constructs a new, empty SourceManager
pub fn add_source(&mut self, source: Box<dyn Source>) -> SourceId
[src]
pub fn add_source(&mut self, source: Box<dyn Source>) -> SourceId
[src]Adds the given Source to the end of the list.
pub fn source(&mut self, id: SourceId) -> Option<&mut Box<dyn Source>>
[src]
pub fn source(&mut self, id: SourceId) -> Option<&mut Box<dyn Source>>
[src]Returns a reference to the Source of the given ID.