package com.chenyang.nse.bussiness.tools.io;

import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.Properties;

public class PropertiesTool {
   public static String getPropertiesValueByKey(String fileNamePath, String key) {
      Properties props = new Properties();
      InputStream in = null;

      String var5;
      try {
         in = new FileInputStream(fileNamePath);
         props.load(in);
         String value = props.getProperty(key);
         var5 = value;
         return var5;
      } catch (IOException e) {
         e.printStackTrace();
         var5 = null;
      } finally {
         if (null != in) {
            try {
               in.close();
            } catch (IOException e) {
               e.printStackTrace();
            }
         }

      }

      return var5;
   }
}
