Enum bonsaidb_core::networking::ServerResponse
source · [−]pub enum ServerResponse {
DatabaseCreated {
name: String,
},
DatabaseDeleted {
name: String,
},
Databases(Vec<Database>),
AvailableSchemas(Vec<SchemaName>),
UserCreated {
id: u64,
},
Authenticated(Authenticated),
}Expand description
A response to a ServerRequest.
Variants
DatabaseCreated
Fields
name: StringThe name of the database to create.
A database with name was successfully created.
DatabaseDeleted
Fields
name: StringThe name of the database to remove.
A database with name was successfully removed.
Databases(Vec<Database>)
A list of available databases.
AvailableSchemas(Vec<SchemaName>)
A list of availble schemas.
UserCreated
Fields
id: u64The id of the user created.
A user was created.
Authenticated(Authenticated)
Successfully authenticated.
Trait Implementations
sourceimpl Clone for ServerResponse
impl Clone for ServerResponse
sourcefn clone(&self) -> ServerResponse
fn clone(&self) -> ServerResponse
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for ServerResponse
impl Debug for ServerResponse
sourceimpl<'de> Deserialize<'de> for ServerResponse
impl<'de> Deserialize<'de> for ServerResponse
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl Serialize for ServerResponse
impl Serialize for ServerResponse
Auto Trait Implementations
impl RefUnwindSafe for ServerResponse
impl Send for ServerResponse
impl Sync for ServerResponse
impl Unpin for ServerResponse
impl UnwindSafe for ServerResponse
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more