public List <Beacon> GetActiveBeeacons() { List <Beacon> beacons = new List <Beacon>(); List <MyDeviceView> devlist = bluetooth.GetDeviceList(); BeaconDB.Upload(); foreach (MyDeviceView device in devlist) { if (BeaconDB.Contains(device.id.ToString())) { beacons.Add(BeaconDB.Get(device.id.ToString())); } } return(beacons); }
public override string ToString() { string id_str = Device.Id.ToString(); string id_short_str = GetShortName(); string name_str; string in_base_flag; if (this.Device.Name != null) { name_str = Device.Name.ToString(); } else { name_str = "n/a"; } if (BeaconDB.Contains(Device)) { in_base_flag = BeaconDB.Get(id_str).ToString(); return("IB: " + in_base_flag); } return(id_short_str + " " + name_str); }
public BeaconFilter(BluetoothDataLayer bluetooth) { this.bluetooth = bluetooth; BeaconDB.Initialize(); }