Java Doc for httpd.java in  » Web-Server » Jigsaw » org » w3c » jigsaw » http » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Web Server » Jigsaw » org.w3c.jigsaw.http 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.w3c.jigsaw.http.httpd

All known Subclasses:   org.w3c.jigsaw.webdav.webdavd,  org.w3c.jigsaw.https.httpsd,
httpd
public class httpd implements ServerInterface,Runnable,PropertyMonitoring,Cloneable,Status(Code)

The server main class. This class can be used either through its main method, to run a full httpd server, or simply by importing it into your app. This latter possibility allows you to export some of your application state through http.

The server itself uses this to report about memory consumption, running threads, etc.



Field Summary
public static  StringCHECKURL_P
     Name of the property indicating the URL of Jigsaw's chekpointer.
final public static  StringCLIENT_BUFSIZE_P
     Nam eof the property giving the client output buffer size.
final public static  StringCLIENT_DEBUG_P
     Name of the property indicating wether client should be debuged.
final public static  StringCLIENT_FACTORY_P
     Name of the property indicating the client factory class.
final public static  StringCLIENT_PRIORITY_P
     Name of the client thread priority property.
final public static  StringCONFIG_P
     Name of the property giving the server's config directory.
final public static  StringDEFHOSTIP_P
     If the Host property is not set (see below), you can select if you want to use FQDN (broken on some jdk implementation) or just the IP address as the default host name, it usually defaults to "false" means, use FQDN.
public static  StringDISPLAY_URL_ON_ERROR_P
    
public static  StringDOCURL_P
     Name of the property indicating the URL of Jigsaw's help.
public static  StringEDIT_ROOT_P
     Name of the property that indicates the root resource for edit.
final public static  StringFS_SENSITIVITY
     Name of the property indicating if the file-system is case sensitive.
final public static  StringHOST_P
     Name of the server host property.
final public static  StringKEEP_ALIVE_P
     Name of the server's keep alive flag. This property is used to determine wether this server should keep its connection alive.
final public static  StringKEEP_TIMEOUT_P
     Name of the server's connection time out property.
final public static  StringLENIENT_P
     Name of property indicating the "lenient" mode of HTTP parsing.
final public static  StringLOGGER_P
     Name of property indicating the logger class to use. The Jigsaw server allows you to implement your own logger.
final public static  intMAX_LOADED_STORE
    
final public static  StringMAX_LOADED_STORE_P
     Max number of store loaded in memory.
final public static  StringPORT_P
     Name of the server port property.
final public static  StringPROPS_P
     Name of the property giving the path of the property file.
public static  StringPUBLIC_P
     Name of the property indicating the public methods allowed on that server.
final public static  StringREQUEST_TIMEOUT_P
     Name of the server's request time out property. The request time out property value indicates, in milliseconds, the allowed duration of a request.
final public static  StringROOT_CLASS_P
    
final public static  StringROOT_NAME_P
     Name of the property giving the name of the root resource.
final public static  StringROOT_P
     Name of the property giving the server root directory.
public static  StringSERIALIZER_CLASS_P
     Name of the serializer class used to store resources.
public static  StringSERVER_GROUP_P
     UNIX - Name of the property that indicates the server group. When set, the server will try to turn itself to the given group name after initialization.
final public static  StringSERVER_SOFTWARE_P
     Name of the server software property.
public static  StringSERVER_USER_P
     UNIX - Name of the property that indicates the server user. When set, the server will try to turn itself to the given user name after initialization.
final public static  StringSHUFFLER_PATH_P
     Name of the property giving the shuffler path. This property should be set if you are to use the shuffler.
final public static  StringSPACE_P
     Name of the property giving the server space directory.
public static  StringSTARTUP_P
    
final public static  intSTORE_SIZE_LIMIT
    
final public static  StringSTORE_SIZE_LIMIT_P
     Max number of store loaded in memory.
final public static  StringTRACE_P
     Name of the server's trace property.
public static  StringTRASHDIR_P
     Name of the property indicating the trash directory.
final public static  StringUSE_SM_P
     Name of property that indicates if some security manager is required.
final public static  StringVERSCOUNT_P
    
final public static  booleandebug
    
 ClientFactoryfactory
    
