What is parse?
identicon
Danny
DISCUSSION OF ORIGIN

Danny Monday 19th February 2018, 19:25

What is parse?

In an article, I read "parse" the this and that... What is meant by "parse"?
Thank you for illuminating me!
Danny
DISCUSSION OF ORIGIN
identicon
webmaster@cfcc0ed1

webmaster@cfcc0ed1 Tuesday 20th February 2018, 19:13

To parse means: to split a text into a list of tokens, by using some characters as delimiters (separators).
It is also called "token parsing", where "token" means "word" (group of characters).
Usually, the text is given as a string and the resulting list comes in a StringList.

Example: you write a procedure WordList(S: string; var Tokens: TStringList) that uses the space character as a delimiter. Calling the procedure as:
WordList('DelphiLand is a great website', Tokens)
results in a stringlist with as contents:

'DelphiLand'
'is'
'a'
'great'
'website'
Last modified: Wednesday 21st February 2018, 14:33
Suggested Topics View / Reply Forum
webmaster@cfcc0ed1 started Emoticons (smilies) 1.2K / 0 General
webmaster@cfcc0ed1 started Database Tutorials 1.2K / 0 News
webmaster@cfcc0ed1 started Starting a new discussion 1.4K / 2 General
Guido started Lazarus / Free Pascal Tutorials 496 / 0 News