Blob
public final class Blob: Equatable, HashableBlob contains arbitrary binary data, tagged with a MIME type.
Blobs can be arbitrarily large, and their data is loaded only on demand (when the content
or contentStream properties are accessed), not when the document is loaded.
The document’s raw JSON form only contains the Blob’s metadata (type, length and a digest of
the data) in a small object. The data itself is stored externally to the document, keyed by
the digest.
- 
                  
                  Initializes a Blob with the given in-memory data. DeclarationSwift public convenience init(contentType: String, data: Data)ParameterscontentTypeThe type of content this Blob will represent. dataThe data that this Blob will contain. 
- 
                  
                  Initializes a Blob with the given stream of data. DeclarationSwift public convenience init(contentType: String, contentStream: InputStream)ParameterscontentTypeThe type of content this Blob will represent. contentStreamThe stream of data that this Blob will consume. 
- 
                  
                  Initializes a Blob with the contents of a file. Throws An error on a failure.DeclarationSwift public convenience init(contentType: String, fileURL: URL) throwsParameterscontentTypeThe type of content this Blob will represent. fileURLA URL to a file containing the data that this Blob will represent. 
- 
                  
                  Gets the contents of a Blob as a block of memory. Not recommended for very large blobs, as it may be slow and use up lots of RAM. DeclarationSwift public var content: Data?
- 
                  
                  A stream of the content of a Blob. The caller is responsible for opening the stream, and closing it when finished. DeclarationSwift public var contentStream: InputStream?
- 
                  
                  The type of content this Blob represents; by convention this is a MIME type. DeclarationSwift public var contentType: String?
- 
                  
                  The binary length of this Blob. DeclarationSwift public var length: UInt64
- 
                  
                  The cryptographic digest of this Blob’s contents, which uniquely identifies it. DeclarationSwift public var digest: String?
- 
                  
                  The metadata associated with this Blob DeclarationSwift public var properties: [String: Any]
- 
                  
                  Equal to operator for comparing two Blob objects. DeclarationSwift public static func == (blob1: Blob, blob2: Blob) -> Bool
 Blob Class Reference
        Blob Class Reference