pub trait Lifecycle {
// Required methods
fn has_transition<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = bool> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn has_expiry(&self) -> bool;
fn has_active_rules(&self, prefix: &str) -> bool;
fn validate<'life0, 'life1, 'async_trait>(
&'life0 self,
lr: &'life1 ObjectLockConfiguration,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn filter_rules<'life0, 'life1, 'async_trait>(
&'life0 self,
obj: &'life1 ObjectOpts,
) -> Pin<Box<dyn Future<Output = Option<Vec<LifecycleRule>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn eval<'life0, 'life1, 'async_trait>(
&'life0 self,
obj: &'life1 ObjectOpts,
) -> Pin<Box<dyn Future<Output = Event> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn predict_expiration<'life0, 'life1, 'async_trait>(
&'life0 self,
obj: &'life1 ObjectOpts,
) -> Pin<Box<dyn Future<Output = Event> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn eval_inner<'life0, 'life1, 'async_trait>(
&'life0 self,
obj: &'life1 ObjectOpts,
now: OffsetDateTime,
newer_noncurrent_versions: usize,
) -> Pin<Box<dyn Future<Output = Event> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn noncurrent_versions_expiration_limit<'life0, 'async_trait>(
self: Arc<Self>,
obj: &'life0 ObjectOpts,
) -> Pin<Box<dyn Future<Output = Event> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Required Methods§
fn has_transition<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = bool> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn has_expiry(&self) -> bool
fn has_active_rules(&self, prefix: &str) -> bool
fn validate<'life0, 'life1, 'async_trait>(
&'life0 self,
lr: &'life1 ObjectLockConfiguration,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn filter_rules<'life0, 'life1, 'async_trait>(
&'life0 self,
obj: &'life1 ObjectOpts,
) -> Pin<Box<dyn Future<Output = Option<Vec<LifecycleRule>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn eval<'life0, 'life1, 'async_trait>(
&'life0 self,
obj: &'life1 ObjectOpts,
) -> Pin<Box<dyn Future<Output = Event> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn predict_expiration<'life0, 'life1, 'async_trait>(
&'life0 self,
obj: &'life1 ObjectOpts,
) -> Pin<Box<dyn Future<Output = Event> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn eval_inner<'life0, 'life1, 'async_trait>(
&'life0 self,
obj: &'life1 ObjectOpts,
now: OffsetDateTime,
newer_noncurrent_versions: usize,
) -> Pin<Box<dyn Future<Output = Event> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn noncurrent_versions_expiration_limit<'life0, 'async_trait>(
self: Arc<Self>,
obj: &'life0 ObjectOpts,
) -> Pin<Box<dyn Future<Output = Event> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".