Extend this abstract class to create your own log layout format. More...
Inherits log4cxx::spi::OptionHandler, and log4cxx::helpers::ObjectImpl.
Inherited by DateLayout, HTMLLayout, PatternLayout, SimpleLayout, and XMLLayout.
Classes | |
| class | ClazzLayout |
Public Member Functions | |
| virtual const helpers::Class & | getClass () const |
| const void * | cast (const helpers::Class &clazz) const |
| bool | instanceof (const helpers::Class &clazz) const |
| virtual | ~Layout () |
| void | addRef () const |
| void | releaseRef () const |
| virtual void | format (LogString &output, const spi::LoggingEventPtr &event, log4cxx::helpers::Pool &pool) const =0 |
| Implement this method to create your own layout format. | |
| virtual LogString | getContentType () const |
| Returns the content type output by this layout. | |
| virtual void | appendHeader (LogString &output, log4cxx::helpers::Pool &p) |
| Append the header for the layout format. | |
| virtual void | appendFooter (LogString &output, log4cxx::helpers::Pool &p) |
| Append the footer for the layout format. | |
| virtual bool | ignoresThrowable () const =0 |
If the layout handles the throwable object contained within LoggingEvent, then the layout should return false. | |
Static Public Member Functions | |
| static const helpers::Class & | getStaticClass () |
| static const log4cxx::helpers::ClassRegistration & | registerClass () |
Extend this abstract class to create your own log layout format.
| virtual ~Layout | ( | ) | [virtual] |
| void addRef | ( | ) | const [virtual] |
Reimplemented from ObjectImpl.
| virtual void appendFooter | ( | LogString & | output, | |
| log4cxx::helpers::Pool & | p | |||
| ) | [virtual] |
| virtual void appendHeader | ( | LogString & | output, | |
| log4cxx::helpers::Pool & | p | |||
| ) | [virtual] |
| const void* cast | ( | const helpers::Class & | clazz | ) | const [inline, virtual] |
Implements Object.
Reimplemented in HTMLLayout, PatternLayout, SimpleLayout, TTCCLayout, and XMLLayout.
| virtual void format | ( | LogString & | output, | |
| const spi::LoggingEventPtr & | event, | |||
| log4cxx::helpers::Pool & | pool | |||
| ) | const [pure virtual] |
Implement this method to create your own layout format.
Implemented in HTMLLayout, PatternLayout, SimpleLayout, TTCCLayout, and XMLLayout.
| virtual const helpers::Class& getClass | ( | ) | const [virtual] |
Reimplemented from OptionHandler.
Reimplemented in HTMLLayout, PatternLayout, SimpleLayout, TTCCLayout, and XMLLayout.
| virtual LogString getContentType | ( | ) | const [virtual] |
Returns the content type output by this layout.
The base class returns "text/plain".
Reimplemented in HTMLLayout.
| static const helpers::Class& getStaticClass | ( | ) | [static] |
Reimplemented from OptionHandler.
Reimplemented in HTMLLayout, PatternLayout, SimpleLayout, TTCCLayout, and XMLLayout.
| virtual bool ignoresThrowable | ( | ) | const [pure virtual] |
If the layout handles the throwable object contained within LoggingEvent, then the layout should return false.
Otherwise, if the layout ignores throwable object, then the layout should return true.
The SimpleLayout, TTCCLayout, PatternLayout all return true. The XMLLayout returns false.
Implemented in HTMLLayout, PatternLayout, SimpleLayout, TTCCLayout, and XMLLayout.
| bool instanceof | ( | const helpers::Class & | clazz | ) | const [inline, virtual] |
Implements Object.
Reimplemented in HTMLLayout, PatternLayout, SimpleLayout, TTCCLayout, and XMLLayout.
| static const log4cxx::helpers::ClassRegistration& registerClass | ( | ) | [static] |
Reimplemented from OptionHandler.
Reimplemented in HTMLLayout, PatternLayout, SimpleLayout, TTCCLayout, and XMLLayout.
| void releaseRef | ( | ) | const [virtual] |
Reimplemented from ObjectImpl.