WO2018028127A1 - 存储文件的解析方法和装置 - Google Patents

存储文件的解析方法和装置 Download PDF

Info

Publication number
WO2018028127A1
WO2018028127A1 PCT/CN2016/113344 CN2016113344W WO2018028127A1 WO 2018028127 A1 WO2018028127 A1 WO 2018028127A1 CN 2016113344 W CN2016113344 W CN 2016113344W WO 2018028127 A1 WO2018028127 A1 WO 2018028127A1
Authority
WO
WIPO (PCT)
Prior art keywords
parsing
storage file
logic
data structure
format data
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Ceased
Application number
PCT/CN2016/113344
Other languages
English (en)
French (fr)
Inventor
陈民敬
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangzhou Shirui Electronics Co Ltd
Original Assignee
Guangzhou Shirui Electronics Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangzhou Shirui Electronics Co Ltd filed Critical Guangzhou Shirui Electronics Co Ltd
Publication of WO2018028127A1 publication Critical patent/WO2018028127A1/zh
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/11File system administration, e.g. details of archiving or snapshots
    • G06F16/116Details of conversion of file system types or formats
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/13File access structures, e.g. distributed indices

Definitions

  • the present invention relates to the field of computer technologies, and in particular, to a method and an apparatus for analyzing a stored file.
  • the parsing logic a when the content of the xml file is displayed on the UI of the interactive whiteboard, the parsing logic a is used to parse the xml file into a memory model, and after adding a json type file to the storage file, the json file is added.
  • the parsing logic a needs to be modified to parse the parsing logic b of the xml file and the json file, and then the json file is parsed into a memory model.
  • the parsing logic c when parsing the storage file into the memory model A, the parsing logic c is used, but after adding a memory model B to the memory model to implement the new function, the parsing logic c needs to be modified to make part
  • the storage file can be parsed into memory model A, while another portion of the storage file can be parsed into memory model B. Therefore, the existing technical solutions lead to poor compatibility of software on the interactive electronic whiteboard, and the process of implementing format compatibility is complicated and difficult.
  • the invention provides a method and a device for parsing a storage file, which can improve the compatibility of the device with the file format, and make the process of implementing the file format compatible easy and simple.
  • the method for parsing a storage file specifically includes:
  • Reading a storage file where the storage file includes a parsing logical identification code corresponding to a format of the storage file;
  • parsing the storage file into an intermediate format data structure according to the parsing logic corresponding to the parsing logic identification code, which includes:
  • the storage file is parsed into the intermediate format data structure according to the parsing logic.
  • parsing logic includes a first parsing logic and a second parsing logic
  • the parsing the storage file into the intermediate format data structure according to the parsing logic, specifically:
  • a format parser corresponding to the format of the storage file, to parse the storage file into a corresponding format data structure
  • the converting the intermediate format data structure into a memory storage file according to the conversion logic that is commonly associated with the element identification code, which includes:
  • the method further includes:
  • the present invention further provides a device for analyzing a file, which specifically includes:
  • a storage file reading module configured to read a storage file, where the storage file includes a parsing logical identification code corresponding to a format of the storage file;
  • a storage file parsing module configured to parse the storage file into an intermediate format data structure according to a parsing logic corresponding to the parsing logic identifier, where the intermediate format data structure includes the storage The element identifier corresponding to each content element in the file;
  • An intermediate format data structure conversion module configured to convert the intermediate format data structure into a memory storage file according to a conversion logic that is preset corresponding to the element identification code; wherein the memory storage file is the storage The mapping of files in memory.
  • the storing file parsing module specifically includes:
  • a parsing logic acquiring unit configured to acquire, according to the parsing logic identifier, the parsing logic corresponding to the parsing logic identifier from a preset parsing manager;
  • a file parsing unit configured to parse the storage file into the intermediate format data structure according to the parsing logic.
  • parsing logic includes a first parsing logic and a second parsing logic
  • the file parsing unit specifically includes:
  • a first parsing subunit configured to, according to the first parsing logic, invoke a format parser corresponding to a format of the storage file to parse the storage file into a corresponding format data structure;
  • a second parsing subunit configured to modify a node reference relationship of the format data structure according to the second parsing logic, and parse the format data structure into the intermediate format data structure.
  • the intermediate format data structure conversion module specifically includes:
  • a conversion logic acquiring unit configured to acquire, according to the element identification code, a conversion logic that is common to the element identification code from a preset conversion manager;
  • a format conversion unit configured to recurse the intermediate format data structure according to the conversion logic, and convert the intermediate format data structure into the memory storage file.
  • the parsing device for storing the file further includes:
  • a rendering display module is configured to render each content element in the memory storage file to a display in a display.
  • the method and apparatus for parsing a storage file parses a storage file into an intermediate format data structure according to parsing logic corresponding to a format of the storage file, and according to a content element corresponding to the intermediate format data structure
  • the conversion logic converts the intermediate format data structure into an in-memory storage file, so that the format change of the storage file is isolated from the change of the content of the storage file, that is, the parsing process can parse the storage file of a plurality of different formats, and Regardless of what content elements are included in the storage file, a plurality of intermediate format data structures containing different content elements can be converted during the conversion process regardless of the format of the corresponding storage file.
  • the parsing method of the storage file provided by the embodiment of the present invention can improve the compatibility of the device with the file format.
  • the parsing method of the storage file can improve the compatibility of the device with the file format.
  • only new parsing logic needs to be added when the format of the storage file changes, when the content element of the storage file changes, only new conversion logic needs to be added, so the process of implementing format compatibility is easy and simple.
  • FIG. 1 is a schematic flow chart of an embodiment of a method for parsing a storage file provided by the present invention
  • FIG. 2 is a schematic diagram of an intermediate format corresponding to an integer X attribute of an embodiment of a method for parsing a storage file provided by the present invention
  • FIG. 3 is a schematic diagram of an intermediate format corresponding to a coordinate point Point attribute of an embodiment of a method for parsing a storage file provided by the present invention
  • FIG. 4 is a schematic diagram of an intermediate format corresponding to a background of a background property of an embodiment of a method for parsing a storage file provided by the present invention
  • FIG. 5 is a schematic diagram of an intermediate format corresponding to a background property of a background of a method for parsing a storage file according to an embodiment of the present invention
  • FIG. 6 is a schematic diagram of an intermediate format corresponding to a Point attribute of a coordinate point array of an embodiment of a method for parsing a storage file provided by the present invention
  • FIG. 7 is a schematic diagram of a tree-type intermediate format data structure of an embodiment of a method for parsing a storage file provided by the present invention.
  • FIG. 8 is a schematic flowchart of a parsing process of an embodiment of a method for parsing a storage file provided by the present invention.
  • FIG. 9 is a schematic flowchart of a conversion process of an embodiment of a method for parsing a storage file provided by the present invention.
  • FIG. 10 is a schematic structural diagram of an embodiment of a device for analyzing a stored file according to the present invention.
  • FIG. 1 is a schematic flowchart diagram of an embodiment of a method for parsing a storage file provided by the present invention, including steps S11 to S13, as follows:
  • S12 Parse the storage file into an intermediate format data structure according to a parsing logic corresponding to the parsing logic identifier, where the intermediate format data structure includes each content in the storage file.
  • S13 Convert the intermediate format data structure into a memory storage file according to a conversion logic that is preset in common with the element identifier; wherein the memory storage file is a mapping of the storage file in memory.
  • the method provided by the present invention mainly consists of a parsing process and a conversion process, that is, when a storage file is parsed and converted into an in-memory storage file, the storage file is first parsed according to corresponding parsing logic. After the intermediate format data structure, the intermediate format data structure is converted into an in-memory storage file according to the corresponding conversion logic.
  • the parsing logic used in the parsing process is determined by the format of the parsed storage file.
  • the transformation logic used in the conversion process is determined by the content elements in the converted intermediate format data structure.
  • the format of the storage file may be an xml format, a json format, or an svg format.
  • the intermediate format data structure can be a tree structure or other types of data structures such as linked lists and stacks.
  • the tree-type intermediate format data structure is taken as an example to illustrate the node reference relationship in the intermediate format data structure.
  • Each node in the intermediate format data structure includes three items of Name, Value and Children, which respectively represent the name of the node, the value of the node, and the child nodes of the node.
  • the attribute represented by a node is an underlying data type such as an integer, a decimal, or a string
  • the Name of the node is the name of the attribute
  • the Value of the node is the value of the attribute
  • the Child value of the node is null.
  • the intermediate format corresponding to the attribute is shown in Figure 2.
  • the attribute represented by a node is a composite data type, that is, the attribute is a composite attribute composed of several single attributes
  • the Name of the node is the name of the attribute
  • the value of the node is null
  • the child of the node points to A node that represents each single attribute.
  • the attribute is the coordinate point Point (100, 200)
  • the attribute represented by a node may be the underlying data type or the composite data type
  • the Name of the node is the name of the attribute
  • the value of the node is null
  • the Child of the node points to the specific The node of the data type and content.
  • the type of the property may be a color or an image.
  • the intermediate format corresponding to the attribute is as shown in FIG. 4 .
  • the intermediate format corresponding to the attribute is as shown in FIG. 5.
  • the Name of the node is the name of the attribute
  • the value of the node is null
  • the Children of the node points to the node representing the attributes of each array element in the attribute.
  • the attribute is an array of Points consisting of two coordinate points Point
  • the intermediate format corresponding to the attribute is as shown in FIG. 6.
  • the computer when a certain storage file needs to be parsed and converted into an in-memory storage file, the computer reads the storage file and according to the parsing logic corresponding to the version number of the parsing logic in the storage file, that is, The parsing logic corresponding to the logical identifier is parsed, and the storage file is parsed into an intermediate format data structure. Subsequently, the computer traverses the intermediate format data structure and converts the intermediate format data structure into an in-memory storage file according to conversion logic that corresponds to the element identification code of each content element therein.
  • the memory storage file is a mapping of the storage file in memory.
  • the intermediate format data structure may be a tree structure, or may be another type of data structure such as a linked list or a stack.
  • each content element is respectively parsed into each subtree having a common parent node in the tree structure, and the root nodes of each subtree respectively correspond to The element identifier of the content element, and each child node in each subtree is the attribute of its parent node.
  • the computer reads the storage file, and obtains a corresponding parsing logic capable of parsing the file in the xml format according to the parsing logical identifier in the storage file, and according to the The parsing logic parses the storage file into an intermediate format data structure of the tree type as shown in FIG.
  • the content element ⁇ iwb:shape> and the content element ⁇ iwb:magnifier> respectively correspond to two subtrees whose common parent node is an elements node.
  • the node name in the root node of the subtree corresponding to the content element ⁇ iwb:shape> is the element identifier of the content element ⁇ iwb:shape>, that is, the iwb:shape, and the attribute of the content element ⁇ iwb:shape> is parsed as the The child or grandchild of the root node.
  • the node name in the root node of the subtree corresponding to the content element ⁇ iwb:magnifier> is the element identifier of the content element ⁇ iwb:magnifier>, ie, iwb:magnifier, and the attribute of the content element ⁇ iwb:magnifier> is parsed as The child or grandchild of the root node.
  • the computer traverses the intermediate format data structure, and obtains a common corresponding conversion logic according to all of the element identification codes, iwb:shape and iwb:magnifier, and the conversion logic is
  • the subtree corresponding to the content element ⁇ iwb:shape> can be converted, and the subtree corresponding to the content element ⁇ iwb:magnifier> can be converted.
  • the intermediate format data structure is converted into a corresponding memory storage file, which includes a shape content element and its corresponding attribute, and a magnifier content element and its corresponding attribute.
  • the intermediate format data is parsed into an intermediate format data structure according to parsing logic corresponding to the format of the stored file, and the conversion format logic corresponding to the content element in the intermediate format data structure
  • the structure is converted into a memory storage file, so that the format change of the storage file is isolated from the change of the content of the storage file, that is, the parsing process can parse the storage file of a plurality of different formats, regardless of what is included in the storage file.
  • the content element can convert a plurality of intermediate format data structures containing different content elements during the conversion process, regardless of the format of the corresponding storage file. Therefore, the parsing method of the storage file provided by the embodiment of the present invention can improve the compatibility of the device with the file format.
  • parsing the storage file into an intermediate format data structure according to the parsing logic corresponding to the parsing logic identification code, which includes:
  • the storage file is parsed into the intermediate format data structure according to the parsing logic.
  • the parsing logic is stored and managed by the parsing manager, and each parsing logic in the parsing manager has a unique version number, that is, parsing the logical identifier. Whenever you add a new storage file format, you need to add the corresponding parsing logic in the parsing manager.
  • the computer finds the parsing logic corresponding to the parsing logical identifier in the storage file in the parsing manager and acquires the parsing logic, and parses the stored file according to the parsing logic. Is an intermediate format data structure.
  • the flow chart of the analysis process of the present embodiment is shown, and the analysis manager 81 stores the analysis logic A and the analysis logic B.
  • the parsing logic A is obtained from the parsing manager 81, and the storage file A is parsed according to the parsing logic A.
  • the parsing logic B is obtained from the parsing manager 81, and the storage file B is parsed according to the parsing logic B.
  • the analysis logic C capable of parsing the storage file C is added to the analysis manager 81.
  • parsing logic includes a first parsing logic and a second parsing logic
  • the parsing the storage file into the intermediate format data structure according to the parsing logic, specifically:
  • the parsing logic is divided into two parts, namely, a first parsing logic and a second parsing logic.
  • the first parsing logic corresponds to the format of the storage file, and is used to call a format parser corresponding to the format of the stored file, thereby parsing the storage file into a corresponding format data structure.
  • the second parsing logic is configured to recurse the format data structure, thereby traversing the format data structure and modifying the node reference relationship therein, and further parsing the format data structure into an intermediate format data structure.
  • the format data structure may be a tree structure, or may be another type of data structure such as a linked list or a stack.
  • the node reference relationships of the format data structures corresponding to the format of different storage files may be the same or different.
  • the xml format data structure is recursively, thereby traversing the xml format data structure and modifying the node reference relationship therein, and further parsing the xml format data structure into the intermediate format data structure.
  • the converting the intermediate format data structure into an in-memory storage file according to the conversion logic that is commonly associated with the element identification code, which includes:
  • the conversion logic is stored and managed by the conversion manager, and each conversion logic in the conversion manager has an element identifier of all content elements that it can convert. Whenever a content element in a storage file changes to implement a new function, the corresponding conversion logic needs to be added in the conversion manager in advance.
  • the conversion logic corresponding to the element identifier of each content element in the intermediate format data structure is found in the conversion manager and the conversion logic is obtained, and according to The conversion logic recursively transforms the intermediate format data structure to convert the intermediate format data structure into an in-memory storage file.
  • the conversion manager 92 stores conversion logic A and conversion logic B.
  • the conversion logic A can convert an intermediate format data structure including the content element a and the content element b
  • the conversion logic B can convert an intermediate format data structure including the content element a, the content element b, and the content element c.
  • the slave conversion manager 92 The conversion logic A is obtained, and the intermediate format data structure 91 is converted into a corresponding memory storage file A according to the conversion logic A, and the converted memory storage file A includes the content element a and its corresponding attribute, and the content element b. And its corresponding properties.
  • adding in the conversion manager 92 is capable of converting the middle including the content element a, the content element b, and the content element d
  • the conversion logic C of the format data structure is capable of converting the middle including the content element a, the content element b, and the content element d.
  • the method further includes:
  • the storage file is parsed and converted into an in-memory storage file
  • the content elements in the memory storage file are rendered to be displayed in the display screen.
  • a storage file includes a content element a representing an ellipse and a content element b representing a magnifying glass
  • the corresponding memory storage file includes the content element a and its corresponding attribute, and the content element b and its corresponding Attributes.
  • an ellipse and a magnifying glass are displayed on the display of the device.
  • the method for parsing a storage file parses a storage file into an intermediate format data structure according to parsing logic corresponding to a format of the storage file, and according to a content element corresponding to the intermediate format data structure
  • the conversion logic converts the intermediate format data structure into an in-memory storage file, so that the format change of the storage file is isolated from the change of the content of the storage file, that is, the parsing process can parse the storage file of a plurality of different formats, and Regardless of what content elements are included in the storage file, a plurality of intermediate format data structures containing different content elements can be converted during the conversion process regardless of the format of the corresponding storage file.
  • the parsing method of the storage file provided by the embodiment of the present invention can improve the compatibility of the device with the file format.
  • the parsing method of the storage file can improve the compatibility of the device with the file format.
  • only new parsing logic needs to be added when the format of the storage file changes, when the content element of the storage file changes, only new conversion logic needs to be added, so the process of implementing format compatibility is easy and simple.
  • the present invention also provides a device for analyzing a file, which can implement all the processes of the method for parsing a file in the above embodiment.
  • FIG. 10 is a schematic structural diagram of an embodiment of a device for analyzing a storage file provided by the present invention, which is specifically as follows:
  • a storage file reading module 01 configured to read a storage file, where the storage file includes a parsing logical identification code corresponding to a format of the storage file;
  • the storage file parsing module 02 is configured to perform, according to a preset parsing logic corresponding to the parsing logic identifier, Parsing the storage file into an intermediate format data structure; wherein the intermediate format data structure includes an element identification code respectively corresponding to each content element in the storage file;
  • the intermediate format data structure conversion module 03 is configured to convert the intermediate format data structure into a memory storage file according to a conversion logic that is preset corresponding to the element identification code; wherein the memory storage file is the Stores the mapping of files in memory.
  • the storage file parsing module 02 specifically includes:
  • a parsing logic acquiring unit configured to acquire, according to the parsing logic identifier, the parsing logic corresponding to the parsing logic identifier from a preset parsing manager;
  • a file parsing unit configured to parse the storage file into the intermediate format data structure according to the parsing logic.
  • parsing logic includes a first parsing logic and a second parsing logic
  • the file parsing unit specifically includes:
  • a first parsing subunit configured to, according to the first parsing logic, invoke a format parser corresponding to a format of the storage file to parse the storage file into a corresponding format data structure;
  • a second parsing subunit configured to modify a node reference relationship of the format data structure according to the second parsing logic, and parse the format data structure into the intermediate format data structure.
  • the intermediate format data structure conversion module 03 specifically includes:
  • a conversion logic acquiring unit configured to acquire, according to the element identification code, a conversion logic that is common to the element identification code from a preset conversion manager;
  • a format conversion unit configured to recurse the intermediate format data structure according to the conversion logic, and convert the intermediate format data structure into the memory storage file.
  • the parsing device for storing the file further includes:
  • a rendering display module is configured to render each content element in the memory storage file to a display in a display.
  • the apparatus for parsing a storage file parses the storage file into an intermediate format data structure according to parsing logic corresponding to the format of the storage file, and according to the content element corresponding to the intermediate format data structure
  • the conversion logic converts the intermediate format data structure into an in-memory storage file, so that the format change of the storage file is isolated from the change of the content of the storage file, that is, the parsing process can parse the storage file of a plurality of different formats, and Regardless of what content elements are included in the storage file, the conversion process can be used for a variety of different content elements.
  • the intermediate format data structure is converted regardless of the format of the corresponding storage file.
  • the parsing method of the storage file provided by the embodiment of the present invention can improve the compatibility of the device with the file format.
  • the parsing method of the storage file can improve the compatibility of the device with the file format.
  • only new parsing logic needs to be added when the format of the storage file changes, when the content element of the storage file changes, only new conversion logic needs to be added, so the process of implementing format compatibility is easy and simple.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Document Processing Apparatus (AREA)

