VOUserNetwork
@interface VOUserNetwork : NSObject
VOUserNetwork
is a model to represent the different networks a user has connected with.
-
The name of the network. Eg. Phone / Email / Facebook.
Declaration
Objective-C
@property (readonly, strong, nonatomic) NSString *_Nonnull name;
Swift
var name: String { get }
-
The
VOUser
‘s name of the network. One of externalUserName / externalUserId must be set.Declaration
Objective-C
@property (readonly, strong, nonatomic, nullable) NSString *externalUserName;
Swift
var externalUserName: String? { get }
-
The
VOUser
‘s id of the network. One of externalUserName / externalUserId must be set.Declaration
Objective-C
@property (readonly, strong, nonatomic, nullable) NSString *externalUserId;
Swift
var externalUserId: String? { get }
-
The status of the network. Either Active or Verifying.
Declaration
Objective-C
@property (readonly, nonatomic) VOUserNetworkStatus status;
Swift
var status: VOUserNetworkStatus { get }
-
Default initializer for the
VOUserNetwork
.Declaration
Objective-C
+ (nonnull instancetype)userNetworkFromDictionary: (nonnull NSDictionary *)dictionary;
Swift
convenience init(from dictionary: [AnyHashable : Any])
Parameters
dictionary
- a dictionary with properties used to create the
VOUserNetwork
.Return Value
instance of
VOUserNetwork
. -
Converts the
VOUserNetwork
to an NSDictionary that can be used for caching or sending to the server.Declaration
Objective-C
- (nonnull NSDictionary *)dictionaryRepresentation;
Swift
func dictionaryRepresentation() -> [AnyHashable : Any]
Return Value
dictionary - Dictionary form of a
VOUserNetwork
.