Skip to main content

PushPolicy

Trait PushPolicy 

Source
pub trait PushPolicy: Send + Sync {
    // Required method
    fn check(
        &self,
        repo: &Repository,
        pusher: &Pusher,
        updates: &[RefUpdate],
    ) -> Vec<Option<String>>;
}
Expand description

Decides, per ref update, whether a push may proceed.

Required Methods§

Source

fn check( &self, repo: &Repository, pusher: &Pusher, updates: &[RefUpdate], ) -> Vec<Option<String>>

One entry per update, in order: Some(reason) refuses that ref.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§