Java Doc for SyslogFormatter.java in  » Development » LogKit » org » apache » log » format » 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 » Development » LogKit » org.apache.log.format 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.apache.log.format.SyslogFormatter

SyslogFormatter
public class SyslogFormatter implements Formatter,org.apache.log.Formatter(Code)
A formatter that serializes in the format originally used by BSD syslog daemon.
author:
   Peter Donald


Field Summary
final public static  intFACILITY_AUTH
    
final public static  intFACILITY_AUTHPRIV
    
final public static  intFACILITY_CRON
    
final public static  intFACILITY_DAEMON
    
final protected static  String[]FACILITY_DESCRIPTIONS
    
final public static  intFACILITY_FTP
    
final public static  intFACILITY_KERN
    
final public static  intFACILITY_LOCAL0
    
final public static  intFACILITY_LOCAL1
    
final public static  intFACILITY_LOCAL2
    
final public static  intFACILITY_LOCAL3
    
final public static  intFACILITY_LOCAL4
    
final public static  intFACILITY_LOCAL5
    
final public static  intFACILITY_LOCAL6
    
final public static  intFACILITY_LOCAL7
    
final public static  intFACILITY_LPR
    
final public static  intFACILITY_MAIL
    
final public static  intFACILITY_NEWS
    
final public static  intFACILITY_SYSLOG
    
final public static  intFACILITY_USER
    
final public static  intFACILITY_UUCP
    
final public static  intPRIORITY_ALERT
    
final public static  intPRIORITY_CRIT
    
final public static  intPRIORITY_DEBUG
    
final public static  intPRIORITY_EMERG
    
final public static  intPRIORITY_ERR
    
final public static  intPRIORITY_INFO
    
final public static  intPRIORITY_NOTICE
    
final public static  intPRIORITY_WARNING
    

Constructor Summary
public  SyslogFormatter()
     Constructor that assumes FACILITY_USER.
public  SyslogFormatter(int facility)
     Constructor so that you can associate facility with formatter.
public  SyslogFormatter(int facility, boolean showFacilityBanner)
     Constructor allowing setting of facility and whether to show banner.

Method Summary
public  Stringformat(LogEvent event)
     Format log event into syslog string.
protected  StringgetFacilityDescription(int facility)
     Retrieve description for facility.
protected  intgetSyslogFacility(LogEvent event)
     Get facility associated with event.
protected  intgetSyslogPriority(LogEvent event)
     Get syslog priority code for LogEvent.

Field Detail
FACILITY_AUTH
final public static int FACILITY_AUTH(Code)



FACILITY_AUTHPRIV
final public static int FACILITY_AUTHPRIV(Code)



FACILITY_CRON
final public static int FACILITY_CRON(Code)



FACILITY_DAEMON
final public static int FACILITY_DAEMON(Code)



FACILITY_DESCRIPTIONS
final protected static String[] FACILITY_DESCRIPTIONS(Code)



FACILITY_FTP
final public static int FACILITY_FTP(Code)



FACILITY_KERN
final public static int FACILITY_KERN(Code)



FACILITY_LOCAL0
final public static int FACILITY_LOCAL0(Code)



FACILITY_LOCAL1
final public static int FACILITY_LOCAL1(Code)



FACILITY_LOCAL2
final public static int FACILITY_LOCAL2(Code)



FACILITY_LOCAL3
final public static int FACILITY_LOCAL3(Code)



FACILITY_LOCAL4
final public static int FACILITY_LOCAL4(Code)



FACILITY_LOCAL5
final public static int FACILITY_LOCAL5(Code)



FACILITY_LOCAL6
final public static int FACILITY_LOCAL6(Code)



FACILITY_LOCAL7
final public static int FACILITY_LOCAL7(Code)



FACILITY_LPR
final public static int FACILITY_LPR(Code)



FACILITY_MAIL
final public static int FACILITY_MAIL(Code)



FACILITY_NEWS
final public static int FACILITY_NEWS(Code)



FACILITY_SYSLOG
final public static int FACILITY_SYSLOG(Code)



FACILITY_USER
final public static int FACILITY_USER(Code)



FACILITY_UUCP
final public static int FACILITY_UUCP(Code)



PRIORITY_ALERT
final public static int PRIORITY_ALERT(Code)



PRIORITY_CRIT
final public static int PRIORITY_CRIT(Code)



PRIORITY_DEBUG
final public static int PRIORITY_DEBUG(Code)



PRIORITY_EMERG
final public static int PRIORITY_EMERG(Code)



PRIORITY_ERR
final public static int PRIORITY_ERR(Code)



PRIORITY_INFO
final public static int PRIORITY_INFO(Code)



PRIORITY_NOTICE
final public static int PRIORITY_NOTICE(Code)



PRIORITY_WARNING
final public static int PRIORITY_WARNING(Code)




Constructor Detail
SyslogFormatter
public SyslogFormatter()(Code)
Constructor that assumes FACILITY_USER.



SyslogFormatter
public SyslogFormatter(int facility)(Code)
Constructor so that you can associate facility with formatter.
Parameters:
  facility - the facility constant



SyslogFormatter
public SyslogFormatter(int facility, boolean showFacilityBanner)(Code)
Constructor allowing setting of facility and whether to show banner.
Parameters:
  facility - the facility code.
Parameters:
  showFacilityBanner - true if facility banner should be shown




Method Detail
format
public String format(LogEvent event)(Code)
Format log event into syslog string.
Parameters:
  event - the event the formatted string



getFacilityDescription
protected String getFacilityDescription(int facility)(Code)
Retrieve description for facility.
Parameters:
  facility - the facility code the facility description



getSyslogFacility
protected int getSyslogFacility(LogEvent event)(Code)
Get facility associated with event. Default implementation returns facility set in constructor.
Parameters:
  event - the log event the facility code



getSyslogPriority
protected int getSyslogPriority(LogEvent event)(Code)
Get syslog priority code for LogEvent. This is done by translating LogKit priority to syslog priority.
Parameters:
  event - the log event the priority code



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.