Commit 02a210bd authored by Omran Saleh's avatar Omran Saleh
Browse files

minor change

parent 77ce9de7
......@@ -69,7 +69,7 @@ In our approach, we have adopted the automated code translation (ACT) technique
\item[Flow graph: ] A logical representation of the input program which comprises nodes (flow nodes) and edges (pipes). A flow node instance represents an operator in the data-flow program. It is the intermediate mean between the parser and the code generator to build up a graph of nodes and generate the target code, respectively. Pipe instance represents the edge between two nodes of the dataflow graph. Therefore, each pipe contains the input node (the node producing tuples which are sent via the pipe) and the output node (the node consuming these tuples from the pipe). This component is mainly used to generate the target code in a specific language. And Irrespective of target language program to be generated this component remains same.
\item[Code generator:] Once the flow graph is generated from the input \PipeFlow source program, the code generator generates the target code based on this graph. The code generator takes the flow graph generated by the parser and a template file, processes all nodes and pipes iteratively, and creates the equivalent code using the StringTemplate library. There are separate code generators for each specific target language depending on the target code to be generated.
\item[Template file:] It is also defined as a string template group file (stg). We can imagine this file as string with holes which has to be filled by the code generator. Inside this file, the rules with its arguments should be defined to specify how to format the operators code and which part in it has to render. Therefore, some parts will be rendered as it is where other parts contain place-holders will be replaced with the provided arguments. Template file is different for each specific target code to be generated as the format and syntax of each target language to be generated is different. The template file contains the library files to be included, packages to be imported, or the code blocks for operators, etc.
\item[Template file:] It is also defined as a string template group file (stg). We can imagine this file as string with holes which has to be filled by the code generator. Inside this file, the rules with its arguments should be defined to specify how to format the operators code and which part in it has to render. Therefore, some parts will be rendered as it is whereas other parts contain place-holders will be replaced with the provided arguments. Template file is different for each specific target code to be generated as the format and syntax of each target language to be generated is different. The template file contains the library files to be included, packages to be imported, or the code blocks for operators, etc.
\end{description}
\subsection{An Example of Translation}
Consider below a simple\footnote{Because of the limitation in the number of pages.} sample script written in \PipeFlow that needs to be translated to PipeFabric and Storm by our system. This script reads a stream that contains \texttt{x} and \texttt{y} fields. Later, the \texttt{x} field is filtered and aggregated to find the sum of all \texttt{y} fields for a particular \texttt{x}. Note that the \PipeFlow construct is simpler than other engine constructs.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment