Generating data format description language schema
First Claim
1. A method for generating a Data Format Description Language (DFDL) schema, the method comprising:
- retrieving annotations added to sample data according to an annotation rule;
analyzing, automatically by a processor, the annotated sample data;
generating, by the processor, a computer readable description of the annotated sample data according to the DFDL specification;
creating, using the computer readable description of the annotated sample data, a logic schema and a configuration file according to the annotation rule and the retrieved annotations added to the sample data, wherein the logic schema represents a tree structure of data elements in the sample data, and the configuration file defines computer executable operations for adding DFDL annotations corresponding to the annotations into the logic schema, wherein the configuration file includes a first section and a second section, the first section including code for declaring operations and generation processes, the second section including code for inputting parameters of the operations declared in the first section;
generating, automatically by the processor, a DFDL schema corresponding to the sample data according to the logic schema and the configuration file by;
loading and parsing the first section of the configuration file;
retrieving, based on the parsing of the first section of the configuration file, an operation to be performed from the first section of the configuration file;
loading and parsing the second section of the configuration file according to a value of an input attribute in the operation;
retrieving, based on the parsing the second section of the configuration file, an input definition of the operation, wherein the input definition of the operation includes a location of an attribute to be added to the DFDL schema, a name of the attribute, and a value of the attribute;
loading and parsing the logic schema using the location to determine a definition for an element; and
generating the element in the DFDL schema using the definition, wherein the element includes the name of the attribute and the value of the attribute;
receiving, by the processor, a stream of data; and
converting, automatically by the processor, the stream of data into a DFDL document using the generated DFDL schema.
1 Assignment
0 Petitions
Accused Products
Abstract
An annotation retrieval module may be configured to retrieve annotations added to sample data, the annotations having been added according to an annotation rule. An analysis tool may be configured to create a logical schema and a configuration file from the retrieved annotations, according to the annotation rule. The logic schema may represent a tree structure containing one or more data elements corresponding to the sample data, and the configuration file may define one or more operations for adding DFDL annotations into the logic schema. A DFDL schema generator may be configured to generate a DFDL schema for the sample data according to the logic schema and the configuration file.
7 Citations
19 Claims
-
1. A method for generating a Data Format Description Language (DFDL) schema, the method comprising:
-
retrieving annotations added to sample data according to an annotation rule; analyzing, automatically by a processor, the annotated sample data; generating, by the processor, a computer readable description of the annotated sample data according to the DFDL specification; creating, using the computer readable description of the annotated sample data, a logic schema and a configuration file according to the annotation rule and the retrieved annotations added to the sample data, wherein the logic schema represents a tree structure of data elements in the sample data, and the configuration file defines computer executable operations for adding DFDL annotations corresponding to the annotations into the logic schema, wherein the configuration file includes a first section and a second section, the first section including code for declaring operations and generation processes, the second section including code for inputting parameters of the operations declared in the first section; generating, automatically by the processor, a DFDL schema corresponding to the sample data according to the logic schema and the configuration file by; loading and parsing the first section of the configuration file; retrieving, based on the parsing of the first section of the configuration file, an operation to be performed from the first section of the configuration file; loading and parsing the second section of the configuration file according to a value of an input attribute in the operation; retrieving, based on the parsing the second section of the configuration file, an input definition of the operation, wherein the input definition of the operation includes a location of an attribute to be added to the DFDL schema, a name of the attribute, and a value of the attribute; loading and parsing the logic schema using the location to determine a definition for an element; and generating the element in the DFDL schema using the definition, wherein the element includes the name of the attribute and the value of the attribute; receiving, by the processor, a stream of data; and converting, automatically by the processor, the stream of data into a DFDL document using the generated DFDL schema. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10)
-
-
11. An apparatus for generating a Data Format Description Language (DFDL) schema, the apparatus comprising:
-
a memory; and a processor communicatively coupled to the memory, wherein the processor is configured to perform a method comprising; retrieving annotations added to sample data according to an annotation rule; analyzing, automatically, the annotated sample data; generating a computer readable description of the annotated sample data according to the DFDL specification; creating, using the computer readable description of the sample data, a logic schema and a configuration file according to the annotation rule and the retrieved annotations added to the sample data, wherein the logic schema represents a tree structure of data elements in the sample data, and the configuration file defines computer executable operations of adding DFDL annotations, corresponding to the retrieved annotations, into the logic schema, wherein the configuration file includes a first section and a second section, the first section including code for declaring operations and generation processes, the second section including code for inputting parameters of the operations declared in the first section; generating, automatically, a DFDL schema corresponding to the sample data according to the logic schema and the configuration file by; loading and parsing the first section of the configuration file; retrieving, based on the parsing of the first section of the configuration file, an operation to be performed from the first section of the configuration file; loading and parsing the second section of the configuration file according to a value of an input attribute in the operation; retrieving, based on the parsing the second section of the configuration file, an input definition of the operation, wherein the input definition of the operation includes a location of an attribute to be added to the DFDL schema, a name of the attribute, and a value of the attribute; loading and parsing the logic schema using the location to determine a definition for an element; and generating the element in the DFDL schema using the definition, wherein the element includes the name of the attribute and the value of the attribute; receiving a stream of data; and converting, automatically, the stream of data into a DFDL document using the generated DFDL schema. - View Dependent Claims (12, 13, 14, 15, 16, 17, 18)
-
-
19. A computer program product for generating a Data Format Description Language (DFDL) schema, the computer program product comprising a computer readable storage medium having program instructions embodied therewith, the program instructions executable by a processor to cause the processor to:
-
retrieve annotations from a sample data, the annotation corresponding to an annotation rule; analyze, automatically, the annotated sample data; generate a computer readable description of the annotated sample data according to the DFDL specification; create, using the computer readable description of the annotated sample data, a logic schema and a configuration file according to the annotation rule and using the retrieved annotation, wherein the logic schema represents a tree structure of data elements, and the configuration file defines one or more operations for adding DFDL annotations into the logic schema, the DFDL annotations corresponding to the retrieved annotations, wherein the configuration file includes a first section and a second section, the first section including code for declaring operations and generation processes, the second section including code for inputting parameters of the operations declared in the first section; generate, automatically, a DFDL schema for the sample data according to the logic schema and the configuration file by; loading and parsing the first section of the configuration file; retrieving, based on the parsing of the first section of the configuration file, an operation to be performed from the first section of the configuration file; loading and parsing the second section of the configuration file according to a value of an input attribute in the operation; retrieving, based on the parsing the second section of the configuration file, an input definition of the operation, wherein the input definition of the operation includes a location of an attribute to be added to the DFDL schema, a name of the attribute, and a value of the attribute; loading and parsing the logic schema using the location to determine a definition for an element; and generating the element in the DFDL schema using the definition, wherein the element includes the name of the attribute and the value of the attribute; receive a stream of data; and convert, automatically, the stream of data into a DFDL document using the generated DFDL schema.
-
Specification