protected  Stringhost
     FIXME check The server host name.
protected  int[]instances
    
 intmax_loaded_store
    
protected  intport
     FIXME check The server port.
protected  ObservablePropertiesprops
     This server set of properties.
public  FramedResourceroot
     This server root entity.
 intstore_size_limit
    
public  Threadthread
    
public  EventManagertimer
    
protected  URLurl
     FIXME check for clones This server URL.
final public static  intverscount
     The current internal version counter of Jigsaw.
final public static  Stringversion
     The current displayed version of Jigsaw.

Constructor Summary
public  httpd()
     Create a new server instance in this process.

Method Summary
public  booleancheckFileSystemSensitivity()
    
protected  booleancheckUpgrade(String id, ObservableProperties props)
    
public  voidcheckpoint()
     Checkpoint all cached data, by saving them to disk.
protected  voidcleanTempDirectory()
     Clean the temp dir.
protected synchronized  voidcleanup(boolean restart)
     Cleanup the resources associated with this server context.
public  ServerHandlerclone(ServerHandlerManager shm, String id, ObservableProperties props)
    
public  voiddebug(boolean onoff)
     Turn debugging on/off for this instance of httpd server.
public  EnumerationenumeratePropertySet()
    
public  voiderrlog(Client client, String msg)
     Emit a server error on behalf of some client object.
public  voiderrlog(String msg)
     Emit an error on behalf of the server.
public  voiderrlog(Object from, String msg)
     The prefered form for reporting errors.
public  voiderrlog(Resource from, String msg)
     Another nice way of reporting errors from an HTTPResource.
public  voidfatal(Exception e, String msg)
     Emit a fatal error.
public  voidfatal(String msg)
     Emit a fatal error.
public  FilegetAuthDirectory()
     Get this server authentication directory.
protected  StringgetBanner()
    
final public  intgetClientBufferSize()
     Get the client's buffer size.
final public  booleangetClientDebug()
     Get the client's debug flags from the properties.
final public  booleangetClientKeepConnection()
    
final public  intgetClientThreadPriority()
     Get the client's threads priority from the properties.
public  FilegetConfigDirectory()
     Get this server config directory.
public  ResourceReferencegetConfigResource()
    
final public  intgetConnectionTimeOut()
     Get the connection allowed idle time from the properties.
public  ResourceContextgetDefaultContext()
     Get the default resource context for that server.
public  StringgetDocumentationURL()
     Get the full URL of Jigsaw's documentation.
public synchronized  ResourceReferencegetEditRoot()
     Get the server's edit root resource.
public  StringgetHTMLStatus()
    
public  StringgetHost()
     Get this server host name.
public  StringgetIdentifier()
     Get this server identifier.
public  FilegetIndexerDirectory()
    
public  IndexersCataloggetIndexersCatalog()
    
public  InetAddressgetInetAddress()
    
public  intgetLocalPort()
    
public  LoggergetLogger()
     Get the logger for that server.
protected  MimeParserFactorygetMimeClientFactory(Client client)
    
public  intgetPort()
     Get this server port number.
public  ObservablePropertiesgetProperties()
     Get this server properties.
public  ResourcegetPropertySet(String name)
    
public  RealmsCataloggetRealmsCatalog()
     Get this server realm catalog.
final public  intgetRequestTimeOut()
     Get the request allowed time slice from the properties.
public  ResourceSpacegetResourceSpace()
    
public  ResourceStoreManagergetResourceStoreManager()
     Get this server resourcestore manager.
public  FramedResourcegetRoot()
     Get the server current root resource.
public  FilegetRootDirectory()
     Get this server root directory.
public  ResourceReferencegetRootReference()
    
public synchronized  ShufflergetShuffler(Client client)
     Get a shuffler for this server's client. Whenever possible, we use a shuffler program to speed up communication with the client.
public  StringgetSoftware()
     Get the server software string.
public  FilegetSpaceDir()
    
public  httpdStatisticsgetStatistics()
     Get this server statistics.
public  FilegetStoreDirectory()
     Get this server store directory.
public  FilegetTempDirectory()
    
public  StringgetTrashDirectory()
    
public  URLgetURL()
     Get the server URL.
