|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.restlet.service.Service
org.restlet.service.LogService
public class LogService
Service providing access logging service. The implementation is fully based
on the standard logging mechanism introduced in JDK 1.4.
The default access log format follows the W3C Extended Log File Format
with the following fields used:
Template
.
Constructor Summary | |
---|---|
LogService()
Constructor. |
|
LogService(boolean enabled)
Constructor. |
Method Summary | |
---|---|
Filter |
createInboundFilter(Context context)
Create the filter that should be invoked for incoming calls. |
String |
getLogFormat()
Returns the format used. |
String |
getLoggerName()
Returns the name of the JDK's logger to use when logging access calls. |
Reference |
getLogPropertiesRef()
Returns the URI reference of the log properties. |
boolean |
isIdentityCheck()
Indicates if the identity check (as specified by RFC1413) is enabled. |
void |
setIdentityCheck(boolean identityCheck)
Indicates if the identity check (as specified by RFC1413) is enabled. |
void |
setLogFormat(String format)
Sets the format to use when logging calls. |
void |
setLoggerName(String name)
Sets the name of the JDK's logger to use when logging access calls. |
void |
setLogPropertiesRef(Reference logPropertiesRef)
Sets the URI reference of the log properties. |
void |
setLogPropertiesRef(String logPropertiesUri)
Sets the URI reference of the log properties. |
void |
start()
Starts the log service by attempting to read the log properties if the getLogPropertiesRef() returns a non null URI reference. |
Methods inherited from class org.restlet.service.Service |
---|
createOutboundFilter, getContext, isEnabled, isStarted, isStopped, setContext, setEnabled, stop |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LogService()
public LogService(boolean enabled)
enabled
- True if the service has been enabled.Method Detail |
---|
public Filter createInboundFilter(Context context)
Service
createInboundFilter
in class Service
context
- The current context.
public String getLogFormat()
for format syntax and variables.
public String getLoggerName()
public Reference getLogPropertiesRef()
public boolean isIdentityCheck()
public void setIdentityCheck(boolean identityCheck)
identityCheck
- True if the identity check is enabled.public void setLogFormat(String format)
format
- The format to use when loggin calls.for format syntax and variables.
public void setLoggerName(String name)
name
- The name of the JDK's logger to use when logging access calls.public void setLogPropertiesRef(Reference logPropertiesRef)
logPropertiesRef
- The URI reference of the log properties.public void setLogPropertiesRef(String logPropertiesUri)
logPropertiesUri
- The URI reference of the log properties.public void start() throws Exception
getLogPropertiesRef()
returns a non null URI reference.
start
in class Service
Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |