pub trait RemoteMDBX: Sized {
Show 25 methods
// Required methods
async fn open_env(
self,
context: Context,
path: PathBuf,
builder: RemoteEnvironmentConfig,
) -> Result<u64, ServerError>;
async fn env_ro_tx(
self,
context: Context,
env: u64,
) -> Result<u64, ServerError>;
async fn env_rw_tx(
self,
context: Context,
env: u64,
) -> Result<u64, ServerError>;
async fn env_sync(
self,
context: Context,
env: u64,
force: bool,
) -> Result<bool, ServerError>;
async fn env_close(
self,
context: Context,
env: u64,
) -> Result<(), ServerError>;
async fn env_stat(
self,
context: Context,
env: u64,
) -> Result<Stat, ServerError>;
async fn env_info(
self,
context: Context,
env: u64,
) -> Result<Info, ServerError>;
async fn tx_create_db(
self,
context: Context,
env: u64,
tx: u64,
db: Option<String>,
flags: u32,
) -> Result<u32, ServerError>;
async fn tx_get(
self,
context: Context,
env: u64,
tx: u64,
dbi: u32,
key: Vec<u8>,
) -> Result<Option<Vec<u8>>, ServerError>;
async fn tx_put(
self,
context: Context,
env: u64,
tx: u64,
dbi: u32,
key: Vec<u8>,
value: Vec<u8>,
flags: u32,
) -> Result<(), ServerError>;
async fn tx_del(
self,
context: Context,
env: u64,
tx: u64,
dbi: u32,
key: Vec<u8>,
value: Option<Vec<u8>>,
) -> Result<bool, ServerError>;
async fn tx_ro_cursor(
self,
context: Context,
env: u64,
tx: u64,
dbi: u32,
) -> Result<u64, ServerError>;
async fn tx_rw_cursor(
self,
context: Context,
env: u64,
tx: u64,
dbi: u32,
) -> Result<u64, ServerError>;
async fn tx_commit(
self,
context: Context,
env: u64,
tx: u64,
) -> Result<(bool, CommitLatency), ServerError>;
async fn tx_abort(
self,
context: Context,
env: u64,
tx: u64,
) -> Result<(), ServerError>;
async fn tx_nested(
self,
context: Context,
env: u64,
tx: u64,
) -> Result<u64, ServerError>;
async fn tx_db_stat(
self,
context: Context,
env: u64,
tx: u64,
dbi: u32,
) -> Result<Stat, ServerError>;
async fn clear_db(
self,
context: Context,
env: u64,
tx: u64,
dbi: u32,
) -> Result<(), ServerError>;
async fn cur_get(
self,
context: Context,
env: u64,
tx: u64,
cur: u64,
key: Option<Vec<u8>>,
data: Option<Vec<u8>>,
op: u32,
) -> Result<(Option<Vec<u8>>, Vec<u8>, bool), ServerError>;
async fn cur_put(
self,
context: Context,
env: u64,
tx: u64,
cur: u64,
key: Vec<u8>,
value: Vec<u8>,
flags: u32,
) -> Result<(), ServerError>;
async fn cur_create(
self,
context: Context,
env: u64,
tx: u64,
cur: u64,
) -> Result<u64, ServerError>;
async fn cur_del(
self,
context: Context,
env: u64,
tx: u64,
cur: u64,
flags: u32,
) -> Result<(), ServerError>;
async fn cur_close(
self,
context: Context,
env: u64,
tx: u64,
cur: u64,
) -> Result<(), ServerError>;
async fn batch_cur_get_full(
self,
context: Context,
env: u64,
tx: u64,
cur: u64,
cnt: u64,
buffer: u64,
op: u32,
) -> Result<Vec<(Vec<u8>, Vec<u8>)>, ServerError>;
// Provided method
fn serve(self) -> ServeRemoteMDBX<Self> { ... }
}Required Methods§
async fn open_env( self, context: Context, path: PathBuf, builder: RemoteEnvironmentConfig, ) -> Result<u64, ServerError>
async fn env_ro_tx(self, context: Context, env: u64) -> Result<u64, ServerError>
async fn env_rw_tx(self, context: Context, env: u64) -> Result<u64, ServerError>
async fn env_sync( self, context: Context, env: u64, force: bool, ) -> Result<bool, ServerError>
async fn env_close(self, context: Context, env: u64) -> Result<(), ServerError>
async fn env_stat(self, context: Context, env: u64) -> Result<Stat, ServerError>
async fn env_info(self, context: Context, env: u64) -> Result<Info, ServerError>
async fn tx_create_db( self, context: Context, env: u64, tx: u64, db: Option<String>, flags: u32, ) -> Result<u32, ServerError>
async fn tx_get( self, context: Context, env: u64, tx: u64, dbi: u32, key: Vec<u8>, ) -> Result<Option<Vec<u8>>, ServerError>
async fn tx_put( self, context: Context, env: u64, tx: u64, dbi: u32, key: Vec<u8>, value: Vec<u8>, flags: u32, ) -> Result<(), ServerError>
async fn tx_del( self, context: Context, env: u64, tx: u64, dbi: u32, key: Vec<u8>, value: Option<Vec<u8>>, ) -> Result<bool, ServerError>
async fn tx_ro_cursor( self, context: Context, env: u64, tx: u64, dbi: u32, ) -> Result<u64, ServerError>
async fn tx_rw_cursor( self, context: Context, env: u64, tx: u64, dbi: u32, ) -> Result<u64, ServerError>
async fn tx_commit( self, context: Context, env: u64, tx: u64, ) -> Result<(bool, CommitLatency), ServerError>
async fn tx_abort( self, context: Context, env: u64, tx: u64, ) -> Result<(), ServerError>
async fn tx_nested( self, context: Context, env: u64, tx: u64, ) -> Result<u64, ServerError>
async fn tx_db_stat( self, context: Context, env: u64, tx: u64, dbi: u32, ) -> Result<Stat, ServerError>
async fn clear_db( self, context: Context, env: u64, tx: u64, dbi: u32, ) -> Result<(), ServerError>
async fn cur_get( self, context: Context, env: u64, tx: u64, cur: u64, key: Option<Vec<u8>>, data: Option<Vec<u8>>, op: u32, ) -> Result<(Option<Vec<u8>>, Vec<u8>, bool), ServerError>
async fn cur_put( self, context: Context, env: u64, tx: u64, cur: u64, key: Vec<u8>, value: Vec<u8>, flags: u32, ) -> Result<(), ServerError>
async fn cur_create( self, context: Context, env: u64, tx: u64, cur: u64, ) -> Result<u64, ServerError>
async fn cur_del( self, context: Context, env: u64, tx: u64, cur: u64, flags: u32, ) -> Result<(), ServerError>
async fn cur_close( self, context: Context, env: u64, tx: u64, cur: u64, ) -> Result<(), ServerError>
async fn batch_cur_get_full( self, context: Context, env: u64, tx: u64, cur: u64, cnt: u64, buffer: u64, op: u32, ) -> Result<Vec<(Vec<u8>, Vec<u8>)>, ServerError>
Provided Methods§
Sourcefn serve(self) -> ServeRemoteMDBX<Self>
fn serve(self) -> ServeRemoteMDBX<Self>
Returns a serving function to use with InFlightRequest::execute.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.