Abstract

一种存储文件的解析方法和装置。所述存储文件的解析方法包括:读取存储文件;其中,所述存储文件中包括与所述存储文件的格式所对应的解析逻辑识别码(S11);根据预先设置的与所述解析逻辑识别码所对应的解析逻辑,将所述存储文件解析为中间格式数据结构;其中,所述中间格式数据结构中包括与所述存储文件中的各个内容元素分别对应的元素识别码(S12);根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转换为内存存储文件;其中,所述内存存储文件为所述存储文件在内存中的映射(S13)。该方法能够提高设备对文件格式的兼容性,且使得实现文件格式兼容的过程容易、简单。

Description

存储文件的解析方法和装置 技术领域
本发明涉及计算机技术领域,尤其涉及一种存储文件的解析方法和装置。
背景技术
在现有的技术方案中,将存储文件的内容显示到交互式电子白板的UI上,是通过将该存储文件的格式从存储格式直接解析为内存中的一种数据结构格式,即内存模型,并对内存模型进行渲染来实现的。由于现有技术中的解析过程是将文件的格式从存储格式直接解析为内存模型,因此,不管是文件的存储格式发生变化,抑或是内存模型发生变化,均需要对解析过程的实现逻辑进行修改。例如,在将xml文件的内容显示至交互式电子白板的UI上时,使用解析逻辑a将该xml文件解析为内存模型,而在存储文件中增加一种json类型的文件之后,在将json文件的内容显示至交互式电子白板的UI上时,则需要先将解析逻辑a修改为能够解析xml文件和json文件的解析逻辑b之后,再将该json文件解析为内存模型。再例如,在将存储文件解析为内存模型A时,采用的是解析逻辑c,但是在内存模型中新增一个内存模型B以实现新的功能之后,则需要对解析逻辑c进行修改以使部分存储文件能够被解析为内存模型A,同时另一部分存储文件能够被解析为内存模型B。因此,现有的技术方案导致交互式电子白板上的软件的兼容性差,实现格式兼容的过程复杂且困难。
发明内容
本发明提出一种存储文件的解析方法和装置,能够提高设备对文件格式的兼容性,且使得实现文件格式兼容的过程容易、简单。
本发明提供的一种存储文件的解析方法,具体包括:
读取存储文件;其中,所述存储文件中包括与所述存储文件的格式所对应的解析逻辑识别码;
根据预先设置的与所述解析逻辑识别码所对应的解析逻辑,将所述存储文件解析为中间格式数据结构;其中,所述中间格式数据结构中包括与所述存储文件中的各个内容元素分别对应的元素识别码;
根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转 换为内存存储文件;其中,所述内存存储文件为所述存储文件在内存中的映射。
进一步地,所述根据预先设置的与所述解析逻辑识别码所对应的解析逻辑,将所述存储文件解析为中间格式数据结构,具体包括:
根据所述解析逻辑识别码,从预先设置的解析管理器中获取所述解析逻辑识别码所对应的所述解析逻辑;
根据所述解析逻辑,将所述存储文件解析为所述中间格式数据结构。
进一步地,所述解析逻辑中包括第一解析逻辑和第二解析逻辑;
所述根据所述解析逻辑,将所述存储文件解析为所述中间格式数据结构,具体包括:
根据所述第一解析逻辑,调用与所述存储文件的格式所对应的格式解析器,将所述存储文件解析为相应的格式数据结构;
根据所述第二解析逻辑,对所述格式数据结构的节点引用关系进行修改,将所述格式数据结构解析为所述中间格式数据结构。
进一步地,所述根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转换为内存存储文件,具体包括:
根据所述元素识别码,从预先设置的转换管理器中获取所述元素识别码所共同对应的转换逻辑;
根据所述转换逻辑,对所述中间格式数据结构进行递归,将所述中间格式数据结构转换为所述内存存储文件。
进一步地,在所述根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转换为内存存储文件之后,还包括:
将所述内存存储文件中的各个内容元素渲染至显示屏中显示。
相应地,本发明还提供了一种存储文件的解析装置,具体包括:
存储文件读取模块,用于读取存储文件;其中,所述存储文件中包括与所述存储文件的格式所对应的解析逻辑识别码;
存储文件解析模块,用于根据预先设置的与所述解析逻辑识别码所对应的解析逻辑,将所述存储文件解析为中间格式数据结构;其中,所述中间格式数据结构中包括与所述存储文件中的各个内容元素分别对应的元素识别码;以及,
中间格式数据结构转换模块,用于根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转换为内存存储文件;其中,所述内存存储文件为所述存储文件在内存中的映射。
进一步地,所述存储文件解析模块,具体包括:
解析逻辑获取单元,用于根据所述解析逻辑识别码,从预先设置的解析管理器中获取所述解析逻辑识别码所对应的所述解析逻辑;以及,
文件解析单元,用于根据所述解析逻辑,将所述存储文件解析为所述中间格式数据结构。
进一步地,所述解析逻辑中包括第一解析逻辑和第二解析逻辑;
所述文件解析单元,具体包括:
第一解析子单元,用于根据所述第一解析逻辑,调用与所述存储文件的格式所对应的格式解析器,将所述存储文件解析为相应的格式数据结构;以及,
第二解析子单元,用于根据所述第二解析逻辑,对所述格式数据结构的节点引用关系进行修改,将所述格式数据结构解析为所述中间格式数据结构。
进一步地,所述中间格式数据结构转换模块,具体包括:
转换逻辑获取单元,用于根据所述元素识别码,从预先设置的转换管理器中获取所述元素识别码所共同对应的转换逻辑;以及,
格式转换单元,用于根据所述转换逻辑,对所述中间格式数据结构进行递归,将所述中间格式数据结构转换为所述内存存储文件。
进一步地,所述存储文件的解析装置,还包括:
渲染显示模块,用于将所述内存存储文件中的各个内容元素渲染至显示屏中显示。
实施本发明,具有如下有益效果:
本发明提供的存储文件的解析方法及装置,通过根据与存储文件的格式相对应的解析逻辑,将存储文件解析为中间格式数据结构,并且根据与该中间格式数据结构中的内容元素相对应的转换逻辑,将该中间格式数据结构转换为内存存储文件,从而使得存储文件的格式的变化与存储文件的内容的变化相互隔离,即在解析过程能够对多种不同格式的存储文件进行解析,而不管该存储文件中包括何种内容元素,在转换过程能够对多种包含不同内容元素的中间格式数据结构进行转换,而不管相对应的存储文件为何种格式。因此,本发明实施例提供的存储文件的解析方法能够提高设备对文件格式的兼容性。同时,由于当存储文件的格式发生变化时只需添加新的解析逻辑,当存储文件的内容元素发生变化时只需添加新的转换逻辑,因此实现格式兼容的过程容易、简单。
附图说明
图1是本发明提供的存储文件的解析方法的一个实施例的流程示意图;
图2是本发明提供的存储文件的解析方法的一个实施例的整数X属性所对应的中间格式的示意图;
图3是本发明提供的存储文件的解析方法的一个实施例的坐标点Point属性所对应的中间格式的示意图;
图4是本发明提供的存储文件的解析方法的一个实施例的背景Background属性的类型为颜色时所对应的中间格式的示意图;
图5是本发明提供的存储文件的解析方法的一个实施例的背景Background属性的类型为图片时所对应的中间格式的示意图;
图6是本发明提供的存储文件的解析方法的一个实施例的坐标点数组Points属性所对应的中间格式的示意图;
图7是本发明提供的存储文件的解析方法的一个实施例的树型的中间格式数据结构的示意图;
图8是本发明提供的存储文件的解析方法的一个实施例的解析过程的流程示意图;
图9是本发明提供的存储文件的解析方法的一个实施例的转换过程的流程示意图;
图10是本发明提供的存储文件的解析装置的一个实施例的结构示意图。
具体实施方式
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。
参见图1,是本发明提供的存储文件的解析方法的一个实施例的流程示意图,包括步骤S11至S13,具体如下:
S11:读取存储文件;其中,所述存储文件中包括与所述存储文件的格式所对应的解析逻辑识别码;
S12:根据预先设置的与所述解析逻辑识别码所对应的解析逻辑,将所述存储文件解析为中间格式数据结构;其中,所述中间格式数据结构中包括与所述存储文件中的各个内容元素分别对应的元素识别码;
S13:根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转换为内存存储文件;其中,所述内存存储文件为所述存储文件在内存中的映射。
需要说明的是,本发明所提供的方法主要由解析过程和转换过程组成,即在将某一存储文件解析并转换为内存存储文件时,先根据相应的解析逻辑将该存储文件解析为对应的中间格式数据结构后,再根据相应的转换逻辑将该中间格式数据结构转换为内存存储文件。解析过程所采用的解析逻辑由所解析的存储文件的格式决定。转换过程所采用的转换逻辑由所转换的中间格式数据结构中的内容元素共同决定。
需要进一步说明的是,存储文件的格式可以为xml格式、json格式或者svg格式等。中间格式数据结构可以为树型结构,也可以为链表、堆栈等其他类型的数据结构。
以树型的中间格式数据结构为例说明中间格式数据结构中的节点引用关系。该中间格式数据结构中的每个节点中均包括Name,Value和Children三个项,分别表示节点的名称、节点的值和节点的子节点。
当某一节点表示的属性为整数、小数、字符串等基础数据类型时,该节点的Name值为该属性的名称,该节点的Value值为该属性的值,该节点的Children值为空。例如:当属性为X=100时,该属性所对应的中间格式如图2所示。
当某一节点表示的属性为复合数据类型,即该属性为由若干单一属性组成的复合属性时,该节点的Name值为该属性的名称,该节点的Value值为空,该节点的Children指向表示各个单一属性的节点。例如,当属性为坐标点Point(100,200)时,该属性由单一属性cx=100和单一属性cy=200组成,因此该属性所对应的中间格式如图3所示。
当某一节点表示的属性可能是基础数据类型,也可能是复合数据类型时,该节点的Name值为该属性的名称,该节点的Value值为空,该节点的Children指向表示该属性的具体的数据类型和内容的节点。例如,当属性为背景Background时,该属性的类型可能是颜色,也可能是图片。当该属性的类型为颜色时,该属性所对应的中间格式如图4所示。
当该属性的类型为图片时,该属性所对应的中间格式如图5所示。
当某一节点表示的属性为数组类型时,该节点的Name值为该属性的名称,该节点的Value值为空,该节点的Children指向表示该属性中的各个数组元素的属性的节点。例如,当属性为由两个坐标点Point组成的Points数组时,该属性所对应的中间格式如图6所示。
在一个优选的实施方式中,当需要将某一存储文件解析并转换为内存存储文件时,计算机读取该存储文件,并根据该存储文件中的解析逻辑的版本号所对应的解析逻辑,即解析逻辑识别码所对应的解析逻辑,将该存储文件解析为中间格式数据结构。随后,计算机遍历该中间格式数据结构,并根据其中的各个内容元素的元素识别码所共同对应的转换逻辑,将该中间格式数据结构转换为内存存储文件。内存存储文件为存储文件在内存中的映射。其中,中间格式数据结构可以为树型结构,也可以为链表、堆栈等其他类型的数据结构。当中间格 式数据结构为树型结构时,存储文件经过解析后,其中的各个内容元素分别对应解析为该树型结构中的具有共同父节点的各个子树,各个子树的根节点中包括分别对应的内容元素的元素识别码,各个子树中的各个子节点分别为其父节点的属性。
例如,假设某一xml格式的存储文件如下:
Figure PCTCN2016113344-appb-000001
其中包括内容元素<iwb:shape>和内容元素<iwb:magnifier>,分别表示一个椭圆和一个放大镜。当需要将该存储文件解析并转换为内存存储文件时,计算机读取该存储文件,并根据该存储文件中的解析逻辑识别码获得相对应的能够解析xml格式的文件的解析逻辑,并根据该解析逻辑将存储文件解析为如图7所示的树型的中间格式数据结构。
其中,内容元素<iwb:shape>和内容元素<iwb:magnifier>分别对应解析为共同父节点为elements节点的两棵子树。内容元素<iwb:shape>所对应的子树的根节点中的节点名称为内容元素<iwb:shape>的元素识别码,即iwb:shape,内容元素<iwb:shape>的属性对应解析为该根节点的子节点或者孙节点。内容元素<iwb:magnifier>所对应的子树的根节点中的节点名称为内容元素<iwb:magnifier>的元素识别码,即iwb:magnifier,内容元素<iwb:magnifier>的属性对应解析为该根节点的子节点或者孙节点。
在将该中间格式数据结构转换为内存存储文件时,计算机遍历该中间格式数据结构,根据其中的所有的元素识别码,即iwb:shape和iwb:magnifier获得共同对应的转换逻辑,该转换逻辑既能够转换内容元素<iwb:shape>所对应的子树,又能够转换内容元素<iwb:magnifier>所对应的子树。根据该转换逻辑,将该中间格式数据结构转换为相应的内存存储文件,该内存存储文件中包括一个shape内容元素及其相应的属性,以及一个magnifier内容元素及其相应的属性。
由此可见,通过根据与存储文件的格式相对应的解析逻辑,将存储文件解析为中间格式数据结构,并且根据与该中间格式数据结构中的内容元素相对应的转换逻辑,将该中间格式数据结构转换为内存存储文件,从而使得存储文件的格式的变化与存储文件的内容的变化相互隔离,即在解析过程能够对多种不同格式的存储文件进行解析,而不管该存储文件中包括何种内容元素,在转换过程能够对多种包含不同内容元素的中间格式数据结构进行转换,而不管相对应的存储文件为何种格式。因此,本发明实施例提供的存储文件的解析方法能够提高设备对文件格式的兼容性。同时,由于当存储文件的格式发生变化时只需添加新的解析逻辑,当存储文件的内容元素发生变化时只需添加新的转换逻辑,即可将具有新格式或者具有新内容元素的存储文件解析并转换为相应的内存存储文件,因此实现文件格式兼容的过程容易、简单。
进一步地,所述根据预先设置的与所述解析逻辑识别码所对应的解析逻辑,将所述存储文件解析为中间格式数据结构,具体包括:
根据所述解析逻辑识别码,从预先设置的解析管理器中获取所述解析逻辑识别码所对应的所述解析逻辑;
根据所述解析逻辑,将所述存储文件解析为所述中间格式数据结构。
需要说明的是,解析逻辑由解析管理器进行存储和管理,解析管理器中的每个解析逻辑均具有唯一的版本号,即解析逻辑识别码。每当增加一种新的存储文件的格式时,需要预先在解析管理器中添加相对应的解析逻辑。当需要将存储文件解析为中间格式数据结构时,计算机在解析管理器中查找到该存储文件中的解析逻辑识别码所对应的解析逻辑并获取该解析逻辑,并根据该解析逻辑将存储文件解析为中间格式数据结构。
例如,如图8所示为本实施方式的解析过程的流程示意图,解析管理器81中存储有解析逻辑A和解析逻辑B。当需要将格式为A的存储文件A解析为中间格式数据结构82时,则从解析管理器81中获取解析逻辑A,并根据该解析逻辑A对存储文件A进行解析。当需要将格式为B的存储文件B解析为中间格式数据结构82时,则从解析管理器81中获取解析逻辑B,并根据该解析逻辑B对存储文件B进行解析。当存储文件中新增加一种格式为C的存储文件C时,则在解析管理器81中添加能够解析该存储文件C的解析逻辑C。
进一步地,所述解析逻辑中包括第一解析逻辑和第二解析逻辑;
所述根据所述解析逻辑,将所述存储文件解析为所述中间格式数据结构,具体包括:
根据所述第一解析逻辑,调用与所述存储文件的格式所对应的格式解析器,将所述存储 文件解析为相应的格式数据结构;
根据所述第二解析逻辑,对所述格式数据结构的节点引用关系进行修改,将所述格式数据结构解析为所述中间格式数据结构。
需要说明的是,解析逻辑分为两个部分,即第一解析逻辑和第二解析逻辑。第一解析逻辑与存储文件的格式相对应,用于调用与存储文件的格式相对应的格式解析器,从而将存储文件解析为相应的格式数据结构。第二解析逻辑用于对该格式数据结构进行递归,从而遍历该格式数据结构并且修改其中的节点引用关系,将该格式数据结构进一步解析为中间格式数据结构。其中,格式数据结构可以为树型结构,也可以为链表、堆栈等其他类型的数据结构。不同的存储文件的格式所对应的格式数据结构的节点引用关系可能相同,也可能不相同。
例如,在将某一xml格式的存储文件解析为中间格式数据结构时,先根据解析逻辑中的第一解析逻辑,调用xml格式解析器,将该存储文件解析为xml格式数据结构,即xml树。随后,根据解析逻辑中的第二解析逻辑,对该xml格式数据结构进行递归,从而遍历该xml格式数据结构并且修改其中的节点引用关系,将该xml格式数据结构进一步解析为中间格式数据结构。
在另一个优选的实施方式中,所述根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转换为内存存储文件,具体包括:
根据所述元素识别码,从预先设置的转换管理器中获取所述元素识别码所共同对应的转换逻辑;
根据所述转换逻辑,对所述中间格式数据结构进行递归,将所述中间格式数据结构转换为所述内存存储文件。
需要说明的是,转换逻辑由转换管理器进行存储和管理,转换管理器中的每个转换逻辑中均具有其能够转换的所有内容元素的元素识别码。每当存储文件中的内容元素发生变化以实现新的功能时,需要预先在转换管理器中添加相对应的转换逻辑。当需要将中间格式数据结构转换为内存存储文件时,在转换管理器中查找到该中间格式数据结构中的每个内容元素的元素识别码所共同对应的转换逻辑并获取该转换逻辑,并根据该转换逻辑,对该中间格式数据结构进行递归,从而将该中间格式数据结构转换为内存存储文件。
例如,如图9所示的本实施方式的转换过程的流程示意图,转换管理器92中存储有转换逻辑A和转换逻辑B。假设其中的转换逻辑A能够转换包括内容元素a和内容元素b的中间格式数据结构,转换逻辑B能够转换包括内容元素a、内容元素b和内容元素c的中间格式数据结构。当中间格式数据结构91中包括内容元素a和内容元素b时,则从转换管理器92 中获取转换逻辑A,并根据该转换逻辑A将该中间格式数据结构91转换为相应的内存存储文件A,转换所得的内存存储文件A中包括内容元素a及其相应的属性,以及内容元素b及其相应的属性。当需要在包括内容元素a和内容元素b的存储文件中增加内容元素d以实现新的功能时,则在转换管理器92中添加能够转换包括内容元素a、内容元素b和内容元素d的中间格式数据结构的转换逻辑C。
进一步地,在所述根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转换为内存存储文件之后,还包括:
将所述内存存储文件中的各个内容元素渲染至显示屏中显示。
需要说明的是,在将存储文件解析并且转换为内存存储文件之后,对该内存存储文件中的内容元素进行渲染,使之在显示屏中显示。
例如,某一存储文件中包括表示椭圆的内容元素a和表示放大镜的内容元素b,则与之相对应的内存存储文件中包括内容元素a及其相应的属性,以及内容元素b及其相应的属性。在对该内存存储文件进行渲染之后,设备的显示屏上显示一个椭圆和一个放大镜。
本发明实施例提供的存储文件的解析方法,通过根据与存储文件的格式相对应的解析逻辑,将存储文件解析为中间格式数据结构,并且根据与该中间格式数据结构中的内容元素相对应的转换逻辑,将该中间格式数据结构转换为内存存储文件,从而使得存储文件的格式的变化与存储文件的内容的变化相互隔离,即在解析过程能够对多种不同格式的存储文件进行解析,而不管该存储文件中包括何种内容元素,在转换过程能够对多种包含不同内容元素的中间格式数据结构进行转换,而不管相对应的存储文件为何种格式。因此,本发明实施例提供的存储文件的解析方法能够提高设备对文件格式的兼容性。同时,由于当存储文件的格式发生变化时只需添加新的解析逻辑,当存储文件的内容元素发生变化时只需添加新的转换逻辑,因此实现格式兼容的过程容易、简单。
相应地,本发明还提供一种存储文件的解析装置,能够实现上述实施例中的存储文件的解析方法的所有流程。
参见图10,是本发明提供的存储文件的解析装置的一个实施例的结构示意图,具体如下:
存储文件读取模块01,用于读取存储文件;其中,所述存储文件中包括与所述存储文件的格式所对应的解析逻辑识别码;
存储文件解析模块02,用于根据预先设置的与所述解析逻辑识别码所对应的解析逻辑, 将所述存储文件解析为中间格式数据结构;其中,所述中间格式数据结构中包括与所述存储文件中的各个内容元素分别对应的元素识别码;以及,
中间格式数据结构转换模块03,用于根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转换为内存存储文件;其中,所述内存存储文件为所述存储文件在内存中的映射。
进一步地,所述存储文件解析模块02,具体包括:
解析逻辑获取单元,用于根据所述解析逻辑识别码,从预先设置的解析管理器中获取所述解析逻辑识别码所对应的所述解析逻辑;以及,
文件解析单元,用于根据所述解析逻辑,将所述存储文件解析为所述中间格式数据结构。
进一步地,所述解析逻辑中包括第一解析逻辑和第二解析逻辑;
所述文件解析单元,具体包括:
第一解析子单元,用于根据所述第一解析逻辑,调用与所述存储文件的格式所对应的格式解析器,将所述存储文件解析为相应的格式数据结构;以及,
第二解析子单元,用于根据所述第二解析逻辑,对所述格式数据结构的节点引用关系进行修改,将所述格式数据结构解析为所述中间格式数据结构。
在另一个优选的实施方式中,所述中间格式数据结构转换模块03,具体包括:
转换逻辑获取单元,用于根据所述元素识别码,从预先设置的转换管理器中获取所述元素识别码所共同对应的转换逻辑;以及,
格式转换单元,用于根据所述转换逻辑,对所述中间格式数据结构进行递归,将所述中间格式数据结构转换为所述内存存储文件。
进一步地,所述存储文件的解析装置,还包括:
渲染显示模块,用于将所述内存存储文件中的各个内容元素渲染至显示屏中显示。
本发明实施例提供的存储文件的解析装置,通过根据与存储文件的格式相对应的解析逻辑,将存储文件解析为中间格式数据结构,并且根据与该中间格式数据结构中的内容元素相对应的转换逻辑,将该中间格式数据结构转换为内存存储文件,从而使得存储文件的格式的变化与存储文件的内容的变化相互隔离,即在解析过程能够对多种不同格式的存储文件进行解析,而不管该存储文件中包括何种内容元素,在转换过程能够对多种包含不同内容元素的 中间格式数据结构进行转换,而不管相对应的存储文件为何种格式。因此,本发明实施例提供的存储文件的解析方法能够提高设备对文件格式的兼容性。同时,由于当存储文件的格式发生变化时只需添加新的解析逻辑,当存储文件的内容元素发生变化时只需添加新的转换逻辑,因此实现格式兼容的过程容易、简单。
以上所述是本发明的优选实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本发明原理的前提下,还可以作出若干改进和润饰,这些改进和润饰也视为本发明的保护范围。

