1/* 2 * Copyright 2016 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 */ 16 17package [email protected]; 18 19/** 20 * Interface exposed by the supplicant for each network configuration it 21 * controls. 22 * A network is the supplicant's way of representing the configuration 23 * parameters of a Wifi service set. Service sets are identified by their 24 * service set identitifier (SSID). The parameters for a network includes the 25 * credentials, bssid, etc. 26 */ 27interface ISupplicantNetwork { 28 /** 29 * Retrieves the ID allocated to this network by the supplicant. 30 * 31 * This is not the |SSID| of the network, but an internal identifier for 32 * this network used by the supplicant. 33 * 34 * @return status Status of the operation. 35 * Possible status codes: 36 * |SupplicantStatusCode.SUCCESS|, 37 * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| 38 * @return id Network ID. 39 */ 40 getId() generates (SupplicantStatus status, SupplicantNetworkId id); 41 42 /** 43 * Retrieves the name of the interface this network belongs to. 44 * 45 * @return status Status of the operation. 46 * Possible status codes: 47 * |SupplicantStatusCode.SUCCESS|, 48 * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| 49 * @return Name of the network interface, e.g., wlan0 50 */ 51 getInterfaceName() generates (SupplicantStatus status, string name); 52 53 /** 54 * Retrieves the type of the interface this network belongs to. 55 * 56 * @return status Status of the operation. 57 * Possible status codes: 58 * |SupplicantStatusCode.SUCCESS|, 59 * |SupplicantStatusCode.FAILURE_IFACE_INVALID| 60 * @return type Type of the network interface, e.g., STA. 61 */ 62 getType() generates (SupplicantStatus status, IfaceType type); 63}; 64