public  voidinitialize(ServerHandlerManager shm, String identifier, ObservableProperties props)
     Initialize a new HTTP server.
protected  voidinitializeProperties()
     FIXME protected for now to handle clones Initialize some of the servers instance values from properties.
protected  voidinitializePropertySets()
    
public  booleanisLenient()
    
public  ResourceReferenceloadResource(String name)
     Lookup the root store for some resource.
Parameters:
  name - The name of the resource to lookup in the root store.
public synchronized  ResourceReferenceloadRoot(String name)
     Dynamically change the root resource for the server. This is kind a dangerous operation !
Parameters:
  name - The name of the new root resource, to be found in theroot resource store.
protected  voidloadStartupClasses()
    
public  voidlog(Client client, Request request, Reply reply, int nbytes, long duration)
     Emit a log entry.
public  voidlog(String msg)
     Emit a log message.
public static  voidmain(String args)
    
public  ReplyInterfaceperform(RequestInterface req)
     Perform the given request on behalf of this server.
Parameters:
  request - The request to perform.
public  booleanpropertyChanged(String name)
     The property monitoring implementation.
Parameters:
  name - The name of the property that has changed.
public synchronized  voidregisterPropertySet(PropertySet set)
     Register a property set to the server.
public synchronized  voidrestart()
     Restart the server properly. This methods restarts the server.
public  voidrun()
    
public synchronized  voidshutdown()
     Shutdown the server properly. This methods shutdown the server, and clean-up all its associated resources.
public  voidstart()
     start the server it will than startup, and finally run in its own thread.
public  voidstartCheckpoint()
    
public  voidtrace(Client client, String msg)
     Emit a server trace.
public  voidtrace(String msg)
     Emit a server trace, on behalf of the server itself.
public static  voidusage()
    
public  voidwarning(String msg)
     Emit a warning.
public  voidwarning(Exception e, String msg)
     Emit a warning.

Field Detail
CHECKURL_P
public static String CHECKURL_P(Code)
Name of the property indicating the URL of Jigsaw's chekpointer.



CLIENT_BUFSIZE_P
final public static String CLIENT_BUFSIZE_P(Code)
Nam eof the property giving the client output buffer size. Each clients, when not using a shuffler, has to allocate its own output buffer, Output buffer size may increase/decrease significantly the Jigsaw performances, so change it with care.

This property defaults to 8192.




CLIENT_DEBUG_P
final public static String CLIENT_DEBUG_P(Code)
Name of the property indicating wether client should be debuged. When debuged, clients emit some traces, through the server logger about their current state.

This property defaults to false.




CLIENT_FACTORY_P
final public static String CLIENT_FACTORY_P(Code)
Name of the property indicating the client factory class.



CLIENT_PRIORITY_P
final public static String CLIENT_PRIORITY_P(Code)
Name of the client thread priority property. Every client threads will run at the given priority, which should be in the range of valid threads priority.

This property defaults to Thread.NORM_PRIORITY.




CONFIG_P
final public static String CONFIG_P(Code)
Name of the property giving the server's config directory.



DEFHOSTIP_P
final public static String DEFHOSTIP_P(Code)
If the Host property is not set (see below), you can select if you want to use FQDN (broken on some jdk implementation) or just the IP address as the default host name, it usually defaults to "false" means, use FQDN.



DISPLAY_URL_ON_ERROR_P
public static String DISPLAY_URL_ON_ERROR_P(Code)
Should we show the URL that triggered an error in the error message or not? Displaying it can lead to so-called "cross-scripting" hacks



DOCURL_P
public static String DOCURL_P(Code)
Name of the property indicating the URL of Jigsaw's help. This URL should point to the URL path of Jigsaw's documentation as served by that server.



EDIT_ROOT_P
public static String EDIT_ROOT_P(Code)
Name of the property that indicates the root resource for edit. The edit root resource is the one that will show up by default when accessing the admin server from JigAdmin.



FS_SENSITIVITY
final public static String FS_SENSITIVITY(Code)
Name of the property indicating if the file-system is case sensitive. This property determines wether Jigsaw will list all files to check for case sensitivity, before creating a resource for that file.

For obvious security reasons, this property defaults to true.




