pub struct Server {Show 15 fields
pub id: String,
pub owner: String,
pub name: String,
pub description: Option<String>,
pub channels: Vec<String>,
pub categories: Option<Vec<Category>>,
pub system_messages: Option<SystemMessageChannels>,
pub roles: HashMap<String, Role>,
pub default_permissions: Permission,
pub icon: Option<Attachment>,
pub banner: Option<Attachment>,
pub flags: Option<ServerFlags>,
pub nsfw: bool,
pub analytics: bool,
pub discoverable: bool,
}Expand description
Representation of a server on Revolt
Fields§
§id: StringUnique Id
owner: StringUser id of the owner
name: StringName of the server
description: Option<String>Description for the server
channels: Vec<String>Channels within this server
categories: Option<Vec<Category>>Categories for this server
system_messages: Option<SystemMessageChannels>Configuration for sending system event messages
roles: HashMap<String, Role>Roles for this server
default_permissions: PermissionDefault set of server and channel permissions
icon: Option<Attachment>Icon attachment
Banner attachment
flags: Option<ServerFlags>Enum of server flags
nsfw: boolWhether this server is flagged as not safe for work
analytics: boolWhether to enable analytics
discoverable: boolWhether this server should be publicly discoverable
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Server
impl<'de> Deserialize<'de> for Server
Source§fn 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
Auto Trait Implementations§
impl Freeze for Server
impl RefUnwindSafe for Server
impl Send for Server
impl Sync for Server
impl Unpin for Server
impl UnwindSafe for Server
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more