zoukankan      html  css  js  c++  java
  • 日志框架的实时变化,即日起,思维详细框架(6)

    代码下一页(5)章:

    /**
    * 阅读资源信息 <特定功能叙述性说明>

    * @param filePath
    *            资源路径(包括文件名)
    * @return Properties [返回类型说明]
    * @see [类、类#方法、类#成员]
    */
    private Properties readProperties(String filePath) {
    Properties props = new Properties();
    InputStream in = null;
    try {
    in = new BufferedInputStream(new FileInputStream(filePath));
    props.load(in);
    } catch (FileNotFoundException e) {
    LOG.error(e.getMessage() + "The config file {0} is not exit");
    } catch (IOException e) {
    LOG.error(e.getMessage() + "Read config file {0} error");
    } finally {
    if (null != in) {
    try {
    in.close();
    } catch (IOException e) {
    LOG.error(e.getMessage()
    + "Close inputStream of file {0} error ");
    }
    }
    }
    return props;
    }
    }

    版权声明:本文博主原创文章,博客,未经同意不得转载。

  • 相关阅读:
    java积累
    J2SE J2EE J2ME的区别
    php无刷新上传图片
    C++小例子
    交通银行万事达Y-POWER信用卡 普卡
    代码面试最常用的5大算法
    php 读取 word
    PHP Simple HTML DOM 使用
    curl http认证
    PHP PDO 安装使用
  • 原文地址:https://www.cnblogs.com/hrhguanli/p/4872928.html
Copyright © 2011-2022 走看看