BeeeOn Gateway  v2020.3.1-2-g6f737dc
Platform to interconnect the IoT world
DeviceCriteria.h
1 #pragma once
2 
3 #include <string>
4 
5 #include <Poco/Nullable.h>
6 #include <Poco/Net/IPAddress.h>
7 
8 #include "net/MACAddress.h"
9 
10 namespace BeeeOn {
11 
21 public:
22  DeviceCriteria(const Poco::Net::IPAddress &address);
23  DeviceCriteria(const MACAddress &address);
24  DeviceCriteria(const uint64_t serialNumber);
25 
26  bool hasIPAddress() const;
27  Poco::Net::IPAddress ipAddress() const;
28 
29  bool hasMACAddress() const;
30  MACAddress macAddress() const;
31 
32  bool hasSerialNumber() const;
33  uint64_t serialNumber() const;
34 
35  std::string toString() const;
36 
37 private:
38  Poco::Nullable<Poco::Net::IPAddress> m_ipAddress;
39  Poco::Nullable<MACAddress> m_macAddress;
40  Poco::Nullable<uint64_t> m_serialNumber;
41 };
42 
43 }
Definition: MACAddress.h:8
DeviceCriteria holds a criteria for device searching. Device can be search by one of the following pr...
Definition: DeviceCriteria.h:20