WifiScanner.h (936B)
1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 2 /* vim: set ts=2 et sw=2 tw=80: */ 3 /* This Source Code Form is subject to the terms of the Mozilla Public 4 * License, v. 2.0. If a copy of the MPL was not distributed with this 5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 6 7 #pragma once 8 9 #include "nsTArray.h" 10 #include "mozilla/RefPtr.h" 11 12 class nsIWifiAccessPoint; 13 14 namespace mozilla { 15 16 class WifiScanner { 17 public: 18 /** 19 * GetAccessPointsFromWLAN 20 * 21 * Scans the available wireless interfaces for nearby access points and 22 * populates the supplied collection with them 23 * 24 * @param accessPoints The collection to populate with available APs 25 * @return NS_OK on success, failure codes on failure 26 */ 27 virtual nsresult GetAccessPointsFromWLAN( 28 nsTArray<RefPtr<nsIWifiAccessPoint>>& accessPoints) = 0; 29 30 virtual ~WifiScanner() = default; 31 }; 32 33 } // namespace mozilla