com.google.appengine.api.socket.dev
Class SocketPermissions

java.lang.Object
  extended by com.google.appengine.api.socket.dev.SocketPermissions

public class SocketPermissions
extends java.lang.Object

Indicates what aspects of socket services the application is allowed to use in the development server.


Constructor Summary
SocketPermissions(boolean canBind, boolean canListen, boolean canConnect, boolean canSetSocketOpt)
           
 
Method Summary
 void checkBind()
          Returns true if the application is allowed to bind.
 void checkConnect()
          Returns true if the application is allowed to connect.
 void checkListen()
          Returns true if the application is is allowed to listen.
 void checkSetSocketOpt()
          Returns true if the application is allowed to call setSocketOpt.
static SocketPermissions getSocketPermissions()
          Get the socket permissions for the current environment.
static void setDefaultSocketPermissions(java.lang.String canBind, java.lang.String canListen, java.lang.String canConnect, java.lang.String canSetSocketOpt)
          Set the socket permissions for the current environment.
static void setSocketPermissions(boolean canBind, boolean canListen, boolean canConnect, boolean canSetSocketOpt)
          Set the socket permissions for the current environment.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SocketPermissions

public SocketPermissions(boolean canBind,
                         boolean canListen,
                         boolean canConnect,
                         boolean canSetSocketOpt)
Method Detail

checkBind

public void checkBind()
Returns true if the application is allowed to bind.


checkListen

public void checkListen()
Returns true if the application is is allowed to listen.


checkConnect

public void checkConnect()
Returns true if the application is allowed to connect.


checkSetSocketOpt

public void checkSetSocketOpt()
Returns true if the application is allowed to call setSocketOpt.


setDefaultSocketPermissions

public static void setDefaultSocketPermissions(java.lang.String canBind,
                                               java.lang.String canListen,
                                               java.lang.String canConnect,
                                               java.lang.String canSetSocketOpt)
Set the socket permissions for the current environment. A null permission indicates retaining the previous default permission.


setSocketPermissions

public static void setSocketPermissions(boolean canBind,
                                        boolean canListen,
                                        boolean canConnect,
                                        boolean canSetSocketOpt)
Set the socket permissions for the current environment.


getSocketPermissions

public static SocketPermissions getSocketPermissions()
Get the socket permissions for the current environment.