mirror of
https://git.proxmox.com/git/proxmox
synced 2025-05-05 11:14:06 +00:00

to be replaced by a new set of macros for the current api schema in proxmox-backup Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
14 lines
429 B
Rust
14 lines
429 B
Rust
//! Proxmox API module. This provides utilities for HTTP and command line APIs.
|
|
|
|
use std::future::Future;
|
|
use std::pin::Pin;
|
|
|
|
use failure::Error;
|
|
use http::Response;
|
|
|
|
/// Return type of an API method.
|
|
pub type ApiOutput<Body> = Result<Response<Body>, Error>;
|
|
|
|
/// Future type of an API method. In order to support `async fn` this is a pinned box.
|
|
pub type ApiFuture<Body> = Pin<Box<dyn Future<Output = ApiOutput<Body>> + Send>>;
|