Millepede-II V04-17-03
|
Analyse text string. More...
Go to the source code of this file.
Modules | |
module | mptext |
Keyword position. | |
Functions/Subroutines | |
subroutine | ratext (text, nums, dnum, mnum) |
Translate text. More... | |
subroutine | rltext (text, ia, ib, nab) |
Analyse text range. More... | |
integer(mpi) function | matint (pat, text, npat, ntext) |
Approximate string matching. More... | |
Variables | |
integer(mpi) | mptext::keya |
start (position) of first keyword More... | |
integer(mpi) | mptext::keyb |
end (position) of first keyword More... | |
integer(mpi) | mptext::keyc |
end (position) of last keyword More... | |
Analyse text string.
Definition in file mptext.f90.
integer(mpi) function matint | ( | character (len=*), intent(in) | pat, |
character (len=*), intent(in) | text, | ||
integer(mpi), intent(out) | npat, | ||
integer(mpi), intent(out) | ntext | ||
) |
Approximate string matching.
Approximate (parallel) string matching - case insensitive. Return number of matching characters (in same order) in strings PAT and TEXT, and number NPAT, NTEXT of characters of string PAT and string TEXT. Strings are considered from first to last non-blank character.
Example:
MATCH = MATINT(' keYs ','keyWO RD',NPAT,NTEXT) returns MATCH=3, NPAT=4, NTEXT=8
[in] | pat | pattern |
[in] | text | text |
[out] | npat | number of characters in pattern |
[out] | ntext | number of characters in text |
Definition at line 308 of file mptext.f90.
References matint().
subroutine ratext | ( | character (len=*), intent(in) | text, |
integer(mpi), intent(out) | nums, | ||
real(mpd), dimension(mnum), intent(out) | dnum, | ||
integer(mpi), intent(in) | mnum | ||
) |
Translate text.
Translate TEXT into arrays of double precision numbers DNUMS(NUMS). Text preceeding numbers is TEXT(KEYA:KEYB), if KEYB >= KEYA.
[in] | text | text |
[out] | nums | number of numbers found |
[out] | dnum | array of numbers found |
[in] | mnum | size of dnum |
Definition at line 50 of file mptext.f90.
References mptext::keya, mptext::keyb, and mptext::keyc.
subroutine rltext | ( | character (len=*), intent(in) | text, |
integer(mpi), intent(out) | ia, | ||
integer(mpi), intent(out) | ib, | ||
integer(mpi), intent(out) | nab | ||
) |
Analyse text range.
[in] | text | text |
[out] | ia | index of first non-blank character, or =1 |
[out] | ib | index of last non-blank character, or =0 - comment excluded |
[out] | nab | index of last non-blank character (=0 for blank text) |
Definition at line 255 of file mptext.f90.