wt.security
Class NetAccess

java.lang.Object
  extended bywt.security.Access
      extended bywt.security.NetAccess
Direct Known Subclasses:
NetAccess_plugin

public class NetAccess
extends Access

Class that provides wrappers to priviledged network methods using the wt.security package. This allows applets to perform network operations that are typically restricted by the sandbox.

Supported API: true


Field Summary
 
Fields inherited from class wt.security.Access
 
Constructor Summary
NetAccess()
           
 
Method Summary
 void connect(URLConnection connection)
          Wrapper for URLConnection.connect() method
(package private)  void connect0(URLConnection connection)
           
 byte[] getAddress(InetAddress inetaddress)
          Wrapper for InetAddress.getAddress() method
(package private)  byte[] getAddress0(InetAddress inetaddress)
           
 String getHostAddress(InetAddress inetaddress)
          Wrapper for InetAddress.getHostAddress() method
(package private)  String getHostAddress0(InetAddress inetaddress)
           
 String getHostName(InetAddress inetaddress)
          Wrapper for InetAddress.getHostName() method
(package private)  String getHostName0(InetAddress inetaddress)
           
 InetAddress getLocalHost()
          Wrapper for InetAddress.getLocalHost() method

Supported API: true
(package private)  InetAddress getLocalHost0()
           
static NetAccess getNetAccess()
          Get instance of NetAccess.
static NetAccess getNetAccess(Frame parentFrame)
          Get instance of NetAccess.
 
Methods inherited from class wt.security.Access
checkAccess, checkAccessAll, checkClass, checkClass, checkClass, getAccessImpl, setParentFrame
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NetAccess

public NetAccess()
Method Detail

getNetAccess

public static NetAccess getNetAccess(Frame parentFrame)
Get instance of NetAccess. This instance can then be used to perform network operations that are typically restricted by the sandbox.

Parameters:
parentFrame - the parent frame for security dialog boxes that may be presented

Supported API: true

getNetAccess

public static NetAccess getNetAccess()
Get instance of NetAccess. This instance can then be used to perform network operations that are typically restricted by the sandbox.

Supported API: true


connect

public void connect(URLConnection connection)
             throws WTSecurityException,
                    IOException
Wrapper for URLConnection.connect() method

Parameters:
connection - the URLConnection object to be connected

Supported API: true
Throws:
WTSecurityException
IOException

connect0

void connect0(URLConnection connection)
        throws WTSecurityException,
               IOException
Throws:
WTSecurityException
IOException

getLocalHost

public InetAddress getLocalHost()
                         throws WTSecurityException,
                                UnknownHostException
Wrapper for InetAddress.getLocalHost() method

Supported API: true

Throws:
WTSecurityException
UnknownHostException

getLocalHost0

InetAddress getLocalHost0()
                    throws WTSecurityException,
                           UnknownHostException
Throws:
WTSecurityException
UnknownHostException

getAddress

public byte[] getAddress(InetAddress inetaddress)
                  throws WTSecurityException
Wrapper for InetAddress.getAddress() method

Parameters:
inetaddress - the InetAddress object to retrieve address for

Supported API: true
Throws:
WTSecurityException

getAddress0

byte[] getAddress0(InetAddress inetaddress)
             throws WTSecurityException
Throws:
WTSecurityException

getHostAddress

public String getHostAddress(InetAddress inetaddress)
                      throws WTSecurityException
Wrapper for InetAddress.getHostAddress() method

Parameters:
inetaddress - the InetAddress object to retrieve address for

Supported API: true
Throws:
WTSecurityException

getHostAddress0

String getHostAddress0(InetAddress inetaddress)
                 throws WTSecurityException
Throws:
WTSecurityException

getHostName

public String getHostName(InetAddress inetaddress)
                   throws WTSecurityException
Wrapper for InetAddress.getHostName() method

Parameters:
inetaddress - the InetAddress object to retrieve address for

Supported API: true
Throws:
WTSecurityException

getHostName0

String getHostName0(InetAddress inetaddress)
              throws WTSecurityException
Throws:
WTSecurityException