Search Results

Search found 1 results on 1 pages for 'elakkiya'.

Page 1/1 | 1 

  • how to generate the instance for logger?

    - by Elakkiya
    Here is my code package com.my; import org.apache.log4j.spi.LoggerFactory; import java.io.*; import java.util.logging.*; public class Log { public static void main(String[] args) { try{ FileHandler hand = new FileHandler("vk.log"); Logger log = Logger.getLogger("log_file"); log.addHandler(hand); log.warning("Doing carefully!"); log.info("Doing something ..."); log.severe("Doing strictily "); System.out.println(log.getName()); } catch(IOException e){ System.out.println(e) } } }

    Read the article

1