org.atmosphere.util
Class Utils

java.lang.Object
  extended by org.atmosphere.util.Utils

public final class Utils
extends Object

Utils class.

Author:
Jeanfrancois Arcand

Constructor Summary
Utils()
           
 
Method Summary
static boolean atmosphereProtocol(AtmosphereRequest r)
           
static boolean firefoxWebSocketEnabled(javax.servlet.http.HttpServletRequest request)
           
static Object invoke(Object proxiedInstance, Method m, Object o)
           Manages the invocation of the given method on the specified 'proxied' instance.
static boolean pollableTransport(AtmosphereResource.TRANSPORT t)
           
static boolean properProtocol(javax.servlet.http.HttpServletRequest request)
           
static boolean pushMessage(AtmosphereResource.TRANSPORT t)
           
static boolean resumableTransport(AtmosphereResource.TRANSPORT t)
           
static boolean twoConnectionsTransport(AtmosphereResource.TRANSPORT t)
           
static boolean webSocketEnabled(javax.servlet.http.HttpServletRequest request)
           
static boolean webSocketMessage(AtmosphereResource r)
           
static AtmosphereResource websocketResource(AtmosphereResource r)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Utils

public Utils()
Method Detail

webSocketEnabled

public static final boolean webSocketEnabled(javax.servlet.http.HttpServletRequest request)

firefoxWebSocketEnabled

public static final boolean firefoxWebSocketEnabled(javax.servlet.http.HttpServletRequest request)

twoConnectionsTransport

public static final boolean twoConnectionsTransport(AtmosphereResource.TRANSPORT t)

resumableTransport

public static final boolean resumableTransport(AtmosphereResource.TRANSPORT t)

pollableTransport

public static final boolean pollableTransport(AtmosphereResource.TRANSPORT t)

pushMessage

public static final boolean pushMessage(AtmosphereResource.TRANSPORT t)

atmosphereProtocol

public static final boolean atmosphereProtocol(AtmosphereRequest r)

webSocketMessage

public static final boolean webSocketMessage(AtmosphereResource r)

properProtocol

public static boolean properProtocol(javax.servlet.http.HttpServletRequest request)

websocketResource

public static final AtmosphereResource websocketResource(AtmosphereResource r)

invoke

public static Object invoke(Object proxiedInstance,
                            Method m,
                            Object o)

Manages the invocation of the given method on the specified 'proxied' instance. Logs any invocation failure.

Parameters:
proxiedInstance - the instance
m - the method to invoke that belongs to the instance
o - the optional parameter
Returns:
the result of the invocation


Copyright © 2014. All Rights Reserved.