The process of "parsing" can be described as reading in a data stream of some sort and building an in-memory model or representation of the semantic content of that data, in order to facilitate performing some kind of transformation on the data.
Some examples:
- A compiler parses your source code to (usually) build an abstract syntax tree of the code, with the objective of generating object- (or byte-) code for execution by a machine.
- An interpreter does the same thing but the syntax tree is then directly used to control execution (some interpreters are a mashup of byte-code generators and virtual machines and may generate intermediate byte-code).
- A CSV parser reads a stream structured according to the rules of CSV (commas, quoting, etc) to extract the data items represented by each line in the file.
- A JSON or XML parser does a similar operation for JSON- or XML-encoded data, building an in-memory representation of the semantic values of the data items and their hierarchical inter-relationships.