Before using this class you must authorize or register with the help of VPNUAuthorizer
class. You must pass the same VPNUTransport
instance to its constructor as you have passed to VPNUAuthorizer
instance constructor.
Extends: NSObject
Declared in: VPNUAccount.h
+ (instancetype)accountWithTransport:(VPNUTransport *)transport;
An initialized account object or nil if the object couldn't be created.
This method is a convenience constructor.
Available in Mac OS X v10.7. Available in iOS v7.0.
- (NSArray<VPNUAccountDevice *> *)devicesWithError:(NSError **)error;
nil
.An array of VPNUAccountDevice
objects for currently logged-in user.
It blocks a calling thread.
This method shouldn't be called from main thread.
Available in Mac OS X v10.7. Available in iOS v7.0.
- (instancetype)initWithTransport:(VPNUTransport *)transport NS_DESIGNATED_INITIALIZER;
An initialized account object or nil if the object couldn't be created.
Available in Mac OS X v10.7. Available in iOS v7.0.
- (NSArray<VPNUAccountDeviceStatistics *> *) statisticsForDevice:(VPNUAccountDevice *)device withError:(NSError **)error;
nil
.An array of VPNUAccountDeviceStatistics
objects for currently logged-in user. Each object represents statistics for a specific date.
It blocks a calling thread.
This method shouldn't be called from main thread.
Available in Mac OS X v10.7. Available in iOS v7.0.
- (VPNUAccountStatus *)statusWithError:(NSError **)error;
nil
.Currently logged-in user's account status.
It blocks a calling thread.
This method shouldn't be called from main thread.
Available in Mac OS X v10.7. Available in iOS v7.0.
- (VPNUAccountUserInfo *)userInfoWithError:(NSError **)error;
nil
.Currently logged-in user's account information.
It blocks a calling thread.
This method shouldn't be called from main thread.
VPNUAccountUserInfo
Available in Mac OS X v10.7. Available in iOS v7.0.