HOST_P
final public static String HOST_P(Code)
Name of the server host property. The host property should be set to the name of the host running this server.

This property defaults to the local host name, although if you want directory listing to work propertly, you might need to provide the full host name (including its domain).




KEEP_ALIVE_P
final public static String KEEP_ALIVE_P(Code)
Name of the server's keep alive flag. This property is used to determine wether this server should keep its connection alive. Keeping connection alive requires this flag to set to true, and clients to be compliant to the keep alive feature as described in HTTP/1.1 specification.

This property defaults to true.




KEEP_TIMEOUT_P
final public static String KEEP_TIMEOUT_P(Code)
Name of the server's connection time out property. This property gives, in milliseconds, the timeout to use for connections that remains idel, waiting for an incoming request.

This property defaults to 10000 milliseconds.




LENIENT_P
final public static String LENIENT_P(Code)
Name of property indicating the "lenient" mode of HTTP parsing.

Property defaults to true




LOGGER_P
final public static String LOGGER_P(Code)
Name of property indicating the logger class to use. The Jigsaw server allows you to implement your own logger. The only logger provided with the core server is the org.w3c.jigsaw.core.CommonLogger, which implements the common log format.

Property defaults to org.w3c.jigsaw.core.CommonLogger




MAX_LOADED_STORE
final public static int MAX_LOADED_STORE(Code)



MAX_LOADED_STORE_P
final public static String MAX_LOADED_STORE_P(Code)
Max number of store loaded in memory.



PORT_P
final public static String PORT_P(Code)
Name of the server port property. At initializatiojn time, the server will bind its accepting socket to the host its runs on, and to the provided port.

This property defaults to 8888.




PROPS_P
final public static String PROPS_P(Code)
Name of the property giving the path of the property file. this should be used internally (for restart) only.

This property defaults to config/httpd.props.




PUBLIC_P
public static String PUBLIC_P(Code)
Name of the property indicating the public methods allowed on that server. This property should provide a | separated list of methods available on that server.

This property defaults to: GET | HEAD | PUT | POST | OPTIONS | DELETE | LINK | UNLINK | TRACE.




REQUEST_TIMEOUT_P
final public static String REQUEST_TIMEOUT_P(Code)
Name of the server's request time out property. The request time out property value indicates, in milliseconds, the allowed duration of a request. Any request whose duration exceeds this time out value will be aborted.

This property defaults to 60000.




ROOT_CLASS_P
final public static String ROOT_CLASS_P(Code)



ROOT_NAME_P
final public static String ROOT_NAME_P(Code)
Name of the property giving the name of the root resource. Upon startup, or restart, the server will look in its root store a resource whose name is given by this resource, and install it as its root resource.

This property defaults to root.




ROOT_P
final public static String ROOT_P(Code)
Name of the property giving the server root directory.

The server root directory is used to deduce a bunch of defaults properties, when they don't have any specific values.

This property has no defaults.




SERIALIZER_CLASS_P
public static String SERIALIZER_CLASS_P(Code)
Name of the serializer class used to store resources.



SERVER_GROUP_P
public static String SERVER_GROUP_P(Code)
UNIX - Name of the property that indicates the server group. When set, the server will try to turn itself to the given group name after initialization. If this fail, the server will abort.

This property has no default value.




SERVER_SOFTWARE_P
final public static String SERVER_SOFTWARE_P(Code)
Name of the server software property. The server software is the string that gets emited by Jigsaw on each reply, to tell the client what server emited the reply.

This property defaults to Jigsaw/1.0a.




SERVER_USER_P
public static String SERVER_USER_P(Code)
UNIX - Name of the property that indicates the server user. When set, the server will try to turn itself to the given user name after initialization. If this fail, the server will abort.

This property has no default value.




SHUFFLER_PATH_P
final public static String SHUFFLER_PATH_P(Code)
Name of the property giving the shuffler path. This property should be set if you are to use the shuffler. The data shuffler is an external process to whiuch Jigsaw delegates the task of writing back document content to clients. Use this when you think your server isn't fast enough.

This should be an absloute path.

This property has no defaults.




SPACE_P
final public static String SPACE_P(Code)
Name of the property giving the server space directory. The server space directory should contain an index file, built with the indexer.

