pub struct SourceControl<'a> { /* private fields */ }
Expand description
Represents a debian/control
file.
Specified at https://www.debian.org/doc/debian-policy/ch-controlfields.html#source-package-control-files-debian-control.
Implementations§
Source§impl<'a> SourceControl<'a>
impl<'a> SourceControl<'a>
Sourcepub fn parse_reader<R: BufRead>(reader: &mut R) -> Result<Self, ControlError>
pub fn parse_reader<R: BufRead>(reader: &mut R) -> Result<Self, ControlError>
Construct an instance by parsing a control file from a reader.
pub fn parse_str(s: &str) -> Result<Self, ControlError>
Sourcepub fn general_paragraph(&self) -> &ControlParagraph<'a>
pub fn general_paragraph(&self) -> &ControlParagraph<'a>
Obtain a handle on the general paragraph.
Sourcepub fn binary_paragraphs(&self) -> impl Iterator<Item = &ControlParagraph<'a>>
pub fn binary_paragraphs(&self) -> impl Iterator<Item = &ControlParagraph<'a>>
Obtain an iterator over paragraphs defining binaries.
Trait Implementations§
Source§impl<'a> Default for SourceControl<'a>
impl<'a> Default for SourceControl<'a>
Source§fn default() -> SourceControl<'a>
fn default() -> SourceControl<'a>
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl<'a> Freeze for SourceControl<'a>
impl<'a> RefUnwindSafe for SourceControl<'a>
impl<'a> Send for SourceControl<'a>
impl<'a> Sync for SourceControl<'a>
impl<'a> Unpin for SourceControl<'a>
impl<'a> UnwindSafe for SourceControl<'a>
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