Paul Stewart | 196f50f | 2013-03-27 18:02:11 -0700 | [diff] [blame] | 1 | // Copyright (c) 2013 The Chromium OS Authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | |
| 5 | #ifndef SUPPLICANT_EVENT_DELEGATE_INTERFACE_H_ |
| 6 | #define SUPPLICANT_EVENT_DELEGATE_INTERFACE_H_ |
| 7 | |
| 8 | #include <map> |
| 9 | #include <string> |
| 10 | |
| 11 | #include <dbus-c++/dbus.h> |
| 12 | |
| 13 | namespace shill { |
| 14 | |
| 15 | // SupplicantEventDelegateInterface declares the set of methods that |
| 16 | // a SupplicantInterfaceProxy calls on an interested party when |
| 17 | // wpa_supplicant events occur on the network interface interface. |
| 18 | class SupplicantEventDelegateInterface { |
| 19 | public: |
| 20 | typedef std::map<std::string, ::DBus::Variant> PropertyMap; |
| 21 | |
| 22 | virtual ~SupplicantEventDelegateInterface() {} |
| 23 | |
Paul Stewart | 9413bcc | 2013-04-04 16:12:43 -0700 | [diff] [blame] | 24 | // Supplicant has added a BSS to its table of visible endpoints. |
Paul Stewart | 196f50f | 2013-03-27 18:02:11 -0700 | [diff] [blame] | 25 | virtual void BSSAdded(const ::DBus::Path &BSS, |
| 26 | const PropertyMap &properties) = 0; |
Paul Stewart | 9413bcc | 2013-04-04 16:12:43 -0700 | [diff] [blame] | 27 | |
| 28 | // Supplicant has removed a BSS from its table of visible endpoints. |
Paul Stewart | 196f50f | 2013-03-27 18:02:11 -0700 | [diff] [blame] | 29 | virtual void BSSRemoved(const ::DBus::Path &BSS) = 0; |
Paul Stewart | 9413bcc | 2013-04-04 16:12:43 -0700 | [diff] [blame] | 30 | |
| 31 | // Supplicant has received a certficate from the remote server during |
| 32 | // the process of authentication. |
Paul Stewart | 196f50f | 2013-03-27 18:02:11 -0700 | [diff] [blame] | 33 | virtual void Certification(const PropertyMap &properties) = 0; |
Paul Stewart | 9413bcc | 2013-04-04 16:12:43 -0700 | [diff] [blame] | 34 | |
| 35 | // Supplicant state machine has output an EAP event notification. |
Paul Stewart | 196f50f | 2013-03-27 18:02:11 -0700 | [diff] [blame] | 36 | virtual void EAPEvent(const std::string &status, |
| 37 | const std::string ¶meter) = 0; |
Paul Stewart | 9413bcc | 2013-04-04 16:12:43 -0700 | [diff] [blame] | 38 | |
| 39 | // The interface element in the supplicant has changed one or more |
| 40 | // properties. |
Paul Stewart | 196f50f | 2013-03-27 18:02:11 -0700 | [diff] [blame] | 41 | virtual void PropertiesChanged(const PropertyMap &properties) = 0; |
Paul Stewart | 9413bcc | 2013-04-04 16:12:43 -0700 | [diff] [blame] | 42 | |
| 43 | // A scan has completed on this interface. |
Paul Stewart | 196f50f | 2013-03-27 18:02:11 -0700 | [diff] [blame] | 44 | virtual void ScanDone() = 0; |
| 45 | }; |
| 46 | |
| 47 | } // namespace shill |
| 48 | |
| 49 | #endif // SUPPLICANT_EVENT_DELEGATE_INTERFACE_H_ |