DBOpenWithInfo

@interface DBOpenWithInfo : NSObject <NSCoding>

Information for returning to the official Dropbox app.

Note

This logic is for official Dropbox partners only, and should not need to be used by other third-party apps.
  • The Dropbox user ID of the current user.

    Declaration

    Objective-C

    @property (readonly, copy, nonatomic) NSString *_Nonnull userId;

    Swift

    var userId: String { get }
  • rev

    The Dropbox revision for the file.

    Declaration

    Objective-C

    @property (readonly, copy, nonatomic) NSString *_Nonnull rev;

    Swift

    var rev: String { get }
  • The Dropbox path for the file.

    Declaration

    Objective-C

    @property (readonly, copy, nonatomic) NSString *_Nonnull path;

    Swift

    var path: String { get }
  • The time the file was modified last.

    Declaration

    Objective-C

    @property (readonly, copy, nonatomic, nullable) NSDate *modifiedTime;

    Swift

    var modifiedTime: Date? { get }
  • Whether the file is read only or not.

    Declaration

    Objective-C

    @property (readonly, nonatomic) BOOL readOnly;

    Swift

    var readOnly: Bool { get }
  • The Dropbox verb associated with the file.

    Declaration

    Objective-C

    @property (readonly, copy, nonatomic) NSString *_Nonnull verb;

    Swift

    var verb: String { get }
  • The Dropbox session ID associated with the file.

    Declaration

    Objective-C

    @property (readonly, copy, nonatomic, nullable) NSString *sessionId;

    Swift

    var sessionId: String? { get }
  • The Dropbox file ID associated with the file.

    Declaration

    Objective-C

    @property (readonly, copy, nonatomic, nullable) NSString *fileId;

    Swift

    var fileId: String? { get }
  • Relevant Dropbox file data associated with the file.

    Declaration

    Objective-C

    @property (readonly, copy, nonatomic, nullable) NSData *fileData;

    Swift

    var fileData: Data? { get }
  • The source application from which the file content originated.

    Declaration

    Objective-C

    @property (readonly, copy, nonatomic, nullable) NSString *sourceApp;

    Swift

    var sourceApp: String? { get }
  • Initializer containing the parameters that we were opened with. Some of these parameters are necessary to return to the originating Dropbox app. There are now two Dropbox apps: the regular Dropbox app and the Dropbox EMM app. Either can open with.

    Note

    This logic is for official Dropbox partners only, and should not need to be used by other third-party apps.

    Declaration

    Objective-C

    - (nonnull id)initWithUserId:(nonnull NSString *)userId
                             rev:(nonnull NSString *)rev
                            path:(nonnull NSString *)path
                    modifiedTime:(nullable NSDate *)modifiedTime
                        readOnly:(BOOL)readOnly
                            verb:(nonnull NSString *)verb
                       sessionId:(nullable NSString *)sessionId
                          fileId:(nullable NSString *)fileId
                        fileData:(nullable NSData *)fileData
                       sourceApp:(nullable NSString *)sourceApp;

    Swift

    init(userId: String, rev: String, path: String, modifiedTime: Date?, readOnly: Bool, verb: String, sessionId: String?, fileId: String?, fileData: Data?, sourceApp: String?)

    Parameters

    userId

    The Dropbox user ID of the current user.

    rev

    The Dropbox revision for the file.

    path

    The Dropbox path for the file.

    modifiedTime

    The time the file was modified last.

    readOnly

    Whether the file is read only.

    verb

    The action type to be taken on the file (e.g. EDIT) supplied by the official Dropbox app.

    sessionId

    The Dropbox session ID supplied by the official app

    fileId

    The Dropbox file ID associated with the file

    fileData

    Relevant Dropbox file data associated with the file.

    sourceApp

    The source application from which the file content originated.

  • Saves open with info to disc.

    Note

    This logic is for official Dropbox partners only, and should not need to be used by other third-party apps.

    Declaration

    Objective-C

    - (void)writeToStorageForSession:(nullable NSString *)sessionId;

    Swift

    func writeToStorage(forSession sessionId: String?)

    Parameters

    sessionId

    The Dropbox session ID supplied by the official app to be used as a storage lookup key.

  • Retrieves open with info from disc.

    Note

    This logic is for official Dropbox partners only, and should not need to be used by other third-party apps.

    Declaration

    Objective-C

    + (nullable DBOpenWithInfo *)popFromStorageForSession:
        (nonnull NSString *)sessionId;

    Swift

    class func popFromStorage(forSession sessionId: String) -> DBOpenWithInfo?

    Parameters

    sessionId

    The Dropbox session ID supplied by the official app to be used as a storage lookup key.