com.aelitis.net.upnp.impl.device
Class UPnPRootDeviceImpl

java.lang.Object
  extended by com.aelitis.net.upnp.impl.device.UPnPRootDeviceImpl
All Implemented Interfaces:
UPnPRootDevice

public class UPnPRootDeviceImpl
extends java.lang.Object
implements UPnPRootDevice


Field Summary
static boolean[] BAD_ROUTER_REPORT_FAIL
           
static java.lang.String[] BAD_ROUTER_VERSIONS
           
static java.lang.String[] ROUTERS
           
 
Constructor Summary
UPnPRootDeviceImpl(UPnPImpl _upnp, java.net.NetworkInterface _network_interface, java.net.InetAddress _local_address, java.lang.String _usn, java.net.URL _location)
           
 
Method Summary
 boolean addAlternativeLocation(java.net.URL alt_location)
           
 void addListener(UPnPRootDeviceListener l)
           
protected  void clearRelativeBaseURL()
           
 void destroy(boolean replaced)
           
protected  java.lang.String getAbsoluteURL(java.lang.String url)
           
 java.util.List<java.net.URL> getAlternativeLocations()
           
 UPnPDevice getDevice()
           
 java.util.Map getDiscoveryCache()
           
 java.lang.String getInfo()
           
 java.net.InetAddress getLocalAddress()
           
 java.net.URL getLocation()
           
 java.net.NetworkInterface getNetworkInterface()
           
 UPnP getUPnP()
           
 java.lang.String getUSN()
           
protected  boolean isBadVersion(java.lang.String current, java.lang.String bad)
           
 boolean isDestroyed()
           
 void portMappingResult(boolean ok)
           
 void removeListener(UPnPRootDeviceListener l)
           
protected  void restoreRelativeBaseURL()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ROUTERS

public static final java.lang.String[] ROUTERS

BAD_ROUTER_VERSIONS

public static final java.lang.String[] BAD_ROUTER_VERSIONS

BAD_ROUTER_REPORT_FAIL

public static final boolean[] BAD_ROUTER_REPORT_FAIL
Constructor Detail

UPnPRootDeviceImpl

public UPnPRootDeviceImpl(UPnPImpl _upnp,
                          java.net.NetworkInterface _network_interface,
                          java.net.InetAddress _local_address,
                          java.lang.String _usn,
                          java.net.URL _location)
                   throws UPnPException
Throws:
UPnPException
Method Detail

getDiscoveryCache

public java.util.Map getDiscoveryCache()
Specified by:
getDiscoveryCache in interface UPnPRootDevice

portMappingResult

public void portMappingResult(boolean ok)

getInfo

public java.lang.String getInfo()
Specified by:
getInfo in interface UPnPRootDevice

getAbsoluteURL

protected java.lang.String getAbsoluteURL(java.lang.String url)

clearRelativeBaseURL

protected void clearRelativeBaseURL()

restoreRelativeBaseURL

protected void restoreRelativeBaseURL()

getUPnP

public UPnP getUPnP()
Specified by:
getUPnP in interface UPnPRootDevice

getNetworkInterface

public java.net.NetworkInterface getNetworkInterface()
Specified by:
getNetworkInterface in interface UPnPRootDevice

getLocalAddress

public java.net.InetAddress getLocalAddress()
Specified by:
getLocalAddress in interface UPnPRootDevice

getUSN

public java.lang.String getUSN()
Specified by:
getUSN in interface UPnPRootDevice

getLocation

public java.net.URL getLocation()
Specified by:
getLocation in interface UPnPRootDevice

addAlternativeLocation

public boolean addAlternativeLocation(java.net.URL alt_location)

getAlternativeLocations

public java.util.List<java.net.URL> getAlternativeLocations()

getDevice

public UPnPDevice getDevice()
Specified by:
getDevice in interface UPnPRootDevice

destroy

public void destroy(boolean replaced)

isDestroyed

public boolean isDestroyed()
Specified by:
isDestroyed in interface UPnPRootDevice

addListener

public void addListener(UPnPRootDeviceListener l)
Specified by:
addListener in interface UPnPRootDevice

removeListener

public void removeListener(UPnPRootDeviceListener l)
Specified by:
removeListener in interface UPnPRootDevice

isBadVersion

protected boolean isBadVersion(java.lang.String current,
                               java.lang.String bad)