com.sun.grizzly.tcp
Class DynamicContentAdapter

java.lang.Object
  extended by com.sun.grizzly.tcp.StaticResourcesAdapter
      extended by com.sun.grizzly.tcp.DynamicContentAdapter
All Implemented Interfaces:
Adapter

Deprecated. - Use GrizzlyAdapter instead.

public abstract class DynamicContentAdapter
extends StaticResourcesAdapter

Abstract Adapter that contains all the common behaviour of the Adapter implementation for standalone usage as well as embedded use.

Author:
Jerome Dochez, Jean-Francois Arcand

Nested Class Summary
 class DynamicContentAdapter.RequestTupple
          Deprecated. Statefull token used to share information with the Containers.
 
Field Summary
protected  String contextRoot
          Deprecated.  
protected static String RFC_2616_FORMAT
          Deprecated.  
 
Fields inherited from class com.sun.grizzly.tcp.StaticResourcesAdapter
cache, commitErrorResponse, fileFolders, logger, resourcesContextPath
 
Constructor Summary
DynamicContentAdapter()
          Deprecated.  
DynamicContentAdapter(String publicDirectory)
          Deprecated.  
 
Method Summary
 void afterService(Request req, Response res)
          Deprecated. Finish the Response and recycle the Request and the Response.
 String getContextRoot()
          Deprecated.  
protected abstract  int getTokenID()
          Deprecated.  
 void service(Request req, Response res)
          Deprecated. Based on the Request URI, try to map the file from the rootFolder, and send it synchronously using send file.
protected abstract  void serviceDynamicContent(Request req, Response res)
          Deprecated.  
 void setContextRoot(String contextRoot)
          Deprecated.  
 
Methods inherited from class com.sun.grizzly.tcp.StaticResourcesAdapter
addRootFolder, customizedErrorPage, getDefaultContentType, getResourcesContextPath, getRootFolder, getRootFolders, initWebDir, isUseSendFile, service, setDefaultContentType, setLogger, setResourcesContextPath, setRootFolder, setUseSendFile
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RFC_2616_FORMAT

protected static final String RFC_2616_FORMAT
Deprecated. 
See Also:
Constant Field Values

contextRoot

protected String contextRoot
Deprecated. 
Constructor Detail

DynamicContentAdapter

public DynamicContentAdapter()
Deprecated. 

DynamicContentAdapter

public DynamicContentAdapter(String publicDirectory)
Deprecated. 
Method Detail

getTokenID

protected abstract int getTokenID()
Deprecated. 

serviceDynamicContent

protected abstract void serviceDynamicContent(Request req,
                                              Response res)
                                       throws IOException
Deprecated. 
Throws:
IOException

afterService

public void afterService(Request req,
                         Response res)
                  throws Exception
Deprecated. 
Description copied from class: StaticResourcesAdapter
Finish the Response and recycle the Request and the Response. If the StaticResourcesAdapter.commitErrorResponse is set to false, this method does nothing.

Specified by:
afterService in interface Adapter
Overrides:
afterService in class StaticResourcesAdapter
Parameters:
req - Request
res - Response
Throws:
Exception

service

public void service(Request req,
                    Response res)
             throws Exception
Deprecated. 
Description copied from class: StaticResourcesAdapter
Based on the Request URI, try to map the file from the rootFolder, and send it synchronously using send file.

Specified by:
service in interface Adapter
Overrides:
service in class StaticResourcesAdapter
Parameters:
req - the Request
res - the Response
Throws:
Exception - if an error happens during handling of the request. Common errors are:
  • IOException if an input/output error occurs and we are processing an included servlet (otherwise it is swallowed and handled by the top level error handler mechanism)
  • ServletException if a servlet throws an exception and we are processing an included servlet (otherwise it is swallowed and handled by the top level error handler mechanism)

setContextRoot

public void setContextRoot(String contextRoot)
Deprecated. 

getContextRoot

public String getContextRoot()
Deprecated. 


Copyright © 2012 Oracle Corporation. All Rights Reserved.