API Reference

Public API

Fortran90Namelists.TokenizerType
Tokenizer(index=0, prior_char='', char='', prior_delim='', group_token='')

A mutable struct for tokenizing input string.

It maintains state information about the current position in the string, the current character, the previous character, the previous delimiter, and the group token if inside a namelist group.

source
Fortran90Namelists.tokenize!Function
tokenize!(tk::Tokenizer, line)

Tokenize the input line using the tokenizer tk.

The function updates the state of tk to reflect the position within line and returns a list of tokens.

source

Private API

The functions and types mentioned here are considered part of the private API and are not intended for direct use by users. They may be modified, moved, or removed without notice and are primarily meant for internal use within the package. Using them directly may result in unexpected errors or compatibility issues in your code.

Fortran90Namelists.tokenizestr!Function
tokenizestr!(tk::Tokenizer, chars::Iterators.Stateful)

Tokenizes a Fortran string.

This function treats everything between a pair of delimiters (such as quotation marks) as a string. It respects escaped delimiters and updates the state of the tokenizer tk to reflect the position within the string.

source
Fortran90Namelists.update!Function
update!(tk::Tokenizer, chars::Iterators.Stateful)

Update the current characters in the tokenizer, tk.

This includes updating both the prior and current characters, and incrementing the index.

source