Skip to content

Commit

Permalink
CharType使用IOAdapter fix #1480
Browse files Browse the repository at this point in the history
  • Loading branch information
hankcs committed May 27, 2020
1 parent fd2a829 commit fee3e14
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/java/com/hankcs/hanlp/dictionary/other/CharType.java
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@

import com.hankcs.hanlp.HanLP;
import com.hankcs.hanlp.corpus.io.ByteArray;
import com.hankcs.hanlp.corpus.io.IOUtil;
import com.hankcs.hanlp.utility.TextUtility;

import java.io.DataOutputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.util.LinkedList;
import java.util.List;
Expand Down Expand Up @@ -131,7 +131,7 @@ private static ByteArray generate() throws IOException
typeList.add(array);
}
// System.out.print("int[" + typeList.size() + "][3] array = \n");
DataOutputStream out = new DataOutputStream(new FileOutputStream(HanLP.Config.CharTypePath));
DataOutputStream out = new DataOutputStream(IOUtil.newOutputStream(HanLP.Config.CharTypePath));
for (int[] array : typeList)
{
// System.out.printf("%d %d %d\n", array[0], array[1], array[2]);
Expand Down

0 comments on commit fee3e14

Please sign in to comment.