Enum git_credentials::helper::Action
source · [−]Expand description
The action to perform by the credentials helper.
Variants
Get(Context)
Provide credentials using the given repository context, which must include the repository url.
Store(BString)
Approve the credentials as identified by the previous input provided as BString
, containing information from Context
.
Erase(BString)
Reject the credentials as identified by the previous input provided as BString
. containing information from Context
.
Implementations
sourceimpl Action
impl Action
Initialization
sourcepub fn get_for_url(url: impl Into<BString>) -> Action
pub fn get_for_url(url: impl Into<BString>) -> Action
Create a Get
action with context containing the given URL
sourceimpl Action
impl Action
Access
sourcepub fn context(&self) -> Option<&Context>
pub fn context(&self) -> Option<&Context>
Return the context of a get operation, or None
.
The opposite of payload
.
sourcepub fn context_mut(&mut self) -> Option<&mut Context>
pub fn context_mut(&mut self) -> Option<&mut Context>
Return the mutable context of a get operation, or None
.
sourcepub fn expects_output(&self) -> bool
pub fn expects_output(&self) -> bool
Returns true if this action expects output from the helper.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Action
impl Send for Action
impl Sync for Action
impl Unpin for Action
impl UnwindSafe for Action
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more