Trait nebari::tree::AnyTreeRoot
source · [−]pub trait AnyTreeRoot<File: ManagedFile> {
fn name(&self) -> &str;
fn default_state(&self) -> Box<dyn AnyTreeState>;
fn begin_transaction(
&self,
transaction_id: TransactionId,
file_path: &Path,
state: &dyn AnyTreeState,
context: &Context<File::Manager>,
transactions: Option<&TransactionManager<File::Manager>>
) -> Result<Box<dyn AnyTransactionTree<File>>, Error>;
}
Expand description
A named tree that can be used in a transaction.
Required methods
fn default_state(&self) -> Box<dyn AnyTreeState>
fn default_state(&self) -> Box<dyn AnyTreeState>
The default state for the underlying root type.
fn begin_transaction(
&self,
transaction_id: TransactionId,
file_path: &Path,
state: &dyn AnyTreeState,
context: &Context<File::Manager>,
transactions: Option<&TransactionManager<File::Manager>>
) -> Result<Box<dyn AnyTransactionTree<File>>, Error>
fn begin_transaction(
&self,
transaction_id: TransactionId,
file_path: &Path,
state: &dyn AnyTreeState,
context: &Context<File::Manager>,
transactions: Option<&TransactionManager<File::Manager>>
) -> Result<Box<dyn AnyTransactionTree<File>>, Error>
Begins a transaction on this tree.