You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

NfcDevice.h 637B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. //
  2. // Created by robin on 6/19/16.
  3. //
  4. #ifndef MIFARE_TOOLS_NFCDEVICEDBO_H
  5. #define MIFARE_TOOLS_NFCDEVICEDBO_H
  6. #include <string>
  7. #include <nfc/nfc-types.h>
  8. #include <DBO/Result.h>
  9. #include "LibNfc.h"
  10. class LibNfc;
  11. class NfcDevice
  12. {
  13. public:
  14. NfcDevice(LibNfc* libNfc, std::string connStr);
  15. ~NfcDevice();
  16. ResultBool open();
  17. void close();
  18. bool isOpened();
  19. const std::string & getConnStr() const;
  20. void setConnStr(const std::string &connStr);
  21. nfc_device * getDevice() const;
  22. private:
  23. std::string _connStr;
  24. nfc_device* _device;
  25. LibNfc* _libNfc;
  26. };
  27. #endif //MIFARE_TOOLS_NFCDEVICEDBO_H