SCM iOS API
|
Class represents a smart card reader (either a physical, hardware reader, or a virtual smart card reader). More...
Inherits NSObject.
Instance Methods | |
(NSString *) | - getName |
(BOOL) | - isCardPresent |
(BOOL) | - isDongle |
(BOOL) | - isVirtual |
(enum ReaderStatus) | - getStatus |
(void) | - connect: |
Class represents a smart card reader (either a physical, hardware reader, or a virtual smart card reader).
Note that the constructor is not intended to be called by user code. Such objects are constructed internally by the API.
- (void) connect: | (void(^)(Token *token, NSError *error)) | completionHandler |
Connects to the card inserted in the reader. This method succeds only if the card is supported by the middleware.
Note that calling connect
stops the scan for bluetooth peripherals.
completionHandler | the completion handler to call when the connection is complete. The completion handler is executed on the main queue and takes the following parameters:
|
- (NSString *) getName |
Gets the name of the reader.
- (enum ReaderStatus) getStatus |
Gets the status of the reader, as a ReaderStatus enum. The following status can be returned:
- (BOOL) isCardPresent |
Returns YES if the card is inserted in the reader.
- (BOOL) isDongle |
Returns YES if the reader is known as an USB dongle type (as opposed to a standard ID-1 format card reader).
Note: that this is indicative, and based on an internal registry of reader names.
- (BOOL) isVirtual |
Returns YES if the reader is a virtual smart card.