This property defaults to /WWW.




STARTUP_P
public static String STARTUP_P(Code)
Name of the property indicating the startup classes to load



STORE_SIZE_LIMIT
final public static int STORE_SIZE_LIMIT(Code)



STORE_SIZE_LIMIT_P
final public static String STORE_SIZE_LIMIT_P(Code)
Max number of store loaded in memory.



TRACE_P
final public static String TRACE_P(Code)
Name of the server's trace property. When set to true, the server will emit some traces indicating its current state by using the logger trace methods. This property should be set to true if you want clients to emit traces.

This property defaults to false.




TRASHDIR_P
public static String TRASHDIR_P(Code)
Name of the property indicating the trash directory.



USE_SM_P
final public static String USE_SM_P(Code)
Name of property that indicates if some security manager is required. You usually don't want to run a security manager for the server, except in the unlikely (right now) case that you want the server to be able to host agents.

This property defaults to false.




VERSCOUNT_P
final public static String VERSCOUNT_P(Code)



debug
final public static boolean debug(Code)
debug flag



factory
ClientFactory factory(Code)



host
protected String host(Code)
FIXME check The server host name.



instances
protected int[] instances(Code)



max_loaded_store
int max_loaded_store(Code)



port
protected int port(Code)
FIXME check The server port.



props
protected ObservableProperties props(Code)
This server set of properties.



root
public FramedResource root(Code)
This server root entity.



store_size_limit
int store_size_limit(Code)



thread
public Thread thread(Code)



timer
public EventManager timer(Code)



url
protected URL url(Code)
FIXME check for clones This server URL.



verscount
final public static int verscount(Code)
The current internal version counter of Jigsaw. This counter is bumped anytime the configuration needs upgrade.



version
final public static String version(Code)
The current displayed version of Jigsaw.




Constructor Detail
httpd
public httpd()(Code)
Create a new server instance in this process.
Parameters:
  identifier - The server's identifier.
Parameters:
  props - The server properties.




Method Detail
checkFileSystemSensitivity
public boolean checkFileSystemSensitivity()(Code)
Is the underlying file-system case sensitive ? A boolean, true if file system is case sensitive, false otherwise.



checkUpgrade
protected boolean checkUpgrade(String id, ObservableProperties props)(Code)



checkpoint
public void checkpoint()(Code)
Checkpoint all cached data, by saving them to disk.



cleanTempDirectory
protected void cleanTempDirectory()(Code)
Clean the temp dir.



cleanup
protected synchronized void cleanup(boolean restart)(Code)
Cleanup the resources associated with this server context. This method should only be called by the server thread itself, when it is requested to perform the cleanup.
Parameters:
  restart - If true the server is restarted (reinitialized) straight away.



clone
public ServerHandler clone(ServerHandlerManager shm, String id, ObservableProperties props) throws ServerHandlerInitException(Code)
clone this server
exception:
  ServerHandlerInitException - if unable to be initialized.



debug
public void debug(boolean onoff)(Code)
Turn debugging on/off for this instance of httpd server.
Parameters:
  A - boolean, true turns debugging on, flase turns it off.



enumeratePropertySet
public Enumeration enumeratePropertySet()(Code)
Enumerate all the registered property sets an enumeration of PropertySet



errlog
public void errlog(Client client, String msg)(Code)
Emit a server error on behalf of some client object.
Parameters:
  client - The client.
Parameters:
  msg - The error message.



errlog
public void errlog(String msg)(Code)
Emit an error on behalf of the server.
Parameters:
  msg - The error message.



errlog
public void errlog(Object from, String msg)(Code)
The prefered form for reporting errors.
Parameters:
  from - The object that emited the error.
Parameters:
  msg - The error message.



errlog
public void errlog(Resource from, String msg)(Code)
Another nice way of reporting errors from an HTTPResource.
Parameters:
  from - The resource that trigered the error.
Parameters:
  msg - The error message.



fatal
public void fatal(Exception e, String msg)(Code)
Emit a fatal error.
Parameters:
  e - Any exception that caused the error.
Parameters:
  msg - Any additional message.



