|
Log4j 1.3alpha-8 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.log4j.spi.ComponentBase | +--org.apache.log4j.Layout | +--org.apache.log4j.HTMLLayout
HTMLLayout outputs events in an HTML table. The content of the table columns
are specified using a conversion pattern. See
PatternLayout
for documentation on the available
patterns.
Field Summary | |
protected int |
BUF_SIZE
|
static String |
LOCATION_INFO_OPTION
Deprecated. Options are now handled using the JavaBeans paradigm. This constant is not longer needed and will be removed in the near term. |
protected int |
MAX_CAPACITY
|
static String |
TITLE_OPTION
Deprecated. Options are now handled using the JavaBeans paradigm. This constant is not longer needed and will be removed in the near term. |
Fields inherited from class org.apache.log4j.Layout |
ignoresThrowable, LINE_SEP, LINE_SEP_LEN |
Fields inherited from class org.apache.log4j.spi.ComponentBase |
repository |
Constructor Summary | |
HTMLLayout()
Constructs a PatternLayout using the DEFAULT_LAYOUT_PATTERN. |
|
HTMLLayout(String pattern)
Constructs a PatternLayout using the supplied conversion pattern. |
Method Summary | |
void |
activateOptions()
Does not do anything as options become effective |
String |
format(LoggingEvent event)
{@inheritDoc} |
String |
getContentType()
Returns the content type output by this layout, i.e "text/html". |
String |
getConversionPattern()
Returns the value of the ConversionPattern option. |
String |
getFooter()
Returns the appropriate HTML footers. |
String |
getHeader()
Returns appropriate HTML headers. |
boolean |
getLocationInfo()
Returns the current value of the LocationInfo option. |
String |
getTitle()
Returns the current value of the Title option. |
String |
getURL2ExternalCSS()
Return the URL to the external CSS file. |
boolean |
ignoresThrowable()
The HTML layout handles the throwable contained in logging events. |
boolean |
isInternalCSS()
Returns the value of the internalCSS option. |
void |
setConversionPattern(String conversionPattern)
Set the ConversionPattern option. |
void |
setInternalCSS(boolean internalCSS)
Set the value of the internalCSS option. |
void |
setLocationInfo(boolean flag)
The LocationInfo option takes a boolean value. |
void |
setTitle(String title)
The Title option takes a String value. |
void |
setURL2ExternalCSS(String url2ExternalCSS)
Set the URL for the external CSS file. |
Methods inherited from class org.apache.log4j.Layout |
setFooter, setHeader, setIgnoresThrowable |
Methods inherited from class org.apache.log4j.spi.ComponentBase |
getLogger, getLoggerRepository, getNonFloodingLogger, resetErrorCount, setLoggerRepository |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final String LOCATION_INFO_OPTION
Note that all option keys are case sensitive.
public static final String TITLE_OPTION
protected final int BUF_SIZE
protected final int MAX_CAPACITY
Constructor Detail |
public HTMLLayout()
public HTMLLayout(String pattern)
Method Detail |
public void setLocationInfo(boolean flag)
If you are embedding this layout within an SMTPAppender
then make sure to set the
LocationInfo option of that appender as well.
public boolean getLocationInfo()
public void setConversionPattern(String conversionPattern)
public String getConversionPattern()
public void activateOptions()
public void setTitle(String title)
Defaults to 'Log4J Log Messages'.
public String getTitle()
public boolean isInternalCSS()
setInternalCSS(boolean)
method for details about the meaning of this option.public void setInternalCSS(boolean internalCSS)
By default, internalCSS
value is set to false, that is,
by default, only a link to an external CSS file will be generated.
internalCSS
- setURL2ExternalCSS(java.lang.String)
public String getURL2ExternalCSS()
setURL2ExternalCSS(java.lang.String)
method for details about the meaning of this option.public void setURL2ExternalCSS(String url2ExternalCSS)
public String getContentType()
getContentType
in class Layout
public String getHeader()
getHeader
in class Layout
public String getFooter()
getFooter
in class Layout
public boolean ignoresThrowable()
false
.ignoresThrowable
in class Layout
public String format(LoggingEvent event)
format
in class Layout
|
Log4j 1.3alpha-8 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |