static addCard(cycleList, startDate, endDate, lockData, progress, success, fail) {
    progress = progress || this.defaultCallback;
    success = success || this.defaultCallback;
    fail = fail || this.defaultCallback;
    cycleList = cycleList || [];
    let subscription = ttlockEventEmitter.addListener(TTLockEvent.AddCardProgrress, () => {
      progress();
    });
    ttlockModule.addCard(cycleList, startDate, endDate, lockData, cardNumber => {
      subscription.remove();
      success(cardNumber);
    }, (errorCode, errorDesc) => {
      subscription.remove();
      fail(errorCode, errorDesc);
    });
  }
/**
   * Add a card to unlock the lock
   * @param cycleList Periodic unlocking. You can set it to null if you don't need it
   * @param startDate Timestamp millisecond. The start valid time of the card.
   * @param endDate Timestamp millisecond. The expiration time of the card
   * @param lockData 
   * @param progress 
   * @param success 
   * @param fail 
   */
Add a card to unlock the lock
@param cycleList Periodic unlocking. You can set it to null if you don't need it
@param startDate Timestamp millisecond. The start valid time of the card.
@param endDate Timestamp millisecond. The expiration time of the card
@param lockData
@param progress
@param success
@param fail
Add a card to unlock the lock @param cycleList Periodic unlocking . You can set it to null if you don ' t need it @param startDate Timestamp millisecond . The start valid time of the card . @param endDate Timestamp millisecond . The expiration time of the card @param lockData @param progress @param success @param fail
static addCard(cycleList, startDate, endDate, lockData, progress, success, fail) {
    progress = progress || this.defaultCallback;
    success = success || this.defaultCallback;
    fail = fail || this.defaultCallback;
    cycleList = cycleList || [];
    let subscription = ttlockEventEmitter.addListener(TTLockEvent.AddCardProgrress, () => {
      progress();
    });
    ttlockModule.addCard(cycleList, startDate, endDate, lockData, cardNumber => {
      subscription.remove();
      success(cardNumber);
    }, (errorCode, errorDesc) => {
      subscription.remove();
      fail(errorCode, errorDesc);
    });
  }
static addCard ( cycleList , startDate , endDate , lockData , progress , success , fail ) { progress = progress || this . defaultCallback ; success = success || this . defaultCallback ; fail = fail || this . defaultCallback ; cycleList = cycleList || [ ] ; let subscription = ttlockEventEmitter . addListener ( TTLockEvent . AddCardProgrress , ( ) => { progress ( ) ; } ) ; ttlockModule . addCard ( cycleList , startDate , endDate , lockData , cardNumber => { subscription . remove ( ) ; success ( cardNumber ) ; } , ( errorCode , errorDesc ) => { subscription . remove ( ) ; fail ( errorCode , errorDesc ) ; } ) ; }
Add a card to unlock the lock
 @param cycleList Periodic unlocking.
Add a card to unlock the lock @param cycleList Periodic unlocking .