blob: 9d7cbd9f2380795cbc133df2f37766680713863d [file] [log] [blame]
San Mehatdc266072009-05-06 11:16:52 -07001/*
2 * Copyright (C) 2008 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
San Mehat3c5a6f02009-05-22 15:36:13 -070016
San Mehatdc266072009-05-06 11:16:52 -070017#ifndef _SUPPLICANT_EVENT_H
18#define _SUPPLICANT_EVENT_H
19
20#include <sys/types.h>
21
22class SupplicantEvent {
23private:
24 int mType;
San Mehatdc266072009-05-06 11:16:52 -070025 int mLevel;
26
27public:
San Mehat3aff2d12009-06-15 14:10:44 -070028 static const int EVENT_UNKNOWN = 0;
29 static const int EVENT_CONNECTED = 1;
30 static const int EVENT_DISCONNECTED = 2;
31 static const int EVENT_TERMINATING = 3;
32 static const int EVENT_PASSWORD_CHANGED = 4;
33 static const int EVENT_EAP_NOTIFICATION = 5;
34 static const int EVENT_EAP_STARTED = 6;
35 static const int EVENT_EAP_METHOD = 7;
36 static const int EVENT_EAP_SUCCESS = 8;
37 static const int EVENT_EAP_FAILURE = 9;
38 static const int EVENT_SCAN_RESULTS = 10;
39 static const int EVENT_STATE_CHANGE = 11;
40 static const int EVENT_LINK_SPEED = 12;
41 static const int EVENT_DRIVER_STATE = 13;
42 static const int EVENT_ASSOCIATING = 14;
43 static const int EVENT_ASSOCIATED = 15;
44 static const int EVENT_CONNECTIONTIMEOUT = 16;
San Mehatdc266072009-05-06 11:16:52 -070045
46public:
San Mehat3aff2d12009-06-15 14:10:44 -070047 SupplicantEvent(int type, int level);
48 virtual ~SupplicantEvent() {}
San Mehatdc266072009-05-06 11:16:52 -070049
50 int getType() { return mType; }
San Mehatdc266072009-05-06 11:16:52 -070051 int getLevel() { return mLevel; }
52};
53
54#endif