src/main/java/org/michailov/async/Logger.java
private static void initialize() {
        try {
            CustomFormatter formatter = new CustomFormatter();

            FileHandler handler = new FileHandler(FILE_PATH);
            handler.setFormatter(formatter);
            
            Logger logger = new Logger();
            logger.addHandler(handler);
            logger.setLevel(Level.FINEST);
            
            _logger = logger;
            _isInitialized = true;
            
            String message = String.format("%2$s logs are located at: %1$s%2$s-*.csv", System.getProperty("java.io.tmpdir"), LOGGER_NAME);
            Logger.getGlobal().info(message);
        }
        catch (IOException ex) {
            String message = String.format("Couldn't create logger %1$s. Exception caught: %2$s\n", LOGGER_NAME, ex.toString());
            Logger.getGlobal().severe(message);
        }
    }
/**
     * Unconditionally initializes this class.
     * This method is not thread-safe. SYNC must be acquired before calling this method.
     */
Unconditionally initializes this class.
This method is not thread-safe. SYNC must be acquired before calling this method.
Unconditionally initializes this class . This method is not thread - safe . SYNC must be acquired before calling this method .
private static void initialize() {
        try {
            CustomFormatter formatter = new CustomFormatter();
            FileHandler handler = new FileHandler(FILE_PATH);
            handler.setFormatter(formatter);
            Logger logger = new Logger();
            logger.addHandler(handler);
            logger.setLevel(Level.FINEST);
            _logger = logger;
            _isInitialized = true;
            String message = String.format("%2$s logs are located at: %1$s%2$s-*.csv", System.getProperty("java.io.tmpdir"), LOGGER_NAME);
            Logger.getGlobal().info(message);
        }
        catch (IOException ex) {
            String message = String.format("Couldn't create logger %1$s. Exception caught: %2$s\n", LOGGER_NAME, ex.toString());
            Logger.getGlobal().severe(message);
        }
    }
private static void initialize ( ) { try { CustomFormatter formatter = new CustomFormatter ( ) ; FileHandler handler = new FileHandler ( FILE_PATH ) ; handler . setFormatter ( formatter ) ; Logger logger = new Logger ( ) ; logger . addHandler ( handler ) ; logger . setLevel ( Level . FINEST ) ; _logger = logger ; _isInitialized = true ; String message = String . format ( "%2$s logs are located at: %1$s%2$s-*.csv" , System . getProperty ( "java.io.tmpdir" ) , LOGGER_NAME ) ; Logger . getGlobal ( ) . info ( message ) ; } catch ( IOException ex ) { String message = String . format ( "Couldn't create logger %1$s. Exception caught: %2$s\n" , LOGGER_NAME , ex . toString ( ) ) ; Logger . getGlobal ( ) . severe ( message ) ; } }
Unconditionally initializes this class.
Unconditionally initializes this class .