Claims (10)

  1. 一种存储文件的解析方法,其特征在于,包括:
    读取存储文件;其中,所述存储文件中包括与所述存储文件的格式所对应的解析逻辑识别码;
    根据预先设置的与所述解析逻辑识别码所对应的解析逻辑,将所述存储文件解析为中间格式数据结构;其中,所述中间格式数据结构中包括与所述存储文件中的各个内容元素分别对应的元素识别码;
    根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转换为内存存储文件;其中,所述内存存储文件为所述存储文件在内存中的映射。
  2. 如权利要求1所述的存储文件的解析方法,其特征在于,所述根据预先设置的与所述解析逻辑识别码所对应的解析逻辑,将所述存储文件解析为中间格式数据结构,具体包括:
    根据所述解析逻辑识别码,从预先设置的解析管理器中获取所述解析逻辑识别码所对应的所述解析逻辑;
    根据所述解析逻辑,将所述存储文件解析为所述中间格式数据结构。
  3. 如权利要求2所述的存储文件的解析方法,其特征在于,所述解析逻辑中包括第一解析逻辑和第二解析逻辑;
    所述根据所述解析逻辑,将所述存储文件解析为所述中间格式数据结构,具体包括:
    根据所述第一解析逻辑,调用与所述存储文件的格式所对应的格式解析器,将所述存储文件解析为相应的格式数据结构;
    根据所述第二解析逻辑,对所述格式数据结构的节点引用关系进行修改,将所述格式数据结构解析为所述中间格式数据结构。
  4. 如权利要求1所述的存储文件的解析方法,其特征在于,所述根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转换为内存存储文件,具体包括:
    根据所述元素识别码,从预先设置的转换管理器中获取所述元素识别码所共同对应的转换逻辑;
    根据所述转换逻辑,对所述中间格式数据结构进行递归,将所述中间格式数据结构转换为所述内存存储文件。
  5. 如权利要求1所述的存储文件的解析方法,其特征在于,在所述根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转换为内存存储文件之后,还包括:
    将所述内存存储文件中的各个内容元素渲染至显示屏中显示。
  6. 一种存储文件的解析装置,其特征在于,包括:
    存储文件读取模块,用于读取存储文件;其中,所述存储文件中包括与所述存储文件的格式所对应的解析逻辑识别码;
    存储文件解析模块,用于根据预先设置的与所述解析逻辑识别码所对应的解析逻辑,将所述存储文件解析为中间格式数据结构;其中,所述中间格式数据结构中包括与所述存储文件中的各个内容元素分别对应的元素识别码;以及,
    中间格式数据结构转换模块,用于根据预先设置的与所述元素识别码所共同对应的转换逻辑,将所述中间格式数据结构转换为内存存储文件;其中,所述内存存储文件为所述存储文件在内存中的映射。
  7. 如权利要求6所述的存储文件的解析装置,其特征在于,所述存储文件解析模块,具体包括:
    解析逻辑获取单元,用于根据所述解析逻辑识别码,从预先设置的解析管理器中获取所述解析逻辑识别码所对应的所述解析逻辑;以及,
    文件解析单元,用于根据所述解析逻辑,将所述存储文件解析为所述中间格式数据结构。
  8. 如权利要求7所述的存储文件的解析装置,其特征在于,所述解析逻辑中包括第一解析逻辑和第二解析逻辑;
    所述文件解析单元,具体包括:
    第一解析子单元,用于根据所述第一解析逻辑,调用与所述存储文件的格式所对应的格式解析器,将所述存储文件解析为相应的格式数据结构;以及,
    第二解析子单元,用于根据所述第二解析逻辑,对所述格式数据结构的节点引用关系进行修改,将所述格式数据结构解析为所述中间格式数据结构。
  9. 如权利要求6所述的存储文件的解析装置,其特征在于,所述中间格式数据结构转换模块,具体包括:
    转换逻辑获取单元,用于根据所述元素识别码,从预先设置的转换管理器中获取所述元素识别码所共同对应的转换逻辑;以及,
    格式转换单元,用于根据所述转换逻辑,对所述中间格式数据结构进行递归,将所述中间格式数据结构转换为所述内存存储文件。
  10. 如权利要求6所述的存储文件的解析装置,其特征在于,所述存储文件的解析装置,还包括:
    渲染显示模块,用于将所述内存存储文件中的各个内容元素渲染至显示屏中显示。
PCT/CN2016/113344 2016-08-09 2016-12-30 存储文件的解析方法和装置 Ceased WO2018028127A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201610648942.XA CN106649428A (zh) 2016-08-09 2016-08-09 存储文件的解析方法和装置
CN201610648942.X 2016-08-09

Publications (1)

Publication Number Publication Date
WO2018028127A1 true WO2018028127A1 (zh) 2018-02-15

Family

ID=58852999

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/113344 Ceased WO2018028127A1 (zh) 2016-08-09 2016-12-30 存储文件的解析方法和装置

Country Status (2)

Country Link
CN (1) CN106649428A (zh)
WO (1) WO2018028127A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109325217A (zh) * 2018-09-19 2019-02-12 深圳市元征科技股份有限公司 一种文件转换方法、系统、装置及计算机可读存储介质

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109213709B (zh) * 2017-06-30 2021-01-15 阿里巴巴(中国)有限公司 数据转换方法、装置及数据处理设备
CN110688343B (zh) * 2019-08-26 2023-04-28 天津开心生活科技有限公司 一种转换数据格式的方法及装置
CN112732643B (zh) * 2021-04-01 2021-07-20 南京国睿信维软件有限公司 流程图图形文件数据与s1000d标准xml格式数据的相互转换方法

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101055577A (zh) * 2006-04-12 2007-10-17 龙搜(北京)科技有限公司 可扩展标记语言集中器
CN102243665A (zh) * 2011-08-22 2011-11-16 上海梅花信息有限公司 一种文档在线播放系统及方法
CN102402431A (zh) * 2010-09-17 2012-04-04 基信康信息技术(上海)有限公司 利用xml进行手机ui设计的方法
US20140279875A1 (en) * 2013-03-15 2014-09-18 Matthew Pitstick Method and apparatus for converting data

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100501740C (zh) * 2007-01-25 2009-06-17 无敌科技(西安)有限公司 将不同格式的文本数据转换为统一格式的方法及其系统
CN101247589B (zh) * 2007-07-04 2010-09-08 华为技术有限公司 移动终端数据的转换/备份方法、设备和系统
CN101917520B (zh) * 2007-07-04 2013-01-30 华为技术有限公司 移动终端数据的转换/备份方法、设备和系统
CN101436185B (zh) * 2007-11-12 2012-02-01 北大方正集团有限公司 一种利用xml内存树实现多种文件兼容的方法
CN102053952A (zh) * 2009-11-10 2011-05-11 英华达(上海)电子有限公司 电子书数据格式转换的方法、装置及便携式电子书阅读器
CN102866986A (zh) * 2012-08-30 2013-01-09 中国矿业大学 一种文档格式转换系统
CN104935499A (zh) * 2015-05-28 2015-09-23 杭州华三通信技术有限公司 一种消息格式转换方法和设备

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101055577A (zh) * 2006-04-12 2007-10-17 龙搜(北京)科技有限公司 可扩展标记语言集中器
CN102402431A (zh) * 2010-09-17 2012-04-04 基信康信息技术(上海)有限公司 利用xml进行手机ui设计的方法
CN102243665A (zh) * 2011-08-22 2011-11-16 上海梅花信息有限公司 一种文档在线播放系统及方法
US20140279875A1 (en) * 2013-03-15 2014-09-18 Matthew Pitstick Method and apparatus for converting data

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109325217A (zh) * 2018-09-19 2019-02-12 深圳市元征科技股份有限公司 一种文件转换方法、系统、装置及计算机可读存储介质
CN109325217B (zh) * 2018-09-19 2023-04-18 深圳市元征科技股份有限公司 一种文件转换方法、系统、装置及计算机可读存储介质

Also Published As

Publication number Publication date
CN106649428A (zh) 2017-05-10

Similar Documents

Publication Publication Date Title
CN102982010B (zh) 提取文档结构的方法和装置
CN108664546B (zh) Xml数据结构转换方法和装置
CN104281601B (zh) 构建超大字库的方法及装置、字符显示方法及装置
CN105843787B (zh) 一种富文本编辑方法及系统
WO2018028127A1 (zh) 存储文件的解析方法和装置
CN105278961B (zh) 生成数据库表结构文档的方法及系统
CN111508562A (zh) 流程描述性语言的可视化显示方法、装置、设备和介质
CN101739462A (zh) 可扩展标记语言编码方法、解码方法和客户端
CN107015948A (zh) 一种日志信息格式化方法及系统
CN114676133A (zh) 索引创建方法、装置、设备及存储介质
CN104424271B (zh) 出版物数字资源的自动采集方法及系统
CN111444235A (zh) 基于Django的数据序列化方法、装置、计算机设备及存储介质
WO2015010386A1 (zh) 文档格式转换装置和文档格式转换方法
TW201448544A (zh) 經由通用類型長度值產生器及剖析器之訊息交換
CN100485670C (zh) 用于从数据库取得和呈现数据的方法及系统
CN111435372A (zh) 数据展示方法及系统、数据编辑方法及系统、设备、介质
CN110308907B (zh) 数据转换方法、装置、存储介质及电子设备
CN114489594B (zh) 一种命令解析处理方法及装置
CN116257714A (zh) 层叠样式表的生成方法、装置、计算机设备和存储介质
CN101114943A (zh) 一种对网管数据上载比较结果进行优化展现的方法
CN109117207B (zh) 一种业务流程模型的数据处理方法
CN112988142A (zh) 一种属性表生成方法和装置
CN117454846B (zh) 一种xsd文件转换为json文件的方法
CN112540958A (zh) 文件处理方法、装置、设备及计算机存储介质
CN112799666B (zh) 容器集群视图自动构建方法、系统、计算机设备及介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 16912580

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 08.07.2019)

122 Ep: pct application non-entry in european phase

Ref document number: 16912580

Country of ref document: EP

Kind code of ref document: A1