DBSHARINGUserInfo

Objective-C

@interface DBSHARINGUserInfo : NSObject <DBSerializable, NSCopying>

Swift

class DBSHARINGUserInfo : NSObject, DBSerializable, NSCopying

The UserInfo struct.

Basic information about a user. Use usersAccount and usersAccountBatch to obtain more detailed information.

This class implements the DBSerializable protocol (serialize and deserialize instance methods), which is required for all Obj-C SDK API route objects.

Instance fields

  • The account ID of the user.

    Declaration

    Objective-C

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

    Swift

    var accountId: String { get }
  • Email address of user.

    Declaration

    Objective-C

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

    Swift

    var email: String { get }
  • The display name of the user.

    Declaration

    Objective-C

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

    Swift

    var displayName: String { get }
  • If the user is in the same team as current user.

    Declaration

    Objective-C

    @property (nonatomic, readonly) NSNumber *_Nonnull sameTeam;

    Swift

    var sameTeam: NSNumber { get }
  • The team member ID of the shared folder member. Only present if sameTeam is true.

    Declaration

    Objective-C

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

    Swift

    var teamMemberId: String? { get }

Constructors

  • Full constructor for the struct (exposes all instance variables).

    Declaration

    Objective-C

    - (nonnull instancetype)initWithAccountId:(nonnull NSString *)accountId
                                        email:(nonnull NSString *)email
                                  displayName:(nonnull NSString *)displayName
                                     sameTeam:(nonnull NSNumber *)sameTeam
                                 teamMemberId:(nullable NSString *)teamMemberId;

    Swift

    init(accountId: String, email: String, displayName: String, sameTeam: NSNumber, teamMemberId: String?)

    Parameters

    accountId

    The account ID of the user.

    email

    Email address of user.

    displayName

    The display name of the user.

    sameTeam

    If the user is in the same team as current user.

    teamMemberId

    The team member ID of the shared folder member. Only present if sameTeam 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
                                        email:(nonnull NSString *)email
                                  displayName:(nonnull NSString *)displayName
                                     sameTeam:(nonnull NSNumber *)sameTeam;

    Swift

    init(accountId: String, email: String, displayName: String, sameTeam: NSNumber)

    Parameters

    accountId

    The account ID of the user.

    email

    Email address of user.

    displayName

    The display name of the user.

    sameTeam

    If the user is in the same team as current user.

    Return Value

    An initialized instance.