Which character can be used to specify a boundary between characters in text files?
A delimiter denotes the limits of something, where it starts and where it ends. For example: Show
has two delimiters, both of which happen to be the double-quote character. The delimiters indicate what's part of the thing, and what is not. A separator distinguishes two things in a sequence:
The role of a separator is to demarcate two distinct entities so that they can be distinguished. (Note that I say "two" because in computer science we're generally talking about processing a linear sequence of characters). A terminator indicates the end of a sequence. In a CSV, you could think of the newline as terminating the record on one line, or as separating one record from the next. Token boundaries are often denoted by a change in syntax classes:
would likely be tokenised as The categories aren't completely distinct. For example:
could (depending on your syntax) be a list of three items; the brackets delimit the list and the
right-bracket terminates the list and marks the end of the As for SO's use of those terms as tags, they're just that: tags to indicate the topic of a question. There isn't a single unified controlled vocabulary for tags; anyone with enough karma can add a new tag. Enough differences in terminology exist that you could never have a single controlled tag vocabulary across all of the topics that SO covers. answered Feb 2, 2012 at 21:14
Ian DickinsonIan Dickinson 12.7k10 gold badges40 silver badges65 bronze badges 2 Technically a delimiter goes between things, perhaps in order to tell you where one field ends and another begins, such as in a comma-separated-value (CSV) file. A terminator goes at the end of something, terminating the line/input/whatever. A separator can be a delimiter or anything else that separates things. Consider the spaces between words in the English language for example. You could argue that a newline character is a line terminator, a delimiter of lines or something that separates two lines. For this reason there are a few different newline-type characters in the Unicode specification. answered Feb 2, 2012 at 19:44
Ian GilhamIan Gilham 1,9163 gold badges21 silver badges31 bronze badges 2 A delimiter is one or two markers that show the start and end of something. They're needed because we don't know how long that 'something' will be. We can have either: 1. a single delimiter, or 2. a pair of pair-delimiters
A seperator is a synonym of a "delimiter", but from my experience it usually refers to field delimiters. A field delimiter acts as a divider between one field and the one following it, which is why is can be though of as "separating" them.
A terminator marks the end of a group of things, again needed because we don't know how long it is.
The terms, delimiter, separator originate from the classical idea of storage, conceptually, being comprised of files, records, and fields, (a file has many records, a record has many fields). In this context, a single delimiter and pair-delimiters might be called record delimiters and field delimiters. Because of the historical significance of files-records-field taxonomy, this terms have a more widespread usage (see Wikipedia page for Delimiter).
For complex nested structures, a terminator can also be a delimiter/separator
(they're not mutually exclusive definitions). From the previous example, the
Really you'll only need to say "terminator" when you're talking at one individual item, (just one string answered Feb 8, 2017 at 10:10
James LawsonJames Lawson 7,75344 silver badges43 bronze badges This response is in context of CSV because all of the provided answers focus on English language instead. Delimiters are all elements mentioned in the given CSV specification that describe the boundaries of stuff, separator is a common name for field delimiters, terminator is a common name for record delimiters. Delimiter is a part of CSV format specification, it defines boundaries and doesn't have to be a printable character. Terminators, separators and field qualifiers are delimiters but are not necessary to specify a CSV format, e.g. 10 columns field delimiter and 30 columns record delimiter mean each 30 columns are one record and each 10 columns are one field (usually padded with white space). In other words CSV format without separators has a constant field and record length, e.g.:
Terminator is a delimiter that marks the end of a
single CSV record and is usually represented either by Line Feed (
Separator is a delimiter that marks the division between CSV fields and is most often represented by a comma (or a semicolon), it has been introduced to store dynamic length values, e.g. two comma separated records in CSV format with
Field qualifier is a delimiter usually used in pairs instead of escape sequence. It is a printable character that isn't allowed in the field value (unless given CSV format specification provides the escape sequence) and marks the beginning and the end of a field, it was introduced to store values containing separators, e.g. this CSV has 2 records with 3 fields each but 3rd field value can contain a semicolon that otherwise acts as a fields separator:
Escape sequence is a character (or a set of characters) that
marks anything that follows the escape sequence as non-significant and therefore as a part of the field value (e.g. backslash might specify the immediately following separator as a part of the value). This sequence can escape one or multiple characters, e.g. CSV with
answered Mar 16, 2016 at 17:54
cprncprn 1,4421 gold badge15 silver badges23 bronze badges DelimiterThere are a couple of senses for
Some may argue the SeparatorIs exactly the same as the first sense (above) of a delimiter (a frontier). So, a TerminatorDemarcate the end of an individual "field". Or,
more strictly, as the NUL (
So, a terminator character is also a delimiter but must also appear at the end. TagsStackoverflow has tags only for delimiters and separators delimiterA delimiter is a sequence of one or more characters used to specify the boundary between separate, independent regions in plain text or other data streams. The terminator tag only apply to a shell terminal emulator: terminatorTerminator is a GPL terminal emulator. And, yes, delimiter and separator are many
times equivalent answered Nov 17, 2018 at 19:12 Interesting question and answers. To summarize, 1) delimiter marks the "limits" of something, i.e. beginning and/or end; 2) terminator is just a special term for "end delimiter"; 3) separator entails there are items on both sides of it (unlike delimiter). Best example I can think of for a start delimiter is the start-comment markers in programming languages ("#", "//", etc.). Best example I can think of for a terminator (end delimiter) is the newline character in Unix. It's a misnomer -- it always terminates a (possibly empty) line but doesn't always start a new line, i.e. when it is the last character in a file. Maybe a better common example is the simple period for sentences. Best example I can think of for a separator is the simple comma. Note that comma never appears in English without text both before and after it. Interesting to note that none of these is necessarily limited to single-character. In fact awk (or maybe only gawk?) in Unix allows FS (field separator) to be any regexp. Also, although "any non-zero amount of whitespace" is considered a "word delimiter" in e.g. the wc command, there are also zero-width "word boundary" specifiers in regexps (e.g. \b). Interesting to ponder whether such zero-width items/boundaries could be considered "delimiters" as well. I tend to think not (too much of a stretch). answered Sep 26, 2015 at 17:24
Jeff YJeff Y 2,4441 gold badge11 silver badges17 bronze badges Terminators are separators when you start with empty. A;B;C; is actually A;B;C;empty. answered Mar 10, 2016 at 5:58
Samuel DanielsonSamuel Danielson 5,0013 gold badges34 silver badges34 bronze badges Just like the English language, there is the technically correct answer, and the generally used answer, and it is probably relevant to isolate to the programming usage of the term definitions being sought. The industry has long used the phrase 'Comma Delimited' file to mean: FirstRowFirstValue,FirstRowSecondValue,FirstRowThirdValue SecondRowFirstValue,SecondRowSecondValue,SecondRowThirdValue TECHNICALLY, this is a Comma 'SEPARATED' list. TECHNICALLY, THIS is a Comma 'DELIMITED' list. ,FirstRowFirstValue,FirstRowSecondValue,FirstRowThirdValue, ,SecondRowFirstValue,SecondRowSecondValue,SecondRowThirdValue, or this: ,FirstRowFirstValue,,FirstRowSecondValue,,FirstRowThirdValue, ,SecondRowFirstValue,,SecondRowSecondValue,,SecondRowThirdValue, and nobody does that. Ever. And the industry standard is to use 'TEXT QUALIFIER' for the TECHNICAL definition of a 'DELIMITER' where (") is the 'TEXT QUALIFIER' and (,) is called the 'DELIMITER'. FirstRowFirstValue,"First Row Second Value",FirstRowThirdValue SecondRowFirstValue,SecondRowSecondValue,SecondRowThirdValue answered Sep 22, 2020 at 15:29
newbynewby 4871 gold badge6 silver badges13 bronze badges Adding to the answer here already, I've use the term notator.
Annotation is all notation and markup used in a particular document. For example, a "TODO List" document must be a line separated list of strings. Notation is markup used to denote specific meaning. For example, "string are in quotes" is a notation. A delimiter is the character or set of characters used to denote a notation. For example, the character quote is the delimiter for strings. A terminator is ending delimiter and prefix is the starting delimiter. For the "TODO List" document, quote may be used as the prefix and terminating delimiter. A seperator is a delimiter that separates two things. For example, "new line" is the separator for each "TODO List" item. In this example, "new line" is also a terminator; a new line may be used to terminate each line. A separator also being a terminator is typical, but not guaranteed to always be the case. Delimiters can also be "positional". A positionally delimited example is a column delimited mainframe flat file. answered Aug 31 at 16:25
ZamicolZamicol 4,2261 gold badge33 silver badges36 bronze badges "word 1", "word 2" \NULL
answered Feb 8, 2017 at 10:17
Zsolt SzilagyiZsolt Szilagyi 4,4524 gold badges25 silver badges43 bronze badges What FileStream property indicates whether the FileStream supports reading?Properties. What class can be used to provide information on directories or folders?Directory and System. IO. File classes provide static methods for retrieving information about directories and files.
Is the process of converting objects into streams of bytes?Serialization is the process of converting an object into a stream of bytes to store the object or transmit it to memory, a database, or a file. Its main purpose is to save the state of an object in order to be able to recreate it when needed. The reverse process is called deserialization.
How does AC application open a file quizlet?How does a C# application open a file? It opens a file by creating an object and associating a stream of bytes with that object. If you attempt to open a file with the Open file mode, what happens if the file does not exist? The program throws a System.
|