mirror of
https://github.com/servo/servo.git
synced 2025-08-06 06:00:15 +01:00
Refactor FileAPI implementation
This commit is contained in:
parent
9b01a4cc97
commit
aea99e081b
8 changed files with 224 additions and 178 deletions
|
@ -6,7 +6,7 @@ use std::str::FromStr;
|
|||
use url::Url;
|
||||
use uuid::Uuid;
|
||||
|
||||
/// Errors returns to BlobURLStoreMsg::Request
|
||||
/// Errors returned to Blob URL Store request
|
||||
#[derive(Clone, Debug, Serialize, Deserialize)]
|
||||
pub enum BlobURLStoreError {
|
||||
/// Invalid File UUID
|
||||
|
@ -16,12 +16,13 @@ pub enum BlobURLStoreError {
|
|||
/// Invalid entry content
|
||||
InvalidEntry,
|
||||
/// External error, from like file system, I/O etc.
|
||||
External,
|
||||
External(String),
|
||||
}
|
||||
|
||||
/// Blob URL store entry, a packaged form of Blob DOM object
|
||||
/// Standalone blob buffer object
|
||||
#[derive(Clone, Serialize, Deserialize)]
|
||||
pub struct BlobURLStoreEntry {
|
||||
pub struct BlobBuf {
|
||||
pub filename: Option<String>,
|
||||
/// MIME type string
|
||||
pub type_string: String,
|
||||
/// Size of content in bytes
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue