I am interested in making a data file parser. It should be a reusable and configurable data parser. The description of the data format and some rules on how to parse would be in a configuration file (maybe a .xml file). The input file to be parsed is a plain text file and the output file will be a .csv file. So every time I want to parse a file I would only write some data description file and/or mapping file, without the need to change the parsing logic. Do you know some parsers that can do what I want?
我对制作数据文件解析器感兴趣。它应该是可重用且可配置的数据解析器。数据格式的描述和关于如何解析的一些规则将在配置文件(可能是.xml文件)中。要解析的输入文件是纯文本文件,输出文件是.csv文件。因此,每次我想解析文件时,我只会编写一些数据描述文件和/或映射文件,而无需更改解析逻辑。你知道一些可以做我想做的解析器吗?
2 个解决方案
#2
0
If your "data files" are binary files, you might be interested in things like http://harmony.apache.org/subcomponents/classlibrary/asn1_framework.html or http://sourceforge.net/projects/jac-asn1/
如果您的“数据文件”是二进制文件,您可能会对http://harmony.apache.org/subcomponents/classlibrary/asn1_framework.html或http://sourceforge.net/projects/jac-asn1/等内容感兴趣。
#1
#2
0
If your "data files" are binary files, you might be interested in things like http://harmony.apache.org/subcomponents/classlibrary/asn1_framework.html or http://sourceforge.net/projects/jac-asn1/
如果您的“数据文件”是二进制文件,您可能会对http://harmony.apache.org/subcomponents/classlibrary/asn1_framework.html或http://sourceforge.net/projects/jac-asn1/等内容感兴趣。