pub trait PlaceApi {
// Required methods
fn get(&self, path: &str) -> Result<Value, CloudError>;
fn get_bytes(&self, path: &str, max: usize) -> Result<Vec<u8>, CloudError>;
fn post(&self, path: &str, body: &Value) -> Result<Value, CloudError>;
}Expand description
The routes a replica needs. crate::transport::CloudClient
implements it; tests use an in-memory server.
Required Methods§
fn get(&self, path: &str) -> Result<Value, CloudError>
fn get_bytes(&self, path: &str, max: usize) -> Result<Vec<u8>, CloudError>
fn post(&self, path: &str, body: &Value) -> Result<Value, CloudError>
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".