com.eurotech.framework.emulator.net
Class EmulatedNetworkServiceImpl

java.lang.Object
  extended by com.eurotech.framework.emulator.net.EmulatedNetworkServiceImpl
All Implemented Interfaces:
NetworkService

public class EmulatedNetworkServiceImpl
extends Object
implements NetworkService


Constructor Summary
EmulatedNetworkServiceImpl()
           
 
Method Summary
protected  void activate(org.osgi.service.component.ComponentContext componentContext)
           
protected  void deactivate(org.osgi.service.component.ComponentContext componentContext)
           
 List<NetInterface<? extends NetInterfaceAddress>> getActiveNetworkInterfaces()
          Return the active NetworkIntefaces which have active connections for the system.
 List<String> getAllNetworkInterfaceNames()
          Gets the names of all the network interface attached to the system.
 List<WifiAccessPoint> getAllWifiAccessPoints()
          Returns the list of all available WifiAccessPoints as seen from the system.
 String getModemPppPort(ModemDevice modemDevice)
           
 String getModemUsbPort(String interfaceName)
           
 List<NetInterface<? extends NetInterfaceAddress>> getNetworkInterfaces()
          Gets the names of all the network interface attached to the system.
 NetworkState getState()
          Returns the overall state of the networking subsystem
 NetInterfaceState getState(String interfaceName)
          Returns the state of a specific network interface
 List<WifiAccessPoint> getWifiAccessPoints(String wifiInterfaceName)
          Returns the list of the WifiAccessPoints visible from the specified wifi network interface.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EmulatedNetworkServiceImpl

public EmulatedNetworkServiceImpl()
Method Detail

activate

protected void activate(org.osgi.service.component.ComponentContext componentContext)

deactivate

protected void deactivate(org.osgi.service.component.ComponentContext componentContext)

getState

public NetworkState getState()
Description copied from interface: NetworkService
Returns the overall state of the networking subsystem

Specified by:
getState in interface NetworkService

getState

public NetInterfaceState getState(String interfaceName)
Description copied from interface: NetworkService
Returns the state of a specific network interface

Specified by:
getState in interface NetworkService

getAllNetworkInterfaceNames

public List<String> getAllNetworkInterfaceNames()
                                         throws EsfException
Description copied from interface: NetworkService
Gets the names of all the network interface attached to the system.

Specified by:
getAllNetworkInterfaceNames in interface NetworkService
Returns:
the names of all interfaces regardless of 'up' status
Throws:
EsfException

getNetworkInterfaces

public List<NetInterface<? extends NetInterfaceAddress>> getNetworkInterfaces()
                                                                       throws EsfException
Description copied from interface: NetworkService
Gets the names of all the network interface attached to the system. For each returned NetworkInterface, its currently active InterfaceAddresses are returned.

Specified by:
getNetworkInterfaces in interface NetworkService
Returns:
all NetworkInterfaces
Throws:
EsfException

getAllWifiAccessPoints

public List<WifiAccessPoint> getAllWifiAccessPoints()
Description copied from interface: NetworkService
Returns the list of all available WifiAccessPoints as seen from the system.

Specified by:
getAllWifiAccessPoints in interface NetworkService
Returns:
all access points accessible from the system.

getWifiAccessPoints

public List<WifiAccessPoint> getWifiAccessPoints(String wifiInterfaceName)
Description copied from interface: NetworkService
Returns the list of the WifiAccessPoints visible from the specified wifi network interface. If this wifiInterfaceName is in Master mode it will return a List with one WifiAccessPoint which is itself.

Specified by:
getWifiAccessPoints in interface NetworkService
Parameters:
wifiInterfaceName - name of the interface used to scan for the available access points
Returns:
the list of the WifiAccessPoints visible from the specified wifi network interface.

getActiveNetworkInterfaces

public List<NetInterface<? extends NetInterfaceAddress>> getActiveNetworkInterfaces()
                                                                             throws EsfException
Description copied from interface: NetworkService
Return the active NetworkIntefaces which have active connections for the system.

Specified by:
getActiveNetworkInterfaces in interface NetworkService
Returns:
Throws:
EsfException

getModemUsbPort

public String getModemUsbPort(String interfaceName)
Specified by:
getModemUsbPort in interface NetworkService

getModemPppPort

public String getModemPppPort(ModemDevice modemDevice)
                       throws EsfException
Specified by:
getModemPppPort in interface NetworkService
Throws:
EsfException


Copyright © 2013. All Rights Reserved.