pub trait PythonExt<R: Runtime> {
// Required methods
fn python(&self) -> &Python<R>;
fn runner(&self) -> &PyRunner;
fn run_python<'life0, 'async_trait>(
&'life0 self,
payload: StringRequest,
) -> Pin<Box<dyn Future<Output = Result<StringResponse>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn register_function<'life0, 'async_trait>(
&'life0 self,
payload: RegisterRequest,
) -> Pin<Box<dyn Future<Output = Result<StringResponse>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn call_function<'life0, 'async_trait>(
&'life0 self,
payload: RunRequest,
) -> Pin<Box<dyn Future<Output = Result<StringResponse>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn read_variable<'life0, 'async_trait>(
&'life0 self,
payload: StringRequest,
) -> Pin<Box<dyn Future<Output = Result<StringResponse>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Expand description
Extensions to tauri::App, tauri::AppHandle and tauri::Window to access the python APIs.
Required Methods§
fn python(&self) -> &Python<R>
fn runner(&self) -> &PyRunner
fn run_python<'life0, 'async_trait>(
&'life0 self,
payload: StringRequest,
) -> Pin<Box<dyn Future<Output = Result<StringResponse>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn register_function<'life0, 'async_trait>(
&'life0 self,
payload: RegisterRequest,
) -> Pin<Box<dyn Future<Output = Result<StringResponse>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn call_function<'life0, 'async_trait>(
&'life0 self,
payload: RunRequest,
) -> Pin<Box<dyn Future<Output = Result<StringResponse>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn read_variable<'life0, 'async_trait>(
&'life0 self,
payload: StringRequest,
) -> Pin<Box<dyn Future<Output = Result<StringResponse>> + 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".