Classes

The following classes are available globally.

  • FirebaseStorage is a service that supports uploading and downloading binary objects, such as images, videos, and other files to Google Cloud Storage.

    If you call [FIRStorage storage], the instance will initialize with the default FIRApp, [FIRApp defaultApp], and the storage location will come from the provided GoogleService-Info.plist.

    If you call [FIRStorage storageForApp:] and provide a custom instance of FIRApp, the storage location will be specified via the FIROptions#storageBucket property.

    Declaration

    Swift

    class Storage : NSObject

    Objective-C

    
    @interface FIRStorage : NSObject
  • FIRStorageDownloadTask implements resumable downloads from an object in Firebase Storage. Downloads can be returned on completion with a completion handler, and can be monitored by attaching observers, or controlled by calling FIRStorageTask#pause, FIRStorageTask#resume, or FIRStorageTask#cancel. Downloads can currently be returned as NSData in memory, or as an NSURL to a file on disk. Downloads are performed on a background queue, and callbacks are raised on the developer specified callbackQueue in FIRStorage, or the main queue if left unspecified. Currently all uploads must be initiated and managed on the main queue.

    Declaration

    Swift

    class StorageDownloadTask : StorageObservableTask, StorageTaskManagement

    Objective-C

    
    @interface FIRStorageDownloadTask
        : FIRStorageObservableTask <FIRStorageTaskManagement>
  • Class which represents the metadata on an object in Firebase Storage. This metadata is returned on successful operations, and can be used to retrieve download URLs, content types, and a FIRStorage reference to the object in question. Full documentation can be found at the GCS Objects#resource docs.

    Declaration

    Swift

    class StorageMetadata : NSObject, NSCopying

    Objective-C

    
    @interface FIRStorageMetadata : NSObject <NSCopying>
  • Extends FIRStorageTask to provide observable semantics such as adding and removing observers. Observers produce a FIRStorageHandle, which is used to keep track of and remove specific observers at a later date. This class is currently not thread safe and can only be called on the main thread.

    Declaration

    Swift

    class StorageObservableTask : StorageTask

    Objective-C

    
    @interface FIRStorageObservableTask : FIRStorageTask
  • FIRStorageReference represents a reference to a Google Cloud Storage object. Developers can upload and download objects, as well as get/set object metadata, and delete an object at the path.

    Declaration

    Swift

    class StorageReference : NSObject

    Objective-C

    
    @interface FIRStorageReference : NSObject
  • A superclass to all FIRStorage*Tasks, including FIRStorageUploadTask and FIRStorageDownloadTask, to provide state transitions, event raising, and common storage or metadata and errors. Callbacks are always fired on the developer specified callback queue. If no queue is specified by the developer, it defaults to the main queue. Currently not thread safe, so only call methods on the main thread.

    Declaration

    Swift

    class StorageTask : NSObject

    Objective-C

    
    @interface FIRStorageTask : NSObject
  • FIRStorageTaskSnapshot represents an immutable view of a task. A Snapshot contains a task, storage reference, metadata (if it exists), progress, and an error (if one occurred).

    Declaration

    Swift

    class StorageTaskSnapshot : NSObject

    Objective-C

    
    @interface FIRStorageTaskSnapshot : NSObject
  • FIRStorageUploadTask implements resumable uploads to a file in Firebase Storage. Uploads can be returned on completion with a completion callback, and can be monitored by attaching observers, or controlled by calling FIRStorageTask#pause, FIRStorageTask#resume, or FIRStorageTask#cancel. Uploads can take NSData in memory, or an NSURL to a file on disk. Uploads are performed on a background queue, and callbacks are raised on the developer specified callbackQueue in FIRStorage, or the main queue if left unspecified. Currently all uploads must be initiated and managed on the main queue.

    Declaration

    Swift

    class StorageUploadTask : StorageObservableTask, StorageTaskManagement

    Objective-C

    
    @interface FIRStorageUploadTask
        : FIRStorageObservableTask <FIRStorageTaskManagement>