Trait tc_transact::fs::Dir [−][src]
pub trait Dir: Store + Sized { type File; type FileClass; #[must_use] fn contains<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
txn_id: &'life1 TxnId,
name: &'life2 PathSegment
) -> Pin<Box<dyn Future<Output = TCResult<bool>> + Send + 'async_trait>>
where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait; #[must_use] fn create_dir<'life0, 'async_trait>(
&'life0 self,
txn_id: TxnId,
name: PathSegment
) -> Pin<Box<dyn Future<Output = TCResult<Self>> + Send + 'async_trait>>
where
'life0: 'async_trait,
Self: 'async_trait; #[must_use] fn create_dir_tmp<'life0, 'async_trait>(
&'life0 self,
txn_id: TxnId
) -> Pin<Box<dyn Future<Output = TCResult<Self>> + Send + 'async_trait>>
where
'life0: 'async_trait,
Self: 'async_trait; #[must_use] fn create_file<'life0, 'async_trait>(
&'life0 self,
txn_id: TxnId,
name: Id,
class: Self::FileClass
) -> Pin<Box<dyn Future<Output = TCResult<Self::File>> + Send + 'async_trait>>
where
'life0: 'async_trait,
Self: 'async_trait; #[must_use] fn create_file_tmp<'life0, 'async_trait>(
&'life0 self,
txn_id: TxnId,
class: Self::FileClass
) -> Pin<Box<dyn Future<Output = TCResult<Self::File>> + Send + 'async_trait>>
where
'life0: 'async_trait,
Self: 'async_trait; #[must_use] fn get_dir<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
txn_id: &'life1 TxnId,
name: &'life2 PathSegment
) -> Pin<Box<dyn Future<Output = TCResult<Option<Self>>> + Send + 'async_trait>>
where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait; #[must_use] fn get_file<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
txn_id: &'life1 TxnId,
name: &'life2 Id
) -> Pin<Box<dyn Future<Output = TCResult<Option<Self::File>>> + Send + 'async_trait>>
where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait; }
A transactional directory
Associated Types
type File
[src]
The type of a file entry in this Dir
type FileClass
[src]
The Class
of a file stored in this Dir
Required methods
#[must_use]fn contains<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
txn_id: &'life1 TxnId,
name: &'life2 PathSegment
) -> Pin<Box<dyn Future<Output = TCResult<bool>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
[src]
#[must_use]
fn contains<'life0, 'life1, 'life2, 'async_trait>(&'life0 self,
txn_id: &'life1 TxnId,
name: &'life2 PathSegment
) -> Pin<Box<dyn Future<Output = TCResult<bool>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Return true
if this directory has an entry at the given PathSegment
.
#[must_use]fn create_dir<'life0, 'async_trait>(
&'life0 self,
txn_id: TxnId,
name: PathSegment
) -> Pin<Box<dyn Future<Output = TCResult<Self>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
#[must_use]
fn create_dir<'life0, 'async_trait>(&'life0 self,
txn_id: TxnId,
name: PathSegment
) -> Pin<Box<dyn Future<Output = TCResult<Self>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
Create a new Dir
.
#[must_use]fn create_dir_tmp<'life0, 'async_trait>(
&'life0 self,
txn_id: TxnId
) -> Pin<Box<dyn Future<Output = TCResult<Self>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
#[must_use]
fn create_dir_tmp<'life0, 'async_trait>(&'life0 self,
txn_id: TxnId
) -> Pin<Box<dyn Future<Output = TCResult<Self>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
Create a new Dir
with a new unique ID.
#[must_use]fn create_file<'life0, 'async_trait>(
&'life0 self,
txn_id: TxnId,
name: Id,
class: Self::FileClass
) -> Pin<Box<dyn Future<Output = TCResult<Self::File>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
#[must_use]
fn create_file<'life0, 'async_trait>(&'life0 self,
txn_id: TxnId,
name: Id,
class: Self::FileClass
) -> Pin<Box<dyn Future<Output = TCResult<Self::File>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
Create a new Self::File
.
#[must_use]fn create_file_tmp<'life0, 'async_trait>(
&'life0 self,
txn_id: TxnId,
class: Self::FileClass
) -> Pin<Box<dyn Future<Output = TCResult<Self::File>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
#[must_use]
fn create_file_tmp<'life0, 'async_trait>(&'life0 self,
txn_id: TxnId,
class: Self::FileClass
) -> Pin<Box<dyn Future<Output = TCResult<Self::File>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
Create a new Self::File
with a new unique ID.
#[must_use]fn get_dir<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
txn_id: &'life1 TxnId,
name: &'life2 PathSegment
) -> Pin<Box<dyn Future<Output = TCResult<Option<Self>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
[src]
#[must_use]
fn get_dir<'life0, 'life1, 'life2, 'async_trait>(&'life0 self,
txn_id: &'life1 TxnId,
name: &'life2 PathSegment
) -> Pin<Box<dyn Future<Output = TCResult<Option<Self>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Look up a subdirectory of this Dir
.
#[must_use]fn get_file<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
txn_id: &'life1 TxnId,
name: &'life2 Id
) -> Pin<Box<dyn Future<Output = TCResult<Option<Self::File>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
[src]
#[must_use]
fn get_file<'life0, 'life1, 'life2, 'async_trait>(&'life0 self,
txn_id: &'life1 TxnId,
name: &'life2 Id
) -> Pin<Box<dyn Future<Output = TCResult<Option<Self::File>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
Get a Self::File
in this Dir
.