pub struct FileOptions {
pub cache_control: Option<u64>,
pub content_type: Option<String>,
pub upsert: Option<bool>,
}
Expand description
- cache_control: The number of seconds the asset is cached in the browser and in the Supabase CDN.
This is set in the
Cache-Control: max-age=<seconds>
header. Defaults to 3600 seconds - content_type: the
Content-Type
header value. Should be specified if using afileBody
that is neitherBlob
norFile
norFormData
, otherwise will default totext/plain;charset=UTF-8
. - upsert: When upsert is set to true, the file is overwritten if it exists. When set to false, an error is thrown if the object already exists. Defaults to false.
Fieldsยง
ยงcache_control: Option<u64>
ยงcontent_type: Option<String>
ยงupsert: Option<bool>
Trait Implementationsยง
Sourceยงimpl Debug for FileOptions
impl Debug for FileOptions
Auto Trait Implementationsยง
impl Freeze for FileOptions
impl RefUnwindSafe for FileOptions
impl Send for FileOptions
impl Sync for FileOptions
impl Unpin for FileOptions
impl UnwindSafe for FileOptions
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