class WXFileUtils {

  public static boolean saveFile(String path, byte[] content, Context context) {
    if (TextUtils.isEmpty(path) || content == null || context == null) {
      return false;
    }
    FileOutputStream outStream = null;
    try {
      outStream = new FileOutputStream(path);
      outStream.write(content);
      return true;
    } catch (Exception e) {
      WXLogUtils.e("WXFileUtils saveFile: " + WXLogUtils.getStackTrace(e));
    } finally {
      if (outStream != null) {
        try {
          outStream.close();
        } catch (IOException e) {
          e.printStackTrace();
        }
      }
    }
    return false;
  }

}