fatal
public void fatal(String msg)(Code)
Emit a fatal error.
Parameters:
  msg - Any error message



getAuthDirectory
public File getAuthDirectory()(Code)
Get this server authentication directory.



getBanner
protected String getBanner()(Code)



getClientBufferSize
final public int getClientBufferSize()(Code)
Get the client's buffer size.



getClientDebug
final public boolean getClientDebug()(Code)
Get the client's debug flags from the properties.



getClientKeepConnection
final public boolean getClientKeepConnection()(Code)
Does this server wants clients to try keeping connections alive ?



getClientThreadPriority
final public int getClientThreadPriority()(Code)
Get the client's threads priority from the properties.



getConfigDirectory
public File getConfigDirectory()(Code)
Get this server config directory.



getConfigResource
public ResourceReference getConfigResource()(Code)
get this server config resource



getConnectionTimeOut
final public int getConnectionTimeOut()(Code)
Get the connection allowed idle time from the properties.



getDefaultContext
public ResourceContext getDefaultContext()(Code)
Get the default resource context for that server.



getDocumentationURL
public String getDocumentationURL()(Code)
Get the full URL of Jigsaw's documentation. A String encoded URL.



getEditRoot
public synchronized ResourceReference getEditRoot()(Code)
Get the server's edit root resource. The edit root is the one that shows up by default when using JigAdmin It is named "root" in the interface. An HTTPResource.



getHTMLStatus
public String getHTMLStatus()(Code)
Give the status of this class as a partial HTML text which will be added into a block level element a String, the generated HTML



getHost
public String getHost()(Code)
Get this server host name.



getIdentifier
public String getIdentifier()(Code)
Get this server identifier.



getIndexerDirectory
public File getIndexerDirectory()(Code)
Get this server index directory



getIndexersCatalog
public IndexersCatalog getIndexersCatalog()(Code)
get the indexer catalog of this server



getInetAddress
public InetAddress getInetAddress()(Code)
Get the server inet address The INET address this server is listening to.



getLocalPort
public int getLocalPort()(Code)
Get the server local port



getLogger
public Logger getLogger()(Code)
Get the logger for that server. A Logger compatible instance, or null if no logger specified.



getMimeClientFactory
protected MimeParserFactory getMimeClientFactory(Client client)(Code)



getPort
public int getPort()(Code)
Get this server port number.



getProperties
public ObservableProperties getProperties()(Code)
Get this server properties.



getPropertySet
public Resource getPropertySet(String name)(Code)
Get a property set matching a specific name a Resource, the property set found



getRealmsCatalog
public RealmsCatalog getRealmsCatalog()(Code)
Get this server realm catalog.



getRequestTimeOut
final public int getRequestTimeOut()(Code)
Get the request allowed time slice from the properties.



getResourceSpace
public ResourceSpace getResourceSpace()(Code)
Get this server resource space



getResourceStoreManager
public ResourceStoreManager getResourceStoreManager()(Code)
Get this server resourcestore manager.



getRoot
public FramedResource getRoot()(Code)
Get the server current root resource.



getRootDirectory
public File getRootDirectory()(Code)
Get this server root directory.



getRootReference
public ResourceReference getRootReference()(Code)
get the resource reference of the root resource of the server



getShuffler
public synchronized Shuffler getShuffler(Client client)(Code)
Get a shuffler for this server's client. Whenever possible, we use a shuffler program to speed up communication with the client. This methods return whatever the server deems appropriate for this client shuffler. A Shuffler instance, or null.
See Also:   org.w3c.jigsaw.http.Shuffler



getSoftware
public String getSoftware()(Code)
Get the server software string.



getSpaceDir
public File getSpaceDir()(Code)
Get this server space diretory



getStatistics
public httpdStatistics getStatistics()(Code)
Get this server statistics.



getStoreDirectory
public File getStoreDirectory()(Code)
Get this server store directory.



getTempDirectory
public File getTempDirectory()(Code)
Get temp directory



getTrashDirectory
public String getTrashDirectory()(Code)
Get the tracsh directory



getURL
public URL getURL()(Code)
Get the server URL.



