org.atmosphere.jersey
Class AtmosphereFilter

java.lang.Object
  extended by org.atmosphere.jersey.AtmosphereFilter
All Implemented Interfaces:
com.sun.jersey.spi.container.ResourceFilterFactory

public class AtmosphereFilter
extends Object
implements com.sun.jersey.spi.container.ResourceFilterFactory

ResourceFilterFactory which intercept the response and appropriately set the AtmosphereResourceEvent filed based on the annotation the application has defined.

Author:
Jeanfrancois Arcand

Nested Class Summary
protected static class AtmosphereFilter.Action
           
 class AtmosphereFilter.Filter
          TODO: Fix that messy class.
 
Field Summary
static String INJECTED_BROADCASTER
           
static String RESUME_CANDIDATES
           
static String RESUME_UUID
           
protected  javax.servlet.http.HttpServletRequest servletReq
           
static String SUSPENDED_RESOURCE
           
 
Constructor Summary
AtmosphereFilter()
           
 
Method Summary
 List<com.sun.jersey.spi.container.ResourceFilter> create(com.sun.jersey.api.model.AbstractMethod am)
          Create a ResourceFilter which contains the information about the annotation being processed.
protected  long translateTimeUnit(long period, TimeUnit tu)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SUSPENDED_RESOURCE

public static final String SUSPENDED_RESOURCE

RESUME_UUID

public static final String RESUME_UUID

RESUME_CANDIDATES

public static final String RESUME_CANDIDATES

INJECTED_BROADCASTER

public static final String INJECTED_BROADCASTER

servletReq

@Context
protected javax.servlet.http.HttpServletRequest servletReq
Constructor Detail

AtmosphereFilter

public AtmosphereFilter()
Method Detail

create

public List<com.sun.jersey.spi.container.ResourceFilter> create(com.sun.jersey.api.model.AbstractMethod am)
Create a ResourceFilter which contains the information about the annotation being processed.

XXX Need to filter invalid mix of annotation.

Specified by:
create in interface com.sun.jersey.spi.container.ResourceFilterFactory
Parameters:
am - an AbstractMethod
Returns:
a List of ResourceFilter to invoke.

translateTimeUnit

protected long translateTimeUnit(long period,
                                 TimeUnit tu)


Copyright © 2014. All Rights Reserved.