DBUSERSBasicAccount
Objective-C
@interface DBUSERSBasicAccount : DBUSERSAccount <DBSerializable, NSCopying>
Swift
class DBUSERSBasicAccount : DBUSERSAccount, DBSerializable, NSCopying
The BasicAccount
struct.
Basic information about any account.
This class implements the DBSerializable
protocol (serialize and
deserialize instance methods), which is required for all Obj-C SDK API route
objects.
-
Whether this user is a teammate of the current user. If this account is the current user’s account, then this will be true.
Declaration
Objective-C
@property (nonatomic, readonly) NSNumber *_Nonnull isTeammate;
Swift
var isTeammate: NSNumber { get }
-
The user’s unique team member id. This field will only be present if the user is part of a team and isTeammate is true.
Declaration
Objective-C
@property (nonatomic, copy, readonly, nullable) NSString *teamMemberId;
Swift
var teamMemberId: String? { get }
-
Full constructor for the struct (exposes all instance variables).
Declaration
Objective-C
- (nonnull instancetype)initWithAccountId:(nonnull NSString *)accountId name:(nonnull DBUSERSName *)name email:(nonnull NSString *)email emailVerified:(nonnull NSNumber *)emailVerified disabled:(nonnull NSNumber *)disabled isTeammate:(nonnull NSNumber *)isTeammate profilePhotoUrl:(nullable NSString *)profilePhotoUrl teamMemberId:(nullable NSString *)teamMemberId;
Swift
init(accountId: String, name: DBUSERSName, email: String, emailVerified: NSNumber, disabled: NSNumber, isTeammate: NSNumber, profilePhotoUrl: String?, teamMemberId: String?)
Parameters
accountId
The user’s unique Dropbox ID.
name
Details of a user’s name.
email
The user’s email address. Do not rely on this without checking the emailVerified field. Even then, it’s possible that the user has since lost access to their email.
emailVerified
Whether the user has verified their email address.
disabled
Whether the user has been disabled.
isTeammate
Whether this user is a teammate of the current user. If this account is the current user’s account, then this will be true.
profilePhotoUrl
URL for the photo representing the user, if one is set.
teamMemberId
The user’s unique team member id. This field will only be present if the user is part of a team and isTeammate is true.
Return Value
An initialized instance.
-
Convenience constructor (exposes only non-nullable instance variables with no default value).
Declaration
Objective-C
- (nonnull instancetype)initWithAccountId:(nonnull NSString *)accountId name:(nonnull DBUSERSName *)name email:(nonnull NSString *)email emailVerified:(nonnull NSNumber *)emailVerified disabled:(nonnull NSNumber *)disabled isTeammate:(nonnull NSNumber *)isTeammate;
Swift
init(accountId: String, name: DBUSERSName, email: String, emailVerified: NSNumber, disabled: NSNumber, isTeammate: NSNumber)
Parameters
accountId
The user’s unique Dropbox ID.
name
Details of a user’s name.
email
The user’s email address. Do not rely on this without checking the emailVerified field. Even then, it’s possible that the user has since lost access to their email.
emailVerified
Whether the user has verified their email address.
disabled
Whether the user has been disabled.
isTeammate
Whether this user is a teammate of the current user. If this account is the current user’s account, then this will be true.
Return Value
An initialized instance.