pub struct Manifest {
pub dir: PathBuf,
pub version: u32,
/* private fields */
}Fields§
§dir: PathBuf§version: u32Implementations§
Source§impl Manifest
impl Manifest
pub const FILE: &'static str = "manifest.txt"
Sourcepub fn load(dir: &Path, version: u32) -> Result<Self, Error>
pub fn load(dir: &Path, version: u32) -> Result<Self, Error>
Read <dir>/manifest.txt, which must be format version.
Sourcepub fn records(&self) -> &[Record]
pub fn records(&self) -> &[Record]
Every model-specific record (not version / param / xclbin), in
file order.
pub fn tagged<'a>(&'a self, tag: &'a str) -> impl Iterator<Item = &'a Record>
pub fn has_param(&self, k: &str) -> bool
pub fn param(&self, k: &str) -> Result<&str, Error>
pub fn param_as<T: FromStr>(&self, k: &str) -> Result<T, Error>
Sourcepub fn list<T: FromStr>(&self, k: &str) -> Result<Vec<T>, Error>
pub fn list<T: FromStr>(&self, k: &str) -> Result<Vec<T>, Error>
A comma-separated param (empty items skipped, so "" is []).
pub fn xclbin(&self, key: &str) -> Result<&Xclbin, Error>
pub fn xclbins(&self) -> impl Iterator<Item = &Xclbin>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Manifest
impl RefUnwindSafe for Manifest
impl Send for Manifest
impl Sync for Manifest
impl Unpin for Manifest
impl UnsafeUnpin for Manifest
impl UnwindSafe for Manifest
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