Skip to content

Commit

Permalink
More CS compatibility
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.php.net/repository/pear/packages/Net_Wifi/trunk@239235 c90b9560-bf6c-de11-be94-00142212c4b1
  • Loading branch information
cweiske committed Jul 6, 2007
1 parent 3efaa1d commit fc60ef9
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 37 deletions.
55 changes: 21 additions & 34 deletions Net/Wifi.php
Original file line number Diff line number Diff line change
@@ -1,40 +1,25 @@
<?php
/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
/**
* A class for scanning wireless networks and identifying
* local wireless network interfaces.
*
* PHP versions 4 and 5
*
* LICENSE: This source file is subject to version 3.0 of the PHP license
* that is available through the world-wide-web at the following URI:
* http://www.php.net/license/3_0.txt. If you did not receive a copy of
* the PHP License and are unable to obtain it through the web, please
* send a note to [email protected] so we can mail you a copy immediately.
*
* @author Christian Weiske <[email protected]>
* @category Networking
* @package Net_Wifi
* @license http://www.gnu.org/copyleft/lesser.html LGPL License 2.1
* @version CVS: $Id$
*/

require_once 'Net/Wifi/Cell.php';
require_once 'Net/Wifi/Config.php';
//required for System::which() functionality
require_once 'System.php';

/**
* This class uses tools like iwconfig and iwlist to scan
* for wireless networks
* A class for scanning wireless networks and identifying
* local wireless network interfaces.
*
* @author Christian Weiske <[email protected]>
* @category Networking
* @package Net_Wifi
* @author Christian Weiske <[email protected]>
* @license http://www.gnu.org/copyleft/lesser.html LGPL License 2.1
* @version CVS: $Id$
* @link http://pear.php.net/package/Net_Wifi
*/
class Net_Wifi
{
/**
* Various locations of programs
* @var array
* Various locations of programs
* @var array
*/
var $arFileLocation = array(
'iwconfig' => '/usr/sbin/iwconfig',
Expand All @@ -45,7 +30,7 @@ class Net_Wifi


/**
* Constructor which tries to guess the paths of the tools
* Constructor which tries to guess the paths of the tools
*/
function Net_Wifi()
{
Expand All @@ -68,11 +53,13 @@ function Net_Wifi()


/**
* Returns an object with the current state of the interface (connected/not connected, AP,...).
* Returns an object with the current state of the interface
* (connected/not connected, AP,...).
*
* @access public
* @param string The interface to check
* @return Net_Wifi_Config The state information
* @param string $strInterface The interface to check
*
* @return Net_Wifi_Config The state information
* @access public
*/
function getCurrentConfig($strInterface)
{
Expand All @@ -87,11 +74,11 @@ function getCurrentConfig($strInterface)


/**
* Parses the iwconfig output to collect the current config information.
* Parses the iwconfig output to collect the current config information.
*
* @access protected
* @param string The iwconfig output to parse
* @return Net_Wifi_Config The current config object
* @access protected
* @param string $strAll The iwconfig output to parse
* @return Net_Wifi_Config The current config object
*/
function parseCurrentConfig($strAll)
{
Expand Down
10 changes: 7 additions & 3 deletions Net/Wifi/Cell.php
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
<?php

/**
* Cell information from a wifi scan.
* Cell information from a wifi scan.
*
* @author Christian Weiske <[email protected]>
* @category Networking
* @package Net_Wifi
* @author Christian Weiske <[email protected]>
* @license http://www.gnu.org/copyleft/lesser.html LGPL License 2.1
* @version CVS: $Id$
* @link http://pear.php.net/package/Net_Wifi
*/
class Net_Wifi_Cell
{
Expand Down

0 comments on commit fc60ef9

Please sign in to comment.