initialize
public void initialize(ServerHandlerManager shm, String identifier, ObservableProperties props) throws ServerHandlerInitException(Code)
Initialize a new HTTP server. The server wil first be initialized from the available properties, it will than startup, and finally run in its own thread.
Parameters:
  identifier - The string identifying this server's occurence.
Parameters:
  props - A set of properties to initialize from.
exception:
  ServerHandlerInitException - if unable to be initialized.



initializeProperties
protected void initializeProperties() throws ServerHandlerInitException(Code)
FIXME protected for now to handle clones Initialize some of the servers instance values from properties.
exception:
  ServerHandlerInitException - if unable to be initialized.



initializePropertySets
protected void initializePropertySets()(Code)



isLenient
public boolean isLenient()(Code)
Get the lenient value, tru if we are lenient in HTTP parsing



loadResource
public ResourceReference loadResource(String name)(Code)
Lookup the root store for some resource.
Parameters:
  name - The name of the resource to lookup in the root store. The loaded resource, or null.



loadRoot
public synchronized ResourceReference loadRoot(String name)(Code)
Dynamically change the root resource for the server. This is kind a dangerous operation !
Parameters:
  name - The name of the new root resource, to be found in theroot resource store. The new installed root resource, or nullif we couldn't load the given resource.



loadStartupClasses
protected void loadStartupClasses()(Code)
startup classes



log
public void log(Client client, Request request, Reply reply, int nbytes, long duration)(Code)
Emit a log entry.
Parameters:
  client - The client whose request is to be logged.
Parameters:
  request - The request that has been handled.
Parameters:
  reply - The emitted reply.
Parameters:
  nbytes - The number of bytes emitted back to the client.
Parameters:
  duration - The time it took to process the request.



log
public void log(String msg)(Code)
Emit a log message.
Parameters:
  msg - The message to log.



main
public static void main(String args)(Code)
debugging main



perform
public ReplyInterface perform(RequestInterface req) throws ProtocolException, ResourceException(Code)
Perform the given request on behalf of this server.
Parameters:
  request - The request to perform. A non-null Reply instance.
exception:
  ProtocolException - If some error occurs during processing therequest.
exception:
  ResourceException - If a resource got a fatal error.



propertyChanged
public boolean propertyChanged(String name)(Code)
The property monitoring implementation.
Parameters:
  name - The name of the property that has changed. A boolean, true if the changed was taken intoaccount, false otherwise.



registerPropertySet
public synchronized void registerPropertySet(PropertySet set)(Code)
Register a property set to the server.
Parameters:
  propSet - The property set to register.



restart
public synchronized void restart()(Code)
Restart the server properly. This methods restarts the server. It cleans-up all its associated resources, and reinitialize it from scratch. If the current thread is not the server thread, it unblocks the server thread from its accept() call, and forces it to perform the rest of the restart operation itself.
Parameters:
  reload_properties - Should we reload the properties from theproperty file, or should we just reinitialize from the current setof properties.
See Also:   httpd.cleanup



run
public void run()(Code)



shutdown
public synchronized void shutdown()(Code)
Shutdown the server properly. This methods shutdown the server, and clean-up all its associated resources. If the current thread is not the server thread, it unblocks the server thread from its accept() call, and forces it to perform the rest of the shutdown operation itself.
See Also:   httpd.cleanup



start
public void start() throws ServerHandlerInitException(Code)
start the server it will than startup, and finally run in its own thread.



startCheckpoint
public void startCheckpoint()(Code)
start the automatic checkpoint



trace
public void trace(Client client, String msg)(Code)
Emit a server trace. Traces are used solely for debugging purposes. You should either use log or error to report informations.
Parameters:
  client - The client object which wants to report the trace.
Parameters:
  msg - The trace message.
See Also:   httpd.log



trace
public void trace(String msg)(Code)
Emit a server trace, on behalf of the server itself.
Parameters:
  msg - The trace the server wants to emit.



usage
public static void usage()(Code)
this server's usage



warning
public void warning(String msg)(Code)
Emit a warning. Warnings are emited, typically if the configuration is inconsistent, and the server can continue its work.
Parameters:
  msg - The warning message.



warning
public void warning(Exception e, String msg)(Code)
Emit a warning.
Parameters:
  e - Any exception.
Parameters:
  msg - Any message.



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.