Struct git_repository::reference::iter::Platform
source · pub struct Platform<'r> { /* private fields */ }Expand description
A platform to create iterators over references.
Implementations§
source§impl<'r> Platform<'r>
impl<'r> Platform<'r>
sourcepub fn all(&self) -> Result<Iter<'_>, Error>
pub fn all(&self) -> Result<Iter<'_>, Error>
Return an iterator over all references in the repository.
Even broken or otherwise unparsible or inaccessible references are returned and have to be handled by the caller on a case by case basis.
sourcepub fn prefixed(&self, prefix: impl AsRef<Path>) -> Result<Iter<'_>, Error>
pub fn prefixed(&self, prefix: impl AsRef<Path>) -> Result<Iter<'_>, Error>
Return an iterator over all references that match the given prefix.
These are of the form refs/heads or refs/remotes/origin, and must not contain relative paths components like . or ...
Return an iterator over all references that are tags.
They are all prefixed with refs/tags.
sourcepub fn local_branches(&self) -> Result<Iter<'_>, Error>
pub fn local_branches(&self) -> Result<Iter<'_>, Error>
Return an iterator over all local branches.
They are all prefixed with refs/heads.
sourcepub fn remote_branches(&self) -> Result<Iter<'_>, Error>
pub fn remote_branches(&self) -> Result<Iter<'_>, Error>
Return an iterator over all remote branches.
They are all prefixed with refs/remotes.