Java 类org.apache.logging.log4j.core.layout.LoggerFields 实例源码

项目:log4j-configuration-builder    文件:ConfigurationBuilder.java   
/**
 * Creates an instance of {@link SyslogAppender}. Parameters
 * match that of appearing in the same method in
 * {@link SyslogAppender}.
 * 
 * @param name
 * @param host
 * @param port
 * @param protocolStr
 * @param appName
 * @param config
 * @param facilityName
 * @param enterpriseNumber
 * @param clientHostName
 * @return an instance of {@link SyslogAppender}
 */
protected static SyslogAppender createSyslogAppender(String name, String host, int port,
    String protocolStr, String appName, Configuration config, String facilityName,
    int enterpriseNumber, String clientHostName) {
  final SslConfiguration sslConfig = null;
  int connectTimeoutMillis = 0;
  int reconnectionDelayMillis = 0;
  boolean immediateFail = true;
  boolean immediateFlush = true;
  boolean ignoreExceptions = true;
  Facility facility = Facility.toFacility(facilityName, Facility.USER);
  String id = null;
  boolean includeMdc = false;
  String mdcId = "mdc-ignored-id";
  String mdcPrefix = null;
  String eventPrefix = "|/" + clientHostName + "/" + appName + ".log|";
  boolean newLine = true;
  String escapeNL = null;
  String msgId = appName;
  String mdcExcludes = null;
  String mdcIncludes = null;
  String mdcRequired = null;
  String format = "RFC5424";
  Filter filter = null;
  Charset charsetName = Charset.defaultCharset();
  String exceptionPattern = null;
  LoggerFields[] loggerFields = new LoggerFields[0];
  boolean advertise = false;
  SyslogAppender sla = SyslogAppender.createAppender(host, port, protocolStr, sslConfig,
      connectTimeoutMillis, reconnectionDelayMillis, immediateFail, name, immediateFlush,
      ignoreExceptions, facility, id, enterpriseNumber, includeMdc, mdcId, mdcPrefix, eventPrefix,
      newLine, escapeNL, appName, msgId, mdcExcludes, mdcIncludes, mdcRequired, format, filter,
      config, charsetName, exceptionPattern, loggerFields, advertise);
  return sla;
}
项目:logging-log4j2    文件:SyslogAppender.java   
public LoggerFields[] getLoggerFields() {
    return loggerFields;
}
项目:logging-log4j2    文件:SyslogAppender.java   
public B setLoggerFields(final LoggerFields[] loggerFields) {
    this.loggerFields = loggerFields;
    return asBuilder();
}