Tabnine Logo
LoggingRule.with
Code IndexAdd Tabnine to your IDE (free)

How to use
with
method
in
net.digitalid.utility.logging.filter.LoggingRule

Best Java code snippets using net.digitalid.utility.logging.filter.LoggingRule.with (Showing top 3 results out of 315)

origin: net.digitalid.utility/utility-testing

/**
 * Initializes the logging filter.
 */
@PureWithSideEffects
@Initialize(target = LoggingFilter.class)
public static void initializeLoggingFilter() {
  final @Nonnull @Absolute File projectDirectory = new File("").getAbsoluteFile();
  final @Nonnull String callerPrefix = "net.digitalid." + projectDirectory.getParentFile().getName() + "." + projectDirectory.getName();
  LoggingFilter.filter.set(ConfigurationBasedLoggingFilter.with(Files.relativeToWorkingDirectory("config/TestingLogging.conf"), LoggingRule.with(Level.VERBOSE, callerPrefix + "."), LoggingRule.with(Level.INFORMATION)));
}

origin: net.digitalid.utility/utility-processing

/**
 * Initializes the output file of the logger with the given name.
 */
@Impure
public static void initialize(@Nonnull String name) throws IllegalArgumentException, FileNotFoundException {
  Caller.index.set(6);
  Version.string.set("0.7");
  LoggingFilter.filter.set(ConfigurationBasedLoggingFilter.with(Files.relativeToWorkingDirectory("config/" + name + ".conf"), LoggingRule.with(Level.INFORMATION)));
  Logger.logger.set(FileLogger.with(Files.relativeToWorkingDirectory("target/processor-logs/" + name + ".log")));
}

origin: net.digitalid.utility/utility-initializer

/**
 * Initializes the logging filter with a configuration-based logging filter.
 * 
 * @throws IllegalArgumentException if a rule has an invalid level.
 */
@PureWithSideEffects
@Initialize(target = LoggingFilter.class, dependencies = Files.class)
public static void initializeLoggingFilter() throws IllegalArgumentException {
  if (LoggingFilter.filter.get() instanceof LevelBasedLoggingFilter) {
    LoggingFilter.filter.set(ConfigurationBasedLoggingFilter.with(Files.relativeToConfigurationDirectory("configs/logging.conf"), LoggingRule.with(Level.INFORMATION)));
    Log.verbose("Replaced the default level-based logging filter with a configuration-based logging filter.");
  } else {
    Log.verbose("Did not replace the non-default logging filter with a configuration-based logging filter.");
  }
}

net.digitalid.utility.logging.filterLoggingRulewith

Javadoc

Returns a logging rule with the given threshold.

Popular methods of LoggingRule

  • <init>
  • accepts
    Returns whether this rule accepts the given message with the given arguments.
  • getNonEmpty
    Returns the token with the given index or null if the array is not long enough or the token is empty
  • getThreshold
    Returns the threshold at and above which messages are accepted.

Popular in Java

  • Making http post requests using okhttp
  • getSharedPreferences (Context)
  • getSystemService (Context)
  • setRequestProperty (URLConnection)
  • TimerTask (java.util)
    The TimerTask class represents a task to run at a specified time. The task may be run once or repeat
  • ConcurrentHashMap (java.util.concurrent)
    A plug-in replacement for JDK1.5 java.util.concurrent.ConcurrentHashMap. This version is based on or
  • Handler (java.util.logging)
    A Handler object accepts a logging request and exports the desired messages to a target, for example
  • ServletException (javax.servlet)
    Defines a general exception a servlet can throw when it encounters difficulty.
  • Runner (org.openjdk.jmh.runner)
  • Option (scala)
  • Top Sublime Text plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now