pub struct AssetsLimits {
pub allowed_extensions: Vec<String>,
pub max_storage: u64,
pub max_asset_size: u64,
}Fields§
§allowed_extensions: Vec<String>Allowed extensions corresponding to MIME types.
(More to be supported in the future)
Supported:
- “txt”
- “xml”
- “html”
- “css”
- “csv”
- “js”
- “png”
- “apng”
- “gif”
- “svg”
- “jpg”
- “jpeg”
- “bmp”
- “tif”
- “tiff”
- “webp”
- “avif”
- “ico”
- “pdf”
- “json”
- “wasm”
Special:
- “none” (for no extension; uses “application/octet-stream”)
- “any” (for unsupported extensions; also uses “application/octet-stream”)
max_storage: u64Limit on total storage for all assets within an app (bytes).
max_asset_size: u64Limit on individual asset size (bytes).
Trait Implementations§
Source§impl Clone for AssetsLimits
impl Clone for AssetsLimits
Source§fn clone(&self) -> AssetsLimits
fn clone(&self) -> AssetsLimits
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AssetsLimits
impl Debug for AssetsLimits
Source§impl Default for AssetsLimits
impl Default for AssetsLimits
Source§impl<'de> Deserialize<'de> for AssetsLimits
impl<'de> Deserialize<'de> for AssetsLimits
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 AssetsLimits
impl RefUnwindSafe for AssetsLimits
impl Send for AssetsLimits
impl Sync for AssetsLimits
impl Unpin for AssetsLimits
impl UnwindSafe for AssetsLimits
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