-rw-r--r-- | libopie2/opienet/onetwork.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libopie2/opienet/onetwork.h b/libopie2/opienet/onetwork.h index e1545dd..0eb4542 100644 --- a/libopie2/opienet/onetwork.h +++ b/libopie2/opienet/onetwork.h | |||
@@ -18,48 +18,49 @@ | |||
18 | + . -:. = it will be useful, but WITHOUT ANY WARRANTY; | 18 | + . -:. = it will be useful, but WITHOUT ANY WARRANTY; |
19 | : .. .:, . . . without even the implied warranty of | 19 | : .. .:, . . . without even the implied warranty of |
20 | =_ + =;=|` MERCHANTABILITY or FITNESS FOR A | 20 | =_ + =;=|` MERCHANTABILITY or FITNESS FOR A |
21 | _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU | 21 | _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU |
22 | ..}^=.= = ; Library General Public License for more | 22 | ..}^=.= = ; Library General Public License for more |
23 | ++= -. .` .: details. | 23 | ++= -. .` .: details. |
24 | : = ...= . :.=- | 24 | : = ...= . :.=- |
25 | -. .:....=;==+<; You should have received a copy of the GNU | 25 | -. .:....=;==+<; You should have received a copy of the GNU |
26 | -_. . . )=. = Library General Public License along with | 26 | -_. . . )=. = Library General Public License along with |
27 | -- :-=` this library; see the file COPYING.LIB. | 27 | -- :-=` this library; see the file COPYING.LIB. |
28 | If not, write to the Free Software Foundation, | 28 | If not, write to the Free Software Foundation, |
29 | Inc., 59 Temple Place - Suite 330, | 29 | Inc., 59 Temple Place - Suite 330, |
30 | Boston, MA 02111-1307, USA. | 30 | Boston, MA 02111-1307, USA. |
31 | 31 | ||
32 | */ | 32 | */ |
33 | 33 | ||
34 | #ifndef ONETWORK_H | 34 | #ifndef ONETWORK_H |
35 | #define ONETWORK_H | 35 | #define ONETWORK_H |
36 | 36 | ||
37 | #include "wireless.h" | 37 | #include "wireless.h" |
38 | 38 | ||
39 | /* OPIE */ | 39 | /* OPIE */ |
40 | 40 | ||
41 | #include <opie2/onetutils.h> | 41 | #include <opie2/onetutils.h> |
42 | #include <opie2/ostation.h> | ||
42 | 43 | ||
43 | /* QT */ | 44 | /* QT */ |
44 | 45 | ||
45 | #include <qvaluelist.h> | 46 | #include <qvaluelist.h> |
46 | #include <qdict.h> | 47 | #include <qdict.h> |
47 | #include <qmap.h> | 48 | #include <qmap.h> |
48 | #include <qobject.h> | 49 | #include <qobject.h> |
49 | #include <qhostaddress.h> | 50 | #include <qhostaddress.h> |
50 | 51 | ||
51 | class ONetworkInterface; | 52 | class ONetworkInterface; |
52 | class OWirelessNetworkInterface; | 53 | class OWirelessNetworkInterface; |
53 | class OChannelHopper; | 54 | class OChannelHopper; |
54 | class OMonitoringInterface; | 55 | class OMonitoringInterface; |
55 | 56 | ||
56 | /*====================================================================================== | 57 | /*====================================================================================== |
57 | * ONetwork | 58 | * ONetwork |
58 | *======================================================================================*/ | 59 | *======================================================================================*/ |
59 | 60 | ||
60 | /** | 61 | /** |
61 | * @brief A container class for all network interfaces | 62 | * @brief A container class for all network interfaces |
62 | * | 63 | * |
63 | * This class provides access to all available network interfaces of your computer. | 64 | * This class provides access to all available network interfaces of your computer. |
64 | * | 65 | * |
65 | * @author Michael 'Mickey' Lauer <mickey@tm.informatik.uni-frankfurt.de> | 66 | * @author Michael 'Mickey' Lauer <mickey@tm.informatik.uni-frankfurt.de> |
@@ -385,63 +386,63 @@ class OWirelessNetworkInterface : public ONetworkInterface | |||
385 | virtual void setNickName( const QString& nickname ); | 386 | virtual void setNickName( const QString& nickname ); |
386 | /** | 387 | /** |
387 | * @returns the current station nickname. | 388 | * @returns the current station nickname. |
388 | */ | 389 | */ |
389 | virtual QString nickName() const; | 390 | virtual QString nickName() const; |
390 | /** | 391 | /** |
391 | * Invoke the private IOCTL @a command with a @number of parameters on the network interface. | 392 | * Invoke the private IOCTL @a command with a @number of parameters on the network interface. |
392 | * @see OPrivateIOCTL | 393 | * @see OPrivateIOCTL |
393 | */ | 394 | */ |
394 | virtual void setPrivate( const QString& command, int number, ... ); | 395 | virtual void setPrivate( const QString& command, int number, ... ); |
395 | /** | 396 | /** |
396 | * @returns true if the interface is featuring the private IOCTL @command. | 397 | * @returns true if the interface is featuring the private IOCTL @command. |
397 | */ | 398 | */ |
398 | virtual bool hasPrivate( const QString& command ); | 399 | virtual bool hasPrivate( const QString& command ); |
399 | virtual void getPrivate( const QString& command ); //FIXME: Implement and document this | 400 | virtual void getPrivate( const QString& command ); //FIXME: Implement and document this |
400 | /** | 401 | /** |
401 | * @returns true if the interface is associated to an access point | 402 | * @returns true if the interface is associated to an access point |
402 | * @note: This information is only valid if the interface is in managed mode. | 403 | * @note: This information is only valid if the interface is in managed mode. |
403 | */ | 404 | */ |
404 | virtual bool isAssociated() const; | 405 | virtual bool isAssociated() const; |
405 | /** | 406 | /** |
406 | * @returns the MAC address of the Access Point if the device is in infrastructure mode. | 407 | * @returns the MAC address of the Access Point if the device is in infrastructure mode. |
407 | * @returns a (more or less random) cell ID address if the device is in adhoc mode. | 408 | * @returns a (more or less random) cell ID address if the device is in adhoc mode. |
408 | */ | 409 | */ |
409 | virtual QString associatedAP() const; | 410 | virtual OMacAddress associatedAP() const; |
410 | /** | 411 | /** |
411 | * Set the @a ssid (Service Set ID) string. This is used to decide | 412 | * Set the @a ssid (Service Set ID) string. This is used to decide |
412 | * which network to associate with (use "any" to let the driver decide). | 413 | * which network to associate with (use "any" to let the driver decide). |
413 | */ | 414 | */ |
414 | virtual void setSSID( const QString& ssid ); | 415 | virtual void setSSID( const QString& ssid ); |
415 | /** | 416 | /** |
416 | * @returns the current SSID (Service Set ID). | 417 | * @returns the current SSID (Service Set ID). |
417 | */ | 418 | */ |
418 | virtual QString SSID() const; | 419 | virtual QString SSID() const; |
419 | /** | 420 | /** |
420 | * Perform scanning the wireless network neighbourhood. | 421 | * Perform scanning the wireless network neighbourhood. |
421 | * @note: UNSTABLE API - UNDER CONSTRUCTION - DON'T USE! | 422 | * @note: UNSTABLE API - UNDER CONSTRUCTION - DON'T USE! |
422 | */ | 423 | */ |
423 | virtual int scanNetwork(); | 424 | virtual OStationList* scanNetwork(); |
424 | 425 | ||
425 | protected: | 426 | protected: |
426 | void buildInformation(); | 427 | void buildInformation(); |
427 | void buildPrivateList(); | 428 | void buildPrivateList(); |
428 | void dumpInformation() const; | 429 | void dumpInformation() const; |
429 | virtual void init(); | 430 | virtual void init(); |
430 | struct iwreq& iwr() const; | 431 | struct iwreq& iwr() const; |
431 | bool wioctl( int call ) const; | 432 | bool wioctl( int call ) const; |
432 | bool wioctl( int call, struct iwreq& ) const; | 433 | bool wioctl( int call, struct iwreq& ) const; |
433 | 434 | ||
434 | protected: | 435 | protected: |
435 | mutable struct iwreq _iwr; | 436 | mutable struct iwreq _iwr; |
436 | QMap<int,int> _channels; | 437 | QMap<int,int> _channels; |
437 | struct iw_range _range; | 438 | struct iw_range _range; |
438 | 439 | ||
439 | private: | 440 | private: |
440 | OChannelHopper* _hopper; | 441 | OChannelHopper* _hopper; |
441 | }; | 442 | }; |
442 | 443 | ||
443 | 444 | ||
444 | /*====================================================================================== | 445 | /*====================================================================================== |
445 | * OMonitoringInterface | 446 | * OMonitoringInterface |
446 | *======================================================================================*/ | 447 | *======================================================================================*/ |
447 | 448 | ||