org.apache.awf.configuration
Class Configuration

java.lang.Object
  extended by org.apache.awf.configuration.Configuration

public class Configuration
extends Object

Simple type to hold configuration options, to be passed to HttpServer .


Constructor Summary
Configuration()
           
 
Method Summary
 String getHandlerPackage()
          Retrieve the package under which RequestHandler implementations are to be found, for example "org.apache.awf".
 String getStaticDirectory()
          Retrieve directory from which static content should be retrieved.
 void setCreateETags(boolean createETags)
          Set whether ETags should be generated and applied.
 void setHandlerPackage(String handlerPackage)
          Set package under which RequestHandler implementations are to be found, for example "org.apache.awf".
 void setStaticDirectory(String staticDirectory)
          Set the directory from which static content should be retrieved.
 boolean shouldCreateETags()
          Determine whether ETags should currently be generated and applied.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Configuration

public Configuration()
Method Detail

getHandlerPackage

public String getHandlerPackage()
Retrieve the package under which RequestHandler implementations are to be found, for example "org.apache.awf".

Returns:
the current package name.

setHandlerPackage

public void setHandlerPackage(String handlerPackage)
Set package under which RequestHandler implementations are to be found, for example "org.apache.awf".

Parameters:
handlerPackage - the name of the package.

getStaticDirectory

public String getStaticDirectory()
Retrieve directory from which static content should be retrieved. Defaults to the value of DEFAULT_STATIC_DIRECTORY where empty or null.

Returns:
the current name of the static directory.

setStaticDirectory

public void setStaticDirectory(String staticDirectory)
Set the directory from which static content should be retrieved.

Parameters:
staticDirectory - the directory name for use.

shouldCreateETags

public boolean shouldCreateETags()
Determine whether ETags should currently be generated and applied.

Returns:
true if they are to be created; false otherwise.

setCreateETags

public void setCreateETags(boolean createETags)
Set whether ETags should be generated and applied.

Parameters:
createETags - true to create them; false otherwise.


Copyright © 2012. All Rights Reserved.