#[non_exhaustive]pub struct CreateOptions {
pub repository: PathBuf,
pub base: String,
pub label: Option<String>,
pub links: BTreeMap<String, String>,
}Expand description
Inputs for creating a capsule.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.repository: PathBufAny path inside the source Git repository.
base: StringRevision to pin, resolved to an immutable commit before work starts.
label: Option<String>Optional human-facing description of the attempt.
links: BTreeMap<String, String>Opaque caller metadata, at most 32 entries. No key is privileged.
Implementations§
Source§impl CreateOptions
impl CreateOptions
Sourcepub fn new(repository: impl Into<PathBuf>) -> Self
pub fn new(repository: impl Into<PathBuf>) -> Self
Options for a capsule based on the repository’s current HEAD.
Sourcepub fn with_label(self, label: impl Into<String>) -> Self
pub fn with_label(self, label: impl Into<String>) -> Self
Set the human-facing attempt label.
Sourcepub fn with_links(self, links: BTreeMap<String, String>) -> Self
pub fn with_links(self, links: BTreeMap<String, String>) -> Self
Replace the opaque caller links.
Trait Implementations§
Source§impl Clone for CreateOptions
impl Clone for CreateOptions
Auto Trait Implementations§
impl Freeze for CreateOptions
impl RefUnwindSafe for CreateOptions
impl Send for CreateOptions
impl Sync for CreateOptions
impl Unpin for CreateOptions
impl UnsafeUnpin for CreateOptions
impl UnwindSafe for CreateOptions
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