Struct warg_server::policy::content::ContentPolicyCollection
source · pub struct ContentPolicyCollection { /* private fields */ }Expand description
Represents a collection of content policies.
Content policies are checked in order of their addition to the collection.
Implementations§
source§impl ContentPolicyCollection
impl ContentPolicyCollection
sourcepub fn push(&mut self, policy: impl ContentPolicy + 'static)
pub fn push(&mut self, policy: impl ContentPolicy + 'static)
Pushes a new content policy into the collection.
Trait Implementations§
source§impl ContentPolicy for ContentPolicyCollection
impl ContentPolicy for ContentPolicyCollection
source§fn new_stream_policy(
&self,
digest: &AnyHash
) -> ContentPolicyResult<Box<dyn ContentStreamPolicy>>
fn new_stream_policy( &self, digest: &AnyHash ) -> ContentPolicyResult<Box<dyn ContentStreamPolicy>>
Creates a new stream policy for the given digest. Read more
source§impl Default for ContentPolicyCollection
impl Default for ContentPolicyCollection
source§fn default() -> ContentPolicyCollection
fn default() -> ContentPolicyCollection
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl !RefUnwindSafe for ContentPolicyCollection
impl Send for ContentPolicyCollection
impl Sync for ContentPolicyCollection
impl Unpin for ContentPolicyCollection
impl !UnwindSafe for ContentPolicyCollection
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