|
Oracle Fusion Middleware Java API Reference for Oracle WebLogic Server 12c (12.1.3) Part Number E41849-02 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectweblogic.servlet.logging.FormatStringBuffer
public final class FormatStringBuffer
This class is very similar to the StringBuffer of the JDK. However since that class if final and you cannot extend it, this class exists. It is primarly written with a couple of convience methods for handling nulls and appending log format dahses (CLF and ELF use both of these as place holders in the log file for null fields. It also tries to pay attention to not generating strings, same as the StringBuffer
Constructor Summary | |
---|---|
FormatStringBuffer()
Constructs a FormatStringBuffer with the initial capacity of 128 bytes |
|
FormatStringBuffer(int capacity)
Constructs a FormatStringBuffer with the initial capacity specified by the capacity argument. |
Method Summary | |
---|---|
FormatStringBuffer |
append(byte b)
Appends the byte argument to this string buffer. |
FormatStringBuffer |
append(byte[] b)
Appends the byte[] argument to this string buffer. |
FormatStringBuffer |
append(byte[] b,
int off,
int len)
|
FormatStringBuffer |
append(char ch)
Appends the chars assuming single bytes. |
FormatStringBuffer |
append(int i)
|
FormatStringBuffer |
append(String s)
Appends the string argument to this string buffer. |
FormatStringBuffer |
appendDate()
|
FormatStringBuffer |
appendMonth(int number)
|
FormatStringBuffer |
appendQuotedValueOrDash(String value)
Appends the string argument with quotes or a dash to the string buffer. |
FormatStringBuffer |
appendSpaceDashSpace()
Appends " - " |
FormatStringBuffer |
appendStatusCode(int number)
Appends the Staus code to the string buffer. |
FormatStringBuffer |
appendTime()
|
FormatStringBuffer |
appendTwoDigits(int number)
Appends two digits to the string buffer. |
FormatStringBuffer |
appendValueOrDash(String value)
Appends the string argument or a dash if null to the string buffer. |
FormatStringBuffer |
appendValueOrEmpty(String val)
Appends the string representation of the string argument or nothing if null to this string buffer. |
FormatStringBuffer |
appendYear(int yearMinus1900)
|
byte[] |
getBytes()
|
void |
setLogMillis(boolean logMs)
|
void |
setUseGMT(boolean useGMT)
|
int |
size()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FormatStringBuffer()
public FormatStringBuffer(int capacity)
Method Detail |
---|
public void setUseGMT(boolean useGMT)
public void setLogMillis(boolean logMs)
public FormatStringBuffer append(String s)
public FormatStringBuffer append(int i)
public FormatStringBuffer append(byte b)
public FormatStringBuffer append(byte[] b)
public FormatStringBuffer append(byte[] b, int off, int len)
public FormatStringBuffer appendValueOrEmpty(String val)
public FormatStringBuffer appendTwoDigits(int number)
public FormatStringBuffer appendValueOrDash(String value)
public FormatStringBuffer append(char ch)
public FormatStringBuffer appendSpaceDashSpace()
public FormatStringBuffer appendQuotedValueOrDash(String value)
public FormatStringBuffer appendStatusCode(int number)
public byte[] getBytes()
public int size()
public FormatStringBuffer appendMonth(int number)
public FormatStringBuffer appendYear(int yearMinus1900)
public FormatStringBuffer appendDate()
public FormatStringBuffer appendTime()
|
Copyright 1996, 2014, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Oracle Fusion Middleware Java API Reference for Oracle WebLogic Server 12c (12.1.3) Part Number E41849-02 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |