diff --git a/.github/workflows/deploy_api_docs.yml b/.github/workflows/deploy_api_docs.yml old mode 100755 new mode 100644 diff --git a/README.md b/README.md index e94a9c48..34f48347 100755 --- a/README.md +++ b/README.md @@ -25,7 +25,7 @@ public entities: use M_strings, only : [split2020](https://urbanjost.github.io/M_strings/split2020.3m_strings), [find_field](https://urbanjost.github.io/M_strings/find_field.3m_strings) use M_strings, only : [substitute](https://urbanjost.github.io/M_strings/substitute.3m_strings), [change](https://urbanjost.github.io/M_strings/change.3m_strings), [modif](https://urbanjost.github.io/M_strings/modif.3m_strings), [transliterate](https://urbanjost.github.io/M_strings/transliterate.3m_strings), [reverse](https://urbanjost.github.io/M_strings/reverse.3m_strings), [squeeze](https://urbanjost.github.io/M_strings/squeeze.3m_strings) use M_strings, only : [replace](https://urbanjost.github.io/M_strings/replace.3m_strings), [join](https://urbanjost.github.io/M_strings/join.3m_strings) - use M_strings, only : [upper](https://urbanjost.github.io/M_strings/upper.3m_strings), [lower](https://urbanjost.github.io/M_strings/lower.3m_strings), [upper_quoted](https://urbanjost.github.io/M_strings/upper_quoted.3m_strings) + use M_strings, only : [upper](https://urbanjost.github.io/M_strings/upper.3m_strings), [lower](https://urbanjost.github.io/M_strings/lower.3m_strings), [upper_quoted](https://urbanjost.github.io/M_strings/upper_quoted.3m_strings), [lower_quoted](https://urbanjost.github.io/M_strings/lower_quoted.3m_strings) use M_strings, only : [rotate13](https://urbanjost.github.io/M_strings/rotate13.3m_strings), [percent_encode](https://urbanjost.github.io/M_strings/percent_encode.3m_strings) use M_strings, only : [adjustc](https://urbanjost.github.io/M_strings/adjustc.3m_strings), [compact](https://urbanjost.github.io/M_strings/compact.3m_strings), [nospace](https://urbanjost.github.io/M_strings/nospace.3m_strings), [indent](https://urbanjost.github.io/M_strings/indent.3m_strings) use M_strings, only : [crop](https://urbanjost.github.io/M_strings/crop.3m_strings), [clip](https://urbanjost.github.io/M_strings/clip.3m_strings), [unquote](https://urbanjost.github.io/M_strings/unquote.3m_strings), [quote](https://urbanjost.github.io/M_strings/quote.3m_strings), [matching_delimiter](https://urbanjost.github.io/M_strings/matching_delimiter.3m_strings) @@ -47,9 +47,8 @@ public entities: use M_strings, only : [describe](https://urbanjost.github.io/M_strings/describe.3m_strings) use M_strings, only : [edit_distance](https://urbanjost.github.io/M_strings/edit_distance.3m_strings) use M_strings, only : [cc](https://urbanjost.github.io/M_strings/cc.3m_strings) - use M_strings, only : - [int](https://urbanjost.github.io/M_strings/int.3m_strings), [dble](https://urbanjost.github.io/M_strings/dble.3m_strings), [nint](https://urbanjost.github.io/M_strings/nint.3m_strings) - use M_strings, only : [atoi](https://urbanjost.github.io/M_strings/atoi.3m_strings), [atol](https://urbanjost.github.io/M_strings/atol.3m_strings), [dble](https://urbanjost.github.io/M_strings/ato.3m_strings) + use M_strings, only : [int](https://urbanjost.github.io/M_strings/int.3m_strings), [real](https://urbanjost.github.io/M_strings/real.3m_strings), [dble](https://urbanjost.github.io/M_strings/dble.3m_strings), [nint](https://urbanjost.github.io/M_strings/nint.3m_strings) + use M_strings, only : [atoi](https://urbanjost.github.io/M_strings/atoi.3m_strings), [atol](https://urbanjost.github.io/M_strings/atol.3m_strings), [ato](https://urbanjost.github.io/M_strings/ato.3m_strings) ## Intrinsics diff --git a/app/b64.f90 b/app/b64.f90 new file mode 100644 index 00000000..ae226826 --- /dev/null +++ b/app/b64.f90 @@ -0,0 +1,100 @@ +program demo_base64 +use M_io, only : filebyte +use M_strings, only : encode_base64, decode_base64 +use M_CLI2, only : set_args, iget, lget, infiles=>unnamed +! encode data to base64 encryption as defined by RFC-4648 and print to standard output +! usage: base64 inputfile > outputfile +! currently stdin and stdout cannot be defined as streams, so stdin should +! be restricted to ASCII files with a newline terminator at end, and stdout is +! potentially subject to linelength limits of the platform. +! reading input into memory could be expensive if the file is large +use,intrinsic :: iso_fortran_env, only : int8, int32, stderr=>ERROR_UNIT, stdout=>OUTPUT_UNIT +implicit none +integer(kind=int32) :: i, j, column, sz, pad, iostat +character(len=1),allocatable :: text(:) ! array to hold file in memory +character(len=1) :: chunk(4) +character(len=1) :: tri(3) +character(len=1),allocatable :: trilast(:) +integer :: wrap +character(len=*),parameter :: rfc4648_alphabet='ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' +integer,parameter :: rfc4648_linelength=76 +character(len=1),parameter :: rfc4648_padding='=' +character(len=:),allocatable :: help_text(:), version_text(:) +logical :: decode +logical :: ignore_garbage + call setup() + call set_args('--wrap:w 76 --decode:d F --ignore-garbage:i F',help_text,version_text) + wrap=iget('wrap') + ignore_garbage=lget('ignore-garbage') + decode=lget('decode') + if(size(infiles).eq.0)infiles=[character(len=1):: '-'] + ! reading the file into memory can be a problem when the files are large, and this routine currently reads stdin + ! until an end-of-file while writing it to a scratch file first, which can be slow and use file space resources + ! can change it to process the file in a buffered mannner so reading from stdin is performed more efficiently + call filebyte(infiles(1),text) ! allocate character array and copy file into it and pad with two characters at end + if(.not.allocated(text))then + stop '*base64* text not allocated' + endif + ! non-advancing I/O is not stream I/O so this could hit a line length limit + select case(decode) + case(.false.) + write(*,fmt='(*(a))',advance='no')encode_base64(text,width=wrap) + case default + write(*,fmt='(*(a))',advance='no')decode_base64(text,ignore_garbage=ignore_garbage) + end select +contains +subroutine setup() +help_text=[ CHARACTER(LEN=128) :: & +'NAME',& +' b64-(1f) - [FUNIX:FILESYSTEM] encode/data specified file to stdout',& +' using base64 encoding as defined in RFC-4648 ',& +' (LICENSE:MIT) ',& +' ',& +'SYNOPSIS ',& +' b64- [[ --decode] [ --ignore-garbage]]|[ --wrap COLS] [FILE] ',& +' |[ --help|--version] ',& +' ',& +'DESCRIPTION ',& +' b64(1f) encodes or decodes a file as described for the ',& +' b64alphabet-encoding in RFC 4648. When decoding, whitespace characters',& +' on input are ignored. ',& +' ',& +' b64(1f) takes stdin or one filename on the command line and encodes ',& +' or decodes it onto standard output. ',& +' ',& +' With no FILE, or when FILE is "-", read standard input. ',& +' ',& +' To ignore all bytes not in the formal base64 alphabet, use ',& +' --ignore-garbage. This option will attempt to recover from any other ',& +' non-alphabet bytes in the encoded stream. ',& +' ',& +'OPTIONS ',& +' ',& +' filename name of file to encode ',& +' --decode,-d decode instead of encode data ',& +' --ignore-garbage,i when decoding, ignore non-alphabet characters ',& +' --wrap=COLS,-w COLS wrap encoded lines after COLS characters ',& +' (default 76). Use 0 to disable line wrapping ',& +' --version,-v Print version information on standard output then',& +' exit successfully. ',& +' --help,-h Print usage information on standard output then ',& +' exit successfully. ',& +'EXAMPLE ',& +' Sample commands ',& +' ',& +' b64 input > output.b64 ',& +' ',& +'SEE ALSO ',& +' base64(1), uuencode(1), uudecode(1) ',& +''] +version_text=[ CHARACTER(LEN=128) :: & +'PRODUCT: GPF (General Purpose Fortran) utilities and examples',& +'PROGRAM: b64(1f) ',& +'DESCRIPTION: encode a file to the base 64 encoding standard defined in RFC-4648',& +'VERSION: 1.0, 2024-11-11 ',& +'AUTHOR: John S. Urban ',& +'LICENSE: MIT ',& +''] +end subroutine setup + +end program demo_base64 diff --git a/app/b64.ff b/app/b64.ff new file mode 100644 index 00000000..7bfdca93 --- /dev/null +++ b/app/b64.ff @@ -0,0 +1,102 @@ +program demo_base64 +use M_io, only : filebyte, putchar +use M_strings, only : encode_base64, decode_base64 +use M_CLI2, only : set_args, iget, lget, infiles=>unnamed +! encode data to base64 encryption as defined by RFC-4648 and print to standard output +! usage: base64 inputfile > outputfile +! currently stdin and stdout cannot be defined as streams, so stdin should +! be restricted to ASCII files with a newline terminator at end, and stdout is +! potentially subject to linelength limits of the platform. +! reading input into memory could be expensive if the file is large +use,intrinsic :: iso_fortran_env, only : int8, int32, stderr=>ERROR_UNIT, stdout=>OUTPUT_UNIT +implicit none +integer(kind=int32) :: i, j, column, sz, pad, iostat +character(len=1),allocatable :: text(:) ! array to hold file in memory +character(len=1) :: chunk(4) +character(len=1) :: tri(3) +character(len=1),allocatable :: trilast(:) +integer :: wrap +character(len=*),parameter :: rfc4648_alphabet='ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' +integer,parameter :: rfc4648_linelength=76 +character(len=1),parameter :: rfc4648_padding='=' +character(len=:),allocatable :: help_text(:), version_text(:) +logical :: decode +logical :: ignore_garbage + call setup() + call set_args('--wrap:w 76 --decode:d F --ignore-garbage:i F',help_text,version_text) + wrap=iget('wrap') + ignore_garbage=lget('ignore-garbage') + decode=lget('decode') + if(size(infiles).eq.0)infiles=[character(len=1):: '-'] + ! reading the file into memory can be a problem when the files are large, and this routine currently reads stdin + ! until an end-of-file while writing it to a scratch file first, which can be slow and use file space resources + ! can change it to process the file in a buffered mannner so reading from stdin is performed more efficiently + call filebyte(infiles(1),text) ! allocate character array and copy file into it and pad with two characters at end + if(.not.allocated(text))then + stop '*base64* text not allocated' + endif + ! non-advancing I/O is not stream I/O so this could hit a line length limit + select case(decode) + case(.false.) + write(*,fmt='(*(a))',advance='no')encode_base64(text,width=wrap) + case default + write(*,fmt='(*(a))',advance='no')decode_base64(text,ignore_garbage=ignore_garbage) + end select +contains +subroutine setup() +$!@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ +$BLOCK VARIABLE --varname help_text --file b64-.1.man +NAME + b64-(1f) - [FUNIX:FILESYSTEM] encode/data specified file to stdout + using base64 encoding as defined in RFC-4648 + (LICENSE:MIT) + +SYNOPSIS + b64- [[ --decode] [ --ignore-garbage]]|[ --wrap COLS] [FILE] + |[ --help|--version] + +DESCRIPTION + b64(1f) encodes or decodes a file as described for the + b64alphabet-encoding in RFC 4648. When decoding, whitespace characters + on input are ignored. + + b64(1f) takes stdin or one filename on the command line and encodes + or decodes it onto standard output. + + With no FILE, or when FILE is "-", read standard input. + + To ignore all bytes not in the formal base64 alphabet, use + --ignore-garbage. This option will attempt to recover from any other + non-alphabet bytes in the encoded stream. + +OPTIONS + + filename name of file to encode + --decode,-d decode instead of encode data + --ignore-garbage,i when decoding, ignore non-alphabet characters + --wrap=COLS,-w COLS wrap encoded lines after COLS characters + (default 76). Use 0 to disable line wrapping + --version,-v Print version information on standard output then + exit successfully. + --help,-h Print usage information on standard output then + exit successfully. +EXAMPLE + Sample commands + + b64 input > output.b64 + +SEE ALSO + base64(1), uuencode(1), uudecode(1) +$!@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ +$BLOCK VARIABLE --varname version_text +PRODUCT: GPF (General Purpose Fortran) utilities and examples +PROGRAM: b64(1f) +DESCRIPTION: encode a file to the base 64 encoding standard defined in RFC-4648 +VERSION: 1.0, 2024-11-11 +AUTHOR: John S. Urban +LICENSE: MIT +$BLOCK END +$!@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ +end subroutine setup + +end program demo_base64 diff --git a/bench/test_atoi.f90 b/bench/test_atoi.f90 old mode 100755 new mode 100644 diff --git a/bench/time_atoi.f90 b/bench/time_atoi.f90 old mode 100755 new mode 100644 diff --git a/bench/time_ator.f90 b/bench/time_ator.f90 old mode 100755 new mode 100644 diff --git a/docs/BOOK_M_strings.html b/docs/BOOK_M_strings.html old mode 100644 new mode 100755 index 39815709..c2113c32 --- a/docs/BOOK_M_strings.html +++ b/docs/BOOK_M_strings.html @@ -4,7 +4,7 @@ - + -
-
-
-


Manual Reference Pages  - M_strings__oop (3m_strings)

-
- - -

NAME

- -
-
-M_strings__oop(3f) - [M_strings::INTRO::OOPS] OOP Fortran string module -

-

-

CONTENTS

-
-Synopsis
-Description
-See Also
-Examples
-Author
-License
-
- - -

SYNOPSIS

- -
-
-use M_strings__oop -
- - -

DESCRIPTION

- -
-
-The M_strings(3fm) module is a collection of Fortran procedures -that supplement the built-in intrinsic string routines. Routines -for parsing, tokenizing, changing case, substituting new strings for -substrings, locating strings with simple wildcard expressions, removing -tabs and line terminators and other string manipulations are included. -

-M_strings__oop(3fm) is a companion module that provides an OOP interface -to the M_strings module. -

- - -

SEE ALSO

- -
-
-There are additional routines in other GPF modules for working with -expressions (M_calculator), time strings (M_time), random strings -(M_random, M_uuid), lists (M_list), and interfacing with the C regular -expression library (M_regex). -
- - -

EXAMPLES

- -
-
-Each of the procedural functions in M_strings(3fm) includes an example -program in the corresponding man(1) page for the function. The -object-oriented interface does not have individual man(1) pages, -but is instead demonstrated using the following example program: -

-

-    program demo_M_strings__oop
-    !
-    ! This is an example using the object-oriented class/type model
-    ! defined in M_strings__oop
-    !
-    ! This is essentially the same functionality as the procedures
-    ! combined with several Fortran intrinsics and overloaded operators
-    !
-    use M_strings__oop,only : string, p
-    implicit none
-    TYPE(string) :: str1, str2, str3, str4
-

- write(*,*)’Call methods of type(STRING)’ -

- ! define TYPE(STRING) with constructor - str2=string(’ This is a String! ’) - str4=string(’ a String ’) -

- write(*,101)’str2%str is ................ ’, & - & str2%str ! print string member of type - write(*,202)’len ........................ ’, & - & str2%len() ! same as intrinsic LEN() - write(*,202)’len_trim ................... ’, & - & str2%len_trim() ! same as intrinsic LEN_TRIM() - write(*,202)’index("is")................. ’, & - & str2%index("is") ! same as intrinsic INDEX() - write(*,202)’index("is",back=.T.) ....... ’, & - & str2%index("is",back=.TRUE.) ! same as intrinsic INDEX() - write(*,101)’upper ...................... ’, & - & p(str2%upper()) ! call upper() - write(*,101)’lower ...................... ’, & - & p(str2%lower()) ! call lower() - write(*,101)’reverse .................... ’, & - & p(str2%reverse()) ! call reverse() - write(*,101)’adjustl .................... ’, & - & p(str2%adjustl()) ! same as intrinsic ADJUSTL() - write(*,101)’adjustr .................... ’, & - & p(str2%adjustr()) ! same as intrinsic ADJUSTR() - write(*,101)’adjustc .................... ’, & - & p(str2%adjustc()) ! center string in current string length - write(*,101)’adjustc(40) ................ ’, & - & p(str2%adjustc(40)) ! center string in string length of NN - write(*,101)’lenset(40) ................. ’, & - & p(str2%lenset(40)) ! call pad() to force minimal string length - write(*,101)’trim ....................... ’, & - & p(str2%trim()) ! same as intrinsic TRIM() - write(*,101)’crop ....................... ’, & - & p(str2%crop()) ! trim leading and trailing spaces - write(*,101)’substitute("This","Here") .. ’, & - & p(str2%substitute("This","Here")) ! call SUBSTITUTE() - write(*,101)’compact .................... ’, & - & p(str2%compact()) ! call COMPACT() - write(*,101)’compact("") ................ ’, & - & p(str2%compact("")) - write(*,101)’compact(":") ............... ’, & - & p(str2%compact(":")) - ! calls M_strings procedure TRANSLITERATE() - write(*,101)’transliterate("aei","VWX") . ’, & - & p(str2%transliterate("aei","VWX")) - write(*,101)’transliterate("aeiou"," ") . ’, & - & p(str2%transliterate("aeiou"," ")) - write(*,101)’transliterate("aeiou","") .. ’, & - & p(str2%transliterate("aeiou","")) - write(*,101)’transliterate(" aeiou","") . ’, & - & p(str2%transliterate(" aeiou","")) - write(*,404)’chars .................... . ’, & - & str4%chars() ! call SWITCH() -

- str2%str=’\t\tSome tabs\t x\bX ’ - write(*,101)’str2%str ................... ’,str2%str - write(*,101)’expand ..................... ’, & - & p(str2%expand()) - str2=str2%expand() - write(*,101)’notabs ..................... ’, & - & p(str2%notabs()) ! calls NOTABS() - write(*,101)’noesc ...................... ’, & - & p(str2%noesc()) ! calls NOESC() -

- write(*,*)repeat(’=’,68) - write(*,*)’Casting to numeric variables’ - str3=string(’ 12.345678901234567e1 ’) - write(*,101)’str3%str ................... ’,str3%str - ! calls to M_strings procedure STRING_TO_VALUE() - write(*,*)’int ....................... ’, str3%int() - write(*,*)’nint ....................... ’, str3%nint() - write(*,*)’real ....................... ’, str3%real() - write(*,*)’dble ....................... ’, str3%dble() -

- write(*,*)repeat(’=’,68) - write(*,*)’Matching simple globbing patterns’ - str3=string(’ 12.345678901234567e1 ’) - str3=string(’Four score and seven years ago’) - write(*,101)’str3%str ................... ’,str3%str - ! %match calls M_strings procedure GLOB - write(*,*)’match("Fo*") ............... ’, str3%match("Fo*") - write(*,*)’match("and") ............... ’, str3%match("and") - write(*,*)’match("*and*") ............. ’, str3%match("*and*") -

- 101 format(1x,a,"[",a,"]") - 202 format(1x,a,i0) - 303 format(1x,*(l3)) - 404 format(1x,a,*("[",a1,"]":)) -

- write(*,*)repeat(’=’,68) - write(*,*)’OVERLOADED OPERATORS (add and subtract,return TYPE(STRING))’ - str1%str=’123.456’ - str2%str=’AaBbCcDdEeFfGgHhIi AaBbCcDdEeFfGgHhIi’ - write(*,101)’str1%str ................... ’,str1%str - write(*,101)’str2%str ................... ’,str2%str - write(*,*)’str1 + str2 ................ ’,p(str1 + str2) - ! a string that looks like a numeric value can have a value added - write(*,*)’str1 + 20000 ............... ’,p(str1 +20000) - write(*,*)’str1 - 20.0 ................ ’,p(str1 -20.0) - write(*,*)’str2 - "Aa" (removes ALL) .. ’,p(str2 - ’Aa’) -

- write(*,*)repeat(’=’,68) - write(*,*)’OVERLOADED OPERATORS (multiply,return TYPE(STRING))’ - str1%str=’AaBbCcDdEeFfGgHhIi’ - write(*,101)’str1%str ................... ’,str1%str - write(*,*)’str1 * 2 ................... ’,p(str1 * 2) -

- write(*,*)repeat(’=’,68) - write(*,*)’OVERLOADED OPERATORS (//,return TYPE(STRING))’ - str1%str=’String one:’ - str2%str=’String two:’ - write(*,101)’str1%str ................... ’,str1%str - write(*,101)’str2%str ................... ’,str2%str - write(*,*)’str1 // str2 ................ ’,p(str1 // str2) - ! numeric values are converted to strings - write(*,*)’str1 // 20000 ............... ’,p(str1 // 20000) - write(*,*)’str1 // 20.0 ................ ’,p(str1 // 20.0) -

- write(*,*)repeat(’=’,68) - write(*,*)’OVERLOADED OPERATORS (logical comparisons,return logical)’ - ! NOTE: comparisons are performed on the character variable members - ! of the type(string) - str1%str=’abcdefghij’ - str2%str=’klmnopqrst’ - write(*,101)’str1%str ................... ’,str1%str - write(*,101)’str2%str ................... ’,str2%str - write(*,*)’: EQ LT GT LE GE NE’ - write(*,*)’compare str1 to str1’ - write(*,303)str1 == str1 ,str1 < str1 ,str1 > str1 ,str1 <= str1 & - & ,str1 >= str1 ,str1 /= str1 - write(*,*)’compare str1 to str2’ - write(*,303)str1 == str2 ,str1 < str2 ,str1 > str2 ,str1 <= str2 & - & ,str1 >= str2 ,str1 /= str2 - write(*,*)’compare str2 to str1’ - write(*,303)str2 == str1 ,str2 < str1 ,str2 > str1 ,str2 <= str1 & - & ,str2 >= str1 ,str2 /= str1 -

- write(*,*)repeat(’=’,68) -

- end program demo_M_strings__oop -

-

-Expected output -

-

-  exercise the M_STRING_OOP module interface
-  ===================================================================
-  Call methods of type(STRING)
-  ===================================================================
-  str2%str is ................ [   This  is  a  String!             ]
-  len ........................ 36
-  len_trim ................... 23
-  index("is")................. 6
-  index("is",back=.T.) ....... 10
-  upper ...................... [   THIS  IS  A  STRING!             ]
-  lower ...................... [   this  is  a  string!             ]
-  reverse .................... [             !gnirtS  a  si  sihT   ]
-  adjustl .................... [This  is  a  String!                ]
-  adjustr .................... [                This  is  a  String!]
-  adjustc .................... [        This  is  a  String!        ]
-  adjustc(40) ................ [              This  is  a  String!      ]
-  lenset(40) ................. [   This  is  a  String!                 ]
-  trim ....................... [   This  is  a  String!]
-  crop ....................... [This  is  a  String!]
-  substitute("This","Here") .. [   Here  is  a  String!             ]
-  compact .................... [This is a String!]
-  compact("") ................ [ThisisaString!]
-  compact(":") ............... [This:is:a:String!]
-  transliterate("aei","VWX") . [   ThXs  Xs  V  StrXng!             ]
-  transliterate("aeiou"," ") . [   Th s   s     Str ng!             ]
-  transliterate("aeiou","") .. [   Ths  s    Strng!                 ]
-  transliterate(" aeiou","") . [ThssStrng!                          ]
-  chars .................... . [ ][a][ ][s][t][r][i][n][g][ ]
-  ===================================================================
-  str2%str ................... [\t\tSome tabs\t   x\bX ]
-  expand ..................... [         Some tabs          x   X]
-  notabs ..................... [                Some tabs          x    X]
-  noesc ...................... [  Some tabs    x X]
-  ===================================================================
-  Casting to numeric variables
-  str3%str ................... [   12.345678901234567e1        ]
-  int  .......................          123
-  real .......................    123.456787
-  dble .......................    123.45678901234567
-  ===================================================================
-  Matching simple globbing patterns
-  str3%str ................... [Four score and seven years ago]
-  match("Fo*") ...............  T
-  match("and") ...............  F
-  match("*and*") .............  T
-  ====================================================================
-  OVERLOADED OPERATORS (add and subtract, return TYPE(STRING))
-  str1%str .................. [123.456]
-  str2%str .................. [AaBbCcDdEeFfGgHhIi AaBbCcDdEeFfGgHhIi]
-  str1 + str2 ............... 123.456 AaBbCcDdEeFfGgHhIi AaBbCcDdEeFfGgHhIi
-  str1 + 20000 .............. 20123.455999999998
-  str1 - 20.0 ............... -103.456
-  str2 - "Aa" (removes ALL) . BbCcDdEeFfGgHhIi BbCcDdEeFfGgHhIi
-  ===================================================================
-  OVERLOADED OPERATORS (multiply, return TYPE(STRING))
-  str1%str ................... [AaBbCcDdEeFfGgHhIi]
-  str1 * 2 ................... AaBbCcDdEeFfGgHhIiAaBbCcDdEeFfGgHhIi
-  ===================================================================
-  OVERLOADED OPERATORS (//, return TYPE(STRING))
-  str1%str ................... [String one:]
-  str2%str ................... [String two:]
-  str1 // str2 ............... String one:String two:
-  str1 // 20000 .............. String one:20000
-  str1 // 20.0 ............... String one:20.0
-  ===================================================================
-  OVERLOADED OPERATORS (logical comparisons, return logical)
-  str1%str ................... [abcdefghij]
-  str2%str ................... [klmnopqrst]
-  : EQ LT GT LE GE NE
-  compare str1 to str1
-  :  T  F  F  T  T  F
-  compare str1 to str2
-  :  F  T  F  T  F  T
-  compare str2 to str1
-  :  F  F  T  F  T  T
-  ===================================================================
-

-

-
- - -

AUTHOR

- -
-
-John S. Urban -
- - -

LICENSE

- -
-
-Public Domain -
-


-
Nemo Release 3.1 M_strings__oop (3m_strings) August 29, 2024
Generated by manServer 1.08 from 9f8af069-41bb-4251-8ae2-62664dd77ab9 using man macros. -

-
-
- - diff --git a/docs/M_strings__oop.3m_strings__oop.html b/docs/M_strings__oop.3m_strings__oop.html index e9598c8c..07dff8ee 100644 --- a/docs/M_strings__oop.3m_strings__oop.html +++ b/docs/M_strings__oop.3m_strings__oop.html @@ -369,7 +369,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 M_strings__oop (3m_strings__oop) September 21, 2024
Generated by manServer 1.08 from 18a52a96-0b3e-4123-a52f-9cf2f22cab37 using man macros. +
Nemo Release 3.1 M_strings__oop (3m_strings__oop) January 10, 2025
Generated by manServer 1.08 from 32957f35-72a6-44c2-8f56-25124ce0a80c using man macros.

diff --git a/docs/M_strings__oop.js b/docs/M_strings__oop.js old mode 100644 new mode 100755 diff --git a/docs/M_strings__oop_slidy.html b/docs/M_strings__oop_slidy.html old mode 100755 new mode 100644 diff --git a/docs/M_strings_slidy.html b/docs/M_strings_slidy.html old mode 100755 new mode 100644 diff --git a/docs/STATUS.md b/docs/STATUS.md old mode 100644 new mode 100755 diff --git a/docs/adjustc.3m_strings.html b/docs/adjustc.3m_strings.html old mode 100644 new mode 100755 index a2754e2a..cd29ce0d --- a/docs/adjustc.3m_strings.html +++ b/docs/adjustc.3m_strings.html @@ -176,7 +176,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 adjustc (3m_strings) September 21, 2024
Generated by manServer 1.08 from e2544fbe-dfd5-4e89-a4af-582535c4d8e9 using man macros. +
Nemo Release 3.1 adjustc (3m_strings) January 10, 2025
Generated by manServer 1.08 from c96e66e4-1904-4420-9567-9567cf2e393a using man macros.

diff --git a/docs/atoi.3m_strings.html b/docs/atoi.3m_strings.html new file mode 100644 index 00000000..d93f8b7d --- /dev/null +++ b/docs/atoi.3m_strings.html @@ -0,0 +1,188 @@ + + + + + + + +
+
+
+


Manual Reference Pages  - atoi (3m_strings)

+
+ + +

NAME

+ +
+
+atoi(3f) - [M_strings:TYPE] function returns a 32-bit +integer value from a string +(LICENSE:PD) +

+

+

CONTENTS

+
+Synopsis
+Description
+Options
+Returns
+Examples
+Author
+License
+
+ + +

SYNOPSIS

+ +
+
+pure elemental function atoi (string) result(val) +

+

+    character(len=*),intent(in)      :: string
+    integer(kind=int32),intent(out)  :: val
+

+

+
+ + +

DESCRIPTION

+ +
+
+function atoi(3f) converts a string representing an integer value +to a numeric 32-bit integer value. +
+ + +

OPTIONS

+ +
+
+ + +
+str +holds string assumed to represent a numeric integer value +
+ + +

RETURNS

+ +
+
+ + +
+val +returned INTEGER. +
+ + +

EXAMPLES

+ +
+
+Sample Program: +

+

+     program demo_atoi
+

+ use iso_fortran_env, only: wp => int32 + use M_strings, only: atoi + implicit none + character(len=14),allocatable :: strings(:) + integer(kind=wp) :: iv + integer :: i +

+ ! different strings representing whole numbers + strings=[& + &’+10 ’,& + &’ -3 ’,& + &’ ’,& ! Note: will return zero without an error message + &’1 2 1 2 1 . 0 ’,& ! Note: will just read first value + &’WHAT? ’] ! Note: will return zero without an error message +

+ do i=1,size(strings) + iv=atoi(strings(i)) + write(*,’(*(g0,1x))’)’STRING:’,strings(i),’:VALUE:’,iv + enddo +

+ end program demo_atoi +

+

+Results: +

+

+ > STRING: +10            :VALUE: 10
+ > STRING:     -3         :VALUE: -3
+ > STRING:                :VALUE: 0
+ > STRING: 1 2 1 2 1 . 0  :VALUE: 1
+ > STRING: WHAT?          :VALUE: 0
+

+

+
+ + +

AUTHOR

+ +
+
+John S. Urban +
+ + +

LICENSE

+ +
+
+Public Domain +
+


+
Nemo Release 3.1 atoi (3m_strings) January 10, 2025
Generated by manServer 1.08 from b0731e12-614f-4dc6-acd3-a9f3cade15b3 using man macros. +

+
+
+ + diff --git a/docs/atol.3m_strings.html b/docs/atol.3m_strings.html new file mode 100644 index 00000000..5d26b763 --- /dev/null +++ b/docs/atol.3m_strings.html @@ -0,0 +1,188 @@ + + + + + + + +
+
+
+


Manual Reference Pages  - atol (3m_strings)

+
+ + +

NAME

+ +
+
+atol(3f) - [M_strings:TYPE] function returns a 64-bit +integer value from a string +(LICENSE:PD) +

+

+

CONTENTS

+
+Synopsis
+Description
+Options
+Returns
+Examples
+Author
+License
+
+ + +

SYNOPSIS

+ +
+
+pure elemental function atol (string) result(val) +

+

+    character(len=*),intent(in)      :: string
+    integer(kind=int64),intent(out)  :: val
+

+

+
+ + +

DESCRIPTION

+ +
+
+function atol(3f) converts a string representing an integer value +to a numeric 64-bit integer value. +
+ + +

OPTIONS

+ +
+
+ + +
+str +holds string assumed to represent a numeric integer value +
+ + +

RETURNS

+ +
+
+ + +
+val +returned INTEGER. +
+ + +

EXAMPLES

+ +
+
+Sample Program: +

+

+     program demo_atol
+

+ use iso_fortran_env, only: wp => int64 + use M_strings, only: atol + implicit none + character(len=14),allocatable :: strings(:) + integer(kind=wp) :: iv + integer :: i +

+ ! different strings representing whole numbers + strings=[& + &’+10 ’,& + &’ -3 ’,& + &’ ’,& ! Note: will return zero without an error message + &’1 2 1 2 1 . 0 ’,& ! Note: will just read first value + &’WHAT? ’] ! Note: will return zero without an error message +

+ do i=1,size(strings) + iv=atol(strings(i)) + write(*,’(*(g0,1x))’)’STRING:’,strings(i),’:VALUE:’,iv + enddo +

+ end program demo_atol +

+

+Results: +

+

+ > STRING: +10            :VALUE: 10
+ > STRING:     -3         :VALUE: -3
+ > STRING:                :VALUE: 0
+ > STRING: 1 2 1 2 1 . 0  :VALUE: 1
+ > STRING: WHAT?          :VALUE: 0
+

+

+
+ + +

AUTHOR

+ +
+
+John S. Urban +
+ + +

LICENSE

+ +
+
+Public Domain +
+


+
Nemo Release 3.1 atol (3m_strings) January 10, 2025
Generated by manServer 1.08 from d6fd5667-c5d3-4df5-9794-96a065e252e6 using man macros. +

+
+
+ + diff --git a/docs/aton.3m_strings.html b/docs/aton.3m_strings.html old mode 100755 new mode 100644 index 06ac5d3e..3e1f5aa9 --- a/docs/aton.3m_strings.html +++ b/docs/aton.3m_strings.html @@ -167,7 +167,6 @@

EXAMPLES

end program demo_aton

-

@@ -187,7 +186,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 aton (3m_strings) September 21, 2024
Generated by
manServer 1.08 from 3604d1b1-53cc-472a-8566-386e5567f6f5 using man macros. +
Nemo Release 3.1 aton (3m_strings) January 10, 2025
Generated by manServer 1.08 from 6b2a0548-366a-410e-8f32-40817425a19f using man macros.

diff --git a/docs/base.3m_strings.html b/docs/base.3m_strings.html old mode 100644 new mode 100755 index e437a16b..e8d49236 --- a/docs/base.3m_strings.html +++ b/docs/base.3m_strings.html @@ -197,7 +197,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 base (3m_strings) September 21, 2024
Generated by manServer 1.08 from 090add50-bd56-4b10-914a-4eef89ce82b7 using man macros. +
Nemo Release 3.1 base (3m_strings) January 10, 2025
Generated by manServer 1.08 from a586889e-f08c-4b45-a078-248ff9de38f3 using man macros.

diff --git a/docs/base2.3m_strings.html b/docs/base2.3m_strings.html old mode 100644 new mode 100755 index 5c53ba00..029939b0 --- a/docs/base2.3m_strings.html +++ b/docs/base2.3m_strings.html @@ -169,7 +169,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 base2 (3m_strings) September 21, 2024
Generated by manServer 1.08 from 5186b6ac-957b-4571-bf67-7f5ed8ade41d using man macros. +
Nemo Release 3.1 base2 (3m_strings) January 10, 2025
Generated by manServer 1.08 from eb400912-7e9f-48ff-8542-2f1a1662f748 using man macros.

diff --git a/docs/bundle.3m_strings.html b/docs/bundle.3m_strings.html old mode 100755 new mode 100644 index ed6e1c02..46ce1ec2 --- a/docs/bundle.3m_strings.html +++ b/docs/bundle.3m_strings.html @@ -131,21 +131,31 @@

EXAMPLES

program demo_bundle use M_strings, only: bundle implicit none - print "(*(’""’,a,’""’:,’,’,1x))", bundle("one") - print "(*(’""’,a,’""’:,’,’,1x))", bundle("one","two") - print "(*(’""’,a,’""’:,’,’,1x))", bundle("one","two","three") - print "(*(’""’,a,’""’:,’,’,1x))", bundle("one","two","three",& - & "four","five","six","seven") + character(len=*),parameter :: fmt= "(*(’""’,a,’""’:,’,’,1x))" + character(len=:),allocatable :: array(:) + print fmt, bundle("one") + print fmt, bundle("one","two") + print fmt, bundle("one","two","three") + array=bundle("one","two","three","four","five","six","seven") + write(*,’(*(g0))’)’size=’,size(array),’,len=’,len(array) + write(*,’("[",a,"]")’)array end program demo_bundle

-Expected output +Results:

-   "one"
-   "one", "two"
-   "one  ", "two  ", "three"
-   "one  ", "two  ", "three", "four ", "five ", "six  ", "seven"
+ > "one"
+ > "one", "two"
+ > "one  ", "two  ", "three"
+ > size=7,len=5
+ > [one  ]
+ > [two  ]
+ > [three]
+ > [four ]
+ > [five ]
+ > [six  ]
+ > [seven]
 

@@ -166,7 +176,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 bundle (3m_strings) September 21, 2024
Generated by manServer 1.08 from 457cf56b-2c5e-4d59-b724-a1ec6d493425 using man macros. +
Nemo Release 3.1 bundle (3m_strings) January 10, 2025
Generated by manServer 1.08 from 1782874d-e10b-430c-817e-484df7279094 using man macros.

diff --git a/docs/c2s.3m_strings.html b/docs/c2s.3m_strings.html old mode 100644 new mode 100755 index 9729256a..d57405a4 --- a/docs/c2s.3m_strings.html +++ b/docs/c2s.3m_strings.html @@ -143,7 +143,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 c2s (3m_strings) September 21, 2024
Generated by manServer 1.08 from 89b4d81f-bf79-42dd-a282-c04b7046af54 using man macros. +
Nemo Release 3.1 c2s (3m_strings) January 10, 2025
Generated by manServer 1.08 from dcf83b3a-cc4d-4c11-a086-cfe103972a18 using man macros.

diff --git a/docs/change.3m_strings.html b/docs/change.3m_strings.html old mode 100644 new mode 100755 index 5591ea14..689c6058 --- a/docs/change.3m_strings.html +++ b/docs/change.3m_strings.html @@ -199,7 +199,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 change (3m_strings) September 21, 2024
Generated by manServer 1.08 from c8b85559-f361-4c80-9381-7a84e8e24500 using man macros. +
Nemo Release 3.1 change (3m_strings) January 10, 2025
Generated by manServer 1.08 from d722e02d-83df-451e-be12-73d2a0a38bfb using man macros.

diff --git a/docs/chomp.3m_strings.html b/docs/chomp.3m_strings.html old mode 100644 new mode 100755 index 1af4584b..92aa98cd --- a/docs/chomp.3m_strings.html +++ b/docs/chomp.3m_strings.html @@ -205,7 +205,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 chomp (3m_strings) September 21, 2024
Generated by manServer 1.08 from 54bd8a8f-a08d-46a5-b76e-97a6e6d52197 using man macros. +
Nemo Release 3.1 chomp (3m_strings) January 10, 2025
Generated by manServer 1.08 from 207ab2e5-e3de-4cdb-8a25-a718af35a0a4 using man macros.

diff --git a/docs/clip.3m_strings.html b/docs/clip.3m_strings.html old mode 100644 new mode 100755 index 51a2e3e2..8585ac34 --- a/docs/clip.3m_strings.html +++ b/docs/clip.3m_strings.html @@ -175,7 +175,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 clip (3m_strings) September 21, 2024
Generated by manServer 1.08 from 472584ce-6fb0-4b42-b746-776da466d935 using man macros. +
Nemo Release 3.1 clip (3m_strings) January 10, 2025
Generated by manServer 1.08 from 64851525-767c-468d-9cdd-8930bc05ce75 using man macros.

diff --git a/docs/codebase.3m_strings.html b/docs/codebase.3m_strings.html old mode 100644 new mode 100755 index 3500f9ae..cc1c0f4c --- a/docs/codebase.3m_strings.html +++ b/docs/codebase.3m_strings.html @@ -183,7 +183,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 codebase (3m_strings) September 21, 2024
Generated by manServer 1.08 from f99bd1d9-4177-429a-9482-b2a3520dfa5b using man macros. +
Nemo Release 3.1 codebase (3m_strings) January 10, 2025
Generated by manServer 1.08 from dfdd0382-d8d6-4d8f-bbff-de001d0aac51 using man macros.

diff --git a/docs/compact.3m_strings.html b/docs/compact.3m_strings.html old mode 100644 new mode 100755 index 59c19f9d..79081c88 --- a/docs/compact.3m_strings.html +++ b/docs/compact.3m_strings.html @@ -180,7 +180,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 compact (3m_strings) September 21, 2024
Generated by manServer 1.08 from 774f81bc-f439-4ed2-9d5d-45d8d955b2ed using man macros. +
Nemo Release 3.1 compact (3m_strings) January 10, 2025
Generated by manServer 1.08 from 92aae8f8-c016-448d-9297-78a522ef3597 using man macros.

diff --git a/docs/cpad.3m_strings.html b/docs/cpad.3m_strings.html old mode 100755 new mode 100644 index e845eb46..24e4c41d --- a/docs/cpad.3m_strings.html +++ b/docs/cpad.3m_strings.html @@ -150,7 +150,6 @@

EXAMPLES

write(*,’("[",a,"]")’) cpad( valuein=1.0/9.0 , length=20) end program demo_cpad

-

@@ -170,7 +169,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 cpad (3m_strings) September 21, 2024
Generated by
manServer 1.08 from df286de5-5540-470f-bf21-6abefdaf6c85 using man macros. +
Nemo Release 3.1 cpad (3m_strings) January 10, 2025
Generated by manServer 1.08 from 4d45a4db-f5d5-4e60-a4b2-5a97f4aaedf1 using man macros.

diff --git a/docs/crop.3m_strings.html b/docs/crop.3m_strings.html old mode 100644 new mode 100755 index d4fd6156..21fc472a --- a/docs/crop.3m_strings.html +++ b/docs/crop.3m_strings.html @@ -92,14 +92,11 @@

DESCRIPTION

- - -
-Tabs are expanded assuming a stop every eight characters.
  -All other +Tabs are expanded assuming a stop every eight characters. All other control characters throughout the string are replaced with spaces and leading and trailing spaces are trimmed from the resulting string. -
This means trailing characters like linefeed and carriage returns are +

+This means trailing characters like linefeed and carriage returns are removed. If this is not desired, see clip(3f).

@@ -145,11 +142,12 @@

EXAMPLES

end program demo_crop

-Expected output +Results:

-     untrimmed string=[   ABCDEFG abcdefg                      ]
-     cropped string=[ABCDEFG abcdefg]
+    >  untrimmed string=[   ABCDEFG abcdefg  ]
+    >  cropped string=[ABCDEFG abcdefg]
+

@@ -177,7 +175,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 crop (3m_strings) September 21, 2024
Generated by
manServer 1.08 from 10a93dd0-1980-4890-9c06-fe5a65b6cba5 using man macros. +
Nemo Release 3.1 crop (3m_strings) January 10, 2025
Generated by manServer 1.08 from 3da2e229-59d4-44f0-a178-7f209366ad39 using man macros.

diff --git a/docs/dble.3m_strings.html b/docs/dble.3m_strings.html old mode 100755 new mode 100644 index 6557c4ee..0bd6bfa1 --- a/docs/dble.3m_strings.html +++ b/docs/dble.3m_strings.html @@ -164,7 +164,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 dble (3m_strings) September 21, 2024
Generated by manServer 1.08 from e921bf4a-eb82-42fd-9dea-6884b42f2f72 using man macros. +
Nemo Release 3.1 dble (3m_strings) January 10, 2025
Generated by manServer 1.08 from 1fdde11e-db5d-4bf9-b5af-8e72514259f1 using man macros.

diff --git a/docs/decode_base64.3m_strings.html b/docs/decode_base64.3m_strings.html new file mode 100644 index 00000000..d9ace06a --- /dev/null +++ b/docs/decode_base64.3m_strings.html @@ -0,0 +1,202 @@ + + + + + + + +
+
+
+


Manual Reference Pages  - decode_base64 (3m_strings)

+
+ + +

NAME

+ +
+
+

+decode_base64-(3f) - [M_strings:ENCODE] decode data from base64 +encoding as defined in RFC-4648 +(LICENSE:MIT) +

+

+

CONTENTS

+
+Synopsis
+Description
+Options
+Output
+Example
+See Also
+
+ + +

SYNOPSIS

+ +
+
+function decode_base64(text,ignore_garbage) result(out) +

+

+     character(len=1),intent(in)  :: text(*)
+     logical,intent(in),optional  :: ignore_garbage
+     character(len=1),allocatable :: out(:)
+

+

+
+ + +

DESCRIPTION

+ +
+
+

+The data is deencoded as described for the base64-alphabet-encoding in +RFC 4648. +

+ + +

OPTIONS

+ +
+
+

+ + +
+IGNORE_GARBAGE
  +when decoding, ignore all characters not in the formal +base64 alphabet. This option will attempt to recover +from any other non-alphabet bytes in the encoded data. +

+ + +

OUTPUT

+ +
+
+

+ + +
+OUT +array of decoded characters +

+ + +

EXAMPLE

+ +
+
+Sample program: +

+

+   program demo_decode_base64
+   use,intrinsic :: iso_fortran_env, only : int8, int16, int32, int64
+   use M_strings, only : switch, encode_base64, decode_base64
+   implicit none
+   integer                      :: i
+   character(len=1),parameter   :: nl=new_line(’a’)
+   character(len=1),allocatable :: textin(:), textout(:)
+   character(len=*),parameter   :: data(*)=[ &
+   ’This is some sample data          ’,  &
+   ’To encode. Should make it long    ’,  &
+   ’enough to generate multiple lines ’,  &
+   ’of output so can check line wrap  ’,  &
+   ’functionality as well.            ’   &
+   ]
+   ! make a file-like byte stream by trimming lines and adding newlines
+      textin=[(switch(trim(data(i))),new_line(’a’),i=1,size(data))]
+      write(*,’(*(a))’)’input:’,nl,textin
+   !
+      textout=encode_base64(textin,width=50)
+      write(*,’(*(a))’)’result:’,nl, textout
+   !
+      write(*,’(*(a))’)’decode result:’,nl, decode_base64(textout)
+   !
+   end program demo_decode_base64
+

+

+Results: +

+

+    > input:
+    > This is some sample data
+    > To encode. Should make it long
+    > enough to generate multiple lines
+    > of output so can check line wrap
+    > functionality as well.
+    >
+    > result:
+    > VGhpcyBpcyBzb21lIHNhbXBsZSBkYXRhClRvIGVuY29kZS4gU2
+    > hvdWxkIG1ha2UgaXQgbG9uZwplbm91Z2ggdG8gZ2VuZXJhdGUg
+    > bXVsdGlwbGUgbGluZXMKb2Ygb3V0cHV0IHNvIGNhbiBjaGVjay
+    > BsaW5lIHdyYXAKZnVuY3Rpb25hbGl0eSBhcyB3ZWxsLgo=
+    >
+    > decode result:
+    > This is some sample data
+    > To encode. Should make it long
+    > enough to generate multiple lines
+    > of output so can check line wrap
+    > functionality as well.
+    >
+

+

+
+ + +

SEE ALSO

+ +
+
+encode_base64(3), base64(1), uuencode(1), uudecode(1) +
+


+
Nemo Release 3.1 decode_base64 (3m_strings) January 10, 2025
Generated by manServer 1.08 from 8699ca81-15dd-4858-89b1-9e0c75be6808 using man macros. +

+
+
+ + diff --git a/docs/decodebase.3m_strings.html b/docs/decodebase.3m_strings.html old mode 100644 new mode 100755 index 0238acf4..0f89cfa8 --- a/docs/decodebase.3m_strings.html +++ b/docs/decodebase.3m_strings.html @@ -204,7 +204,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 decodebase (3m_strings) September 21, 2024
Generated by manServer 1.08 from 274e0041-4a1c-407a-8d74-028a760e9cad using man macros. +
Nemo Release 3.1 decodebase (3m_strings) January 10, 2025
Generated by manServer 1.08 from cae2cdc3-e28a-4fb5-be39-98ec5f6d828f using man macros.

diff --git a/docs/delim.3m_strings.html b/docs/delim.3m_strings.html old mode 100644 new mode 100755 index bfc5b974..2ac687d4 --- a/docs/delim.3m_strings.html +++ b/docs/delim.3m_strings.html @@ -276,7 +276,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 delim (3m_strings) September 21, 2024
Generated by manServer 1.08 from 2dfe62d1-5277-4341-b00e-03f73b378593 using man macros. +
Nemo Release 3.1 delim (3m_strings) January 10, 2025
Generated by manServer 1.08 from 38fa9909-d4bb-452f-9cc4-9dfb98e069d3 using man macros.

diff --git a/docs/describe.3m_strings.html b/docs/describe.3m_strings.html old mode 100644 new mode 100755 index 1108ba6a..965e8d30 --- a/docs/describe.3m_strings.html +++ b/docs/describe.3m_strings.html @@ -262,7 +262,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 describe (3m_strings) September 21, 2024
Generated by manServer 1.08 from 9a1106d1-616f-44ed-970a-7cb0e08ae709 using man macros. +
Nemo Release 3.1 describe (3m_strings) January 10, 2025
Generated by manServer 1.08 from 54157ab4-e5d0-436b-8a69-e1f612203b50 using man macros.

diff --git a/docs/dilate.3m_strings.html b/docs/dilate.3m_strings.html old mode 100644 new mode 100755 index 16ae1e5f..415970fb --- a/docs/dilate.3m_strings.html +++ b/docs/dilate.3m_strings.html @@ -56,7 +56,7 @@

NAME

-dilate(3f) - [M_strings:NONALPHA] expand tab characters +dilate(3f) - [M_strings:NONALPHA] function to expand tab characters (LICENSE:PD)

@@ -92,7 +92,7 @@

DESCRIPTION

@@ -173,7 +173,7 @@

LICENSE

Public Domain


-
-dilate() converts tabs in INSTR to spaces in OUTSTR.
  +dilate(3) converts tabs in INSTR to spaces in OUTSTR.
  It assumes a tab is set every 8 characters. Trailing spaces are removed.
Nemo Release 3.1 dilate (3m_strings) September 21, 2024
Generated by manServer 1.08 from 5308e439-59b7-43ee-9f2e-1feb583dbcd9 using man macros. +
Nemo Release 3.1 dilate (3m_strings) January 10, 2025
Generated by manServer 1.08 from 71d5c2f9-3c4c-4dc6-9e46-6f6606846f39 using man macros.

diff --git a/docs/edit_distance.3m_strings.html b/docs/edit_distance.3m_strings.html old mode 100644 new mode 100755 index b58ca8f6..4aa55658 --- a/docs/edit_distance.3m_strings.html +++ b/docs/edit_distance.3m_strings.html @@ -136,7 +136,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 edit_distance (3m_strings) September 21, 2024
Generated by manServer 1.08 from 3791dfd3-41c1-45fc-9467-fd9f322338db using man macros. +
Nemo Release 3.1 edit_distance (3m_strings) January 10, 2025
Generated by manServer 1.08 from cea2e66b-7787-4963-bf34-8cd9ec56d11b using man macros.

diff --git a/docs/encode_base64.3m_strings.html b/docs/encode_base64.3m_strings.html new file mode 100644 index 00000000..8b18c452 --- /dev/null +++ b/docs/encode_base64.3m_strings.html @@ -0,0 +1,205 @@ + + + + + + + +
+
+
+


Manual Reference Pages  - encode_base64 (3m_strings)

+
+ + +

NAME

+ +
+
+

+encode_base64-(3f) - [M_strings:ENCODE] encode data using base64 +encoding as defined in RFC-4648 +(LICENSE:MIT) +

+

+

CONTENTS

+
+Synopsis
+Description
+Options
+Output
+Example
+See Also
+
+ + +

SYNOPSIS

+ +
+
+function encode_base64(text,width) result(out) +

+

+     character(len=1),intent(in) :: text(*)
+     integer,intent(in),optional :: width
+     character(len=1),allocatable :: out(:)
+

+

+
+ + +

DESCRIPTION

+ +
+
+

+The data is encoded as described for the base64-alphabet-encoding in +RFC 4648. +

+ + +

OPTIONS

+ +
+
+

+ + + +
+TEXT +Data to encode +
+WIDTH +wrap encoded lines after specified number of characters +(default 76). Use 0 to disable line wrapping +

+ + +

OUTPUT

+ +
+
+

+ + +
+OUT +array of encoded characters representing input text +

+ + +

EXAMPLE

+ +
+
+Sample program: +

+

+   program demo_encode_base64
+   use,intrinsic :: iso_fortran_env, only : int8, int16, int32, int64
+   use M_strings, only : switch, encode_base64, decode_base64
+   implicit none
+   integer                      :: i
+   character(len=1),parameter   :: nl=new_line(’a’)
+   character(len=1),allocatable :: textin(:), textout(:)
+   character(len=*),parameter   :: data(*)=[ &
+   ’This is some sample data          ’,  &
+   ’To encode. Should make it long    ’,  &
+   ’enough to generate multiple lines ’,  &
+   ’of output so can check line wrap  ’,  &
+   ’functionality as well.            ’   &
+   ]
+   ! make a file-like byte stream by trimming lines and adding newlines
+      textin=[(switch(trim(data(i))),new_line(’a’),i=1,size(data))]
+      write(*,’(*(a))’)’input:’,nl,textin
+   !
+      textout=encode_base64(textin,width=50)
+      write(*,’(*(a))’)’result:’,nl, textout
+   !
+      write(*,’(*(a))’)’decode result:’,nl, decode_base64(textout)
+   !
+   end program demo_encode_base64
+

+

+Results: +

+

+    > input:
+    > This is some sample data
+    > To encode. Should make it long
+    > enough to generate multiple lines
+    > of output so can check line wrap
+    > functionality as well.
+    >
+    > result:
+    > VGhpcyBpcyBzb21lIHNhbXBsZSBkYXRhClRvIGVuY29kZS4gU2
+    > hvdWxkIG1ha2UgaXQgbG9uZwplbm91Z2ggdG8gZ2VuZXJhdGUg
+    > bXVsdGlwbGUgbGluZXMKb2Ygb3V0cHV0IHNvIGNhbiBjaGVjay
+    > BsaW5lIHdyYXAKZnVuY3Rpb25hbGl0eSBhcyB3ZWxsLgo=
+    >
+    > decode result:
+    > This is some sample data
+    > To encode. Should make it long
+    > enough to generate multiple lines
+    > of output so can check line wrap
+    > functionality as well.
+    >
+

+

+
+ + +

SEE ALSO

+ +
+
+decode_base64(3), base64(1), uuencode(1), uudecode(1) +
+


+
Nemo Release 3.1 encode_base64 (3m_strings) January 10, 2025
Generated by manServer 1.08 from fa70ef89-827c-445a-b50c-5e39500f869b using man macros. +

+
+
+ + diff --git a/docs/ends_with.3m_strings.html b/docs/ends_with.3m_strings.html old mode 100644 new mode 100755 index 99d268d4..b3ef1ac2 --- a/docs/ends_with.3m_strings.html +++ b/docs/ends_with.3m_strings.html @@ -209,7 +209,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 ends_with (3m_strings) September 21, 2024
Generated by manServer 1.08 from a87c8509-9a01-41fb-af07-08e92ff908e3 using man macros. +
Nemo Release 3.1 ends_with (3m_strings) January 10, 2025
Generated by manServer 1.08 from 70adc0ec-8ce5-4b87-99da-0f8df8e30c80 using man macros.

diff --git a/docs/expand.3m_strings.html b/docs/expand.3m_strings.html old mode 100644 new mode 100755 index fd53ef38..5d2354b0 --- a/docs/expand.3m_strings.html +++ b/docs/expand.3m_strings.html @@ -89,7 +89,7 @@

DESCRIPTION

-EXPAND() expands sequences used to represent commonly used escape +EXPAND(3) expands sequences used to represent commonly used escape sequences or control characters. By default ...

Escape sequences @@ -168,7 +168,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 expand (3m_strings) September 21, 2024
Generated by manServer 1.08 from 55f0ff2a-5d2d-414d-be7d-5067c8654951 using man macros. +
Nemo Release 3.1 expand (3m_strings) January 10, 2025
Generated by manServer 1.08 from e4f46d4a-af0d-4e8f-bd24-9a37457b7bef using man macros.

diff --git a/docs/find_field.3m_strings.html b/docs/find_field.3m_strings.html old mode 100755 new mode 100644 index 39451958..fce0c6d6 --- a/docs/find_field.3m_strings.html +++ b/docs/find_field.3m_strings.html @@ -97,8 +97,8 @@

DESCRIPTION

Find a delimited field in a string.

-Here’s my equivalent, which I’ve used for nearly 2 decades, as you can -see from the date. This doesn’t try to mimic the C strtok (and doesn’t +Here is my equivalent, which I have used for nearly 2 decades, as you can +see from the date. This does not try to mimic the C strtok (and does not have its limitations either). It is in a much more native Fortran style.

It is a little more complicated than some because it does some things @@ -271,7 +271,7 @@

VERSION

Minor editing to conform to inclusion in the string procedure module


-
Nemo Release 3.1 find_field (3m_strings) September 21, 2024
Generated by manServer 1.08 from 888ad9d0-35a2-4a1d-a7f0-83e6ae9ef444 using man macros. +
Nemo Release 3.1 find_field (3m_strings) January 10, 2025
Generated by manServer 1.08 from 3e3fa14f-52d8-4b8f-b435-c6e3888ebb51 using man macros.

diff --git a/docs/fmt.3m_strings.html b/docs/fmt.3m_strings.html index 19b534e2..ff19d7e1 100644 --- a/docs/fmt.3m_strings.html +++ b/docs/fmt.3m_strings.html @@ -56,7 +56,7 @@

NAME

-fmt(3f) - [M_strings] convert any intrinsic to a string using specified format +fmt(3f) - [M_strings:TYPE] convert any intrinsic to a string using specified format (LICENSE:PD)

CONTENTS

@@ -177,7 +177,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 fmt (3m_strings) September 21, 2024
Generated by manServer 1.08 from 1fd90c1e-bef9-42f0-bb30-82ab4c717a73 using man macros. +
Nemo Release 3.1 fmt (3m_strings) January 10, 2025
Generated by manServer 1.08 from 741f0000-e96a-415f-b6c0-bb96cddfeb3e using man macros.

diff --git a/docs/fortran_name.3m_strings.html b/docs/fortran_name.3m_strings.html old mode 100644 new mode 100755 index 82fe9865..3767ddb9 --- a/docs/fortran_name.3m_strings.html +++ b/docs/fortran_name.3m_strings.html @@ -180,7 +180,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 fortran_name (3m_strings) September 21, 2024
Generated by manServer 1.08 from 700592e4-c5eb-45d4-8f8a-9e3eece816cc using man macros. +
Nemo Release 3.1 fortran_name (3m_strings) January 10, 2025
Generated by manServer 1.08 from bdd103ae-017d-4ebc-b048-2a5903b68f05 using man macros.

diff --git a/docs/fpm-ford/css/bootstrap.css b/docs/fpm-ford/css/bootstrap.css old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/css/bootstrap.min.css b/docs/fpm-ford/css/bootstrap.min.css old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/css/font-awesome.css b/docs/fpm-ford/css/font-awesome.css old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/css/font-awesome.min.css b/docs/fpm-ford/css/font-awesome.min.css old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/css/local.css b/docs/fpm-ford/css/local.css old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/css/pygments.css b/docs/fpm-ford/css/pygments.css old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/fonts/FontAwesome.otf b/docs/fpm-ford/fonts/FontAwesome.otf old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/fonts/fontawesome-webfont.eot b/docs/fpm-ford/fonts/fontawesome-webfont.eot old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/fonts/fontawesome-webfont.svg b/docs/fpm-ford/fonts/fontawesome-webfont.svg old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/fonts/fontawesome-webfont.ttf b/docs/fpm-ford/fonts/fontawesome-webfont.ttf old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/fonts/fontawesome-webfont.woff b/docs/fpm-ford/fonts/fontawesome-webfont.woff old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/fonts/glyphicons-halflings-regular.eot b/docs/fpm-ford/fonts/glyphicons-halflings-regular.eot old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/fonts/glyphicons-halflings-regular.svg b/docs/fpm-ford/fonts/glyphicons-halflings-regular.svg old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/fonts/glyphicons-halflings-regular.ttf b/docs/fpm-ford/fonts/glyphicons-halflings-regular.ttf old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/fonts/glyphicons-halflings-regular.woff b/docs/fpm-ford/fonts/glyphicons-halflings-regular.woff old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/index.html b/docs/fpm-ford/index.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/atleast.html b/docs/fpm-ford/interface/atleast.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/aton.html b/docs/fpm-ford/interface/aton.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/cc.html b/docs/fpm-ford/interface/cc.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/cpad.html b/docs/fpm-ford/interface/cpad.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/dble.html b/docs/fpm-ford/interface/dble.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/ends_with.html b/docs/fpm-ford/interface/ends_with.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/int.html b/docs/fpm-ford/interface/int.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/lpad.html b/docs/fpm-ford/interface/lpad.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/matchw.html b/docs/fpm-ford/interface/matchw.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/msg.html b/docs/fpm-ford/interface/msg.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/nint.html b/docs/fpm-ford/interface/nint.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/percent_encode.html b/docs/fpm-ford/interface/percent_encode.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/real.html b/docs/fpm-ford/interface/real.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/rpad.html b/docs/fpm-ford/interface/rpad.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/split2020.html b/docs/fpm-ford/interface/split2020.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/string.html b/docs/fpm-ford/interface/string.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/string_to_value.html b/docs/fpm-ford/interface/string_to_value.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/switch.html b/docs/fpm-ford/interface/switch.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/upper.html b/docs/fpm-ford/interface/upper.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/v2s.html b/docs/fpm-ford/interface/v2s.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/interface/zpad.html b/docs/fpm-ford/interface/zpad.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/js/MathJax-config/.gitignore b/docs/fpm-ford/js/MathJax-config/.gitignore old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/js/bootstrap.js b/docs/fpm-ford/js/bootstrap.js old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/js/bootstrap.min.js b/docs/fpm-ford/js/bootstrap.min.js old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/js/ie10-viewport-bug-workaround.js b/docs/fpm-ford/js/ie10-viewport-bug-workaround.js old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/js/jquery-2.1.3.min.js b/docs/fpm-ford/js/jquery-2.1.3.min.js old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/js/svg-pan-zoom.min.js b/docs/fpm-ford/js/svg-pan-zoom.min.js old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/lists/files.html b/docs/fpm-ford/lists/files.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/lists/modules.html b/docs/fpm-ford/lists/modules.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/lists/procedures.html b/docs/fpm-ford/lists/procedures.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/lists/types.html b/docs/fpm-ford/lists/types.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/media/M_strings.gif b/docs/fpm-ford/media/M_strings.gif old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/media/strings.gif b/docs/fpm-ford/media/strings.gif old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/media/strings_small.gif b/docs/fpm-ford/media/strings_small.gif old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/module/m_strings.html b/docs/fpm-ford/module/m_strings.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/module/m_strings__oop.html b/docs/fpm-ford/module/m_strings__oop.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/adjustc.html b/docs/fpm-ford/proc/adjustc.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/atoi.html b/docs/fpm-ford/proc/atoi.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/atol.html b/docs/fpm-ford/proc/atol.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/base.html b/docs/fpm-ford/proc/base.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/base2.html b/docs/fpm-ford/proc/base2.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/bundle.html b/docs/fpm-ford/proc/bundle.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/c2s.html b/docs/fpm-ford/proc/c2s.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/change.html b/docs/fpm-ford/proc/change.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/chomp.html b/docs/fpm-ford/proc/chomp.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/clip.html b/docs/fpm-ford/proc/clip.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/codebase.html b/docs/fpm-ford/proc/codebase.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/compact.html b/docs/fpm-ford/proc/compact.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/crop.html b/docs/fpm-ford/proc/crop.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/decodebase.html b/docs/fpm-ford/proc/decodebase.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/delim.html b/docs/fpm-ford/proc/delim.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/describe.html b/docs/fpm-ford/proc/describe.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/dilate.html b/docs/fpm-ford/proc/dilate.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/edit_distance.html b/docs/fpm-ford/proc/edit_distance.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/expand.html b/docs/fpm-ford/proc/expand.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/find_field.html b/docs/fpm-ford/proc/find_field.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/fortran_name.html b/docs/fpm-ford/proc/fortran_name.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/getvals.html b/docs/fpm-ford/proc/getvals.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/glob.html b/docs/fpm-ford/proc/glob.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/indent.html b/docs/fpm-ford/proc/indent.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/isalnum.html b/docs/fpm-ford/proc/isalnum.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/isalpha.html b/docs/fpm-ford/proc/isalpha.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/isascii.html b/docs/fpm-ford/proc/isascii.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/isblank.html b/docs/fpm-ford/proc/isblank.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/iscntrl.html b/docs/fpm-ford/proc/iscntrl.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/isdigit.html b/docs/fpm-ford/proc/isdigit.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/isgraph.html b/docs/fpm-ford/proc/isgraph.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/islower.html b/docs/fpm-ford/proc/islower.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/isnumber.html b/docs/fpm-ford/proc/isnumber.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/isprint.html b/docs/fpm-ford/proc/isprint.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/ispunct.html b/docs/fpm-ford/proc/ispunct.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/isspace.html b/docs/fpm-ford/proc/isspace.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/isupper.html b/docs/fpm-ford/proc/isupper.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/isxdigit.html b/docs/fpm-ford/proc/isxdigit.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/join.html b/docs/fpm-ford/proc/join.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/len_white.html b/docs/fpm-ford/proc/len_white.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/lenset.html b/docs/fpm-ford/proc/lenset.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/listout.html b/docs/fpm-ford/proc/listout.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/longest_common_substring.html b/docs/fpm-ford/proc/longest_common_substring.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/lower.html b/docs/fpm-ford/proc/lower.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/matching_delimiter.html b/docs/fpm-ford/proc/matching_delimiter.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/merge_str.html b/docs/fpm-ford/proc/merge_str.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/modif.html b/docs/fpm-ford/proc/modif.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/noesc.html b/docs/fpm-ford/proc/noesc.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/nospace.html b/docs/fpm-ford/proc/nospace.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/notabs.html b/docs/fpm-ford/proc/notabs.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/p.html b/docs/fpm-ford/proc/p.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/pad.html b/docs/fpm-ford/proc/pad.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/paragraph.html b/docs/fpm-ford/proc/paragraph.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/quote.html b/docs/fpm-ford/proc/quote.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/replace.html b/docs/fpm-ford/proc/replace.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/reverse.html b/docs/fpm-ford/proc/reverse.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/rotate13.html b/docs/fpm-ford/proc/rotate13.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/s2c.html b/docs/fpm-ford/proc/s2c.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/s2v.html b/docs/fpm-ford/proc/s2v.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/s2vs.html b/docs/fpm-ford/proc/s2vs.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/sep.html b/docs/fpm-ford/proc/sep.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/setbits16.html b/docs/fpm-ford/proc/setbits16.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/setbits32.html b/docs/fpm-ford/proc/setbits32.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/setbits64.html b/docs/fpm-ford/proc/setbits64.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/setbits8.html b/docs/fpm-ford/proc/setbits8.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/split.html b/docs/fpm-ford/proc/split.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/squeeze.html b/docs/fpm-ford/proc/squeeze.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/stretch.html b/docs/fpm-ford/proc/stretch.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/string_to_values.html b/docs/fpm-ford/proc/string_to_values.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/string_tokens.html b/docs/fpm-ford/proc/string_tokens.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/strtok.html b/docs/fpm-ford/proc/strtok.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/substitute.html b/docs/fpm-ford/proc/substitute.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/transliterate.html b/docs/fpm-ford/proc/transliterate.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/unquote.html b/docs/fpm-ford/proc/unquote.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/upper.html b/docs/fpm-ford/proc/upper.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/upper_quoted.html b/docs/fpm-ford/proc/upper_quoted.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/value_to_string.html b/docs/fpm-ford/proc/value_to_string.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/proc/visible.html b/docs/fpm-ford/proc/visible.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/search.html b/docs/fpm-ford/search.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/sourcefile/m_strings.f90.html b/docs/fpm-ford/sourcefile/m_strings.f90.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/sourcefile/m_strings__oop.f90.html b/docs/fpm-ford/sourcefile/m_strings__oop.f90.html old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/tipuesearch/.DS_Store b/docs/fpm-ford/tipuesearch/.DS_Store old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/tipuesearch/img/.DS_Store b/docs/fpm-ford/tipuesearch/img/.DS_Store old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/tipuesearch/img/loader.gif b/docs/fpm-ford/tipuesearch/img/loader.gif old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/tipuesearch/img/search.png b/docs/fpm-ford/tipuesearch/img/search.png old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/tipuesearch/tipuesearch.css b/docs/fpm-ford/tipuesearch/tipuesearch.css old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/tipuesearch/tipuesearch.js b/docs/fpm-ford/tipuesearch/tipuesearch.js old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/tipuesearch/tipuesearch.min.js b/docs/fpm-ford/tipuesearch/tipuesearch.min.js old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/tipuesearch/tipuesearch_content.js b/docs/fpm-ford/tipuesearch/tipuesearch_content.js old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/tipuesearch/tipuesearch_set.js b/docs/fpm-ford/tipuesearch/tipuesearch_set.js old mode 100755 new mode 100644 diff --git a/docs/fpm-ford/type/string.html b/docs/fpm-ford/type/string.html old mode 100755 new mode 100644 diff --git a/docs/getvals.3m_strings.html b/docs/getvals.3m_strings.html old mode 100644 new mode 100755 index 05401157..0281c12f --- a/docs/getvals.3m_strings.html +++ b/docs/getvals.3m_strings.html @@ -234,7 +234,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 getvals (3m_strings) September 21, 2024
Generated by manServer 1.08 from 859ceba4-7441-4c36-864e-a2d2d7a74197 using man macros. +
Nemo Release 3.1 getvals (3m_strings) January 10, 2025
Generated by manServer 1.08 from 1319e72d-08a7-4404-8bb0-9ccb7d6fe06e using man macros.

diff --git a/docs/glob.3m_strings.html b/docs/glob.3m_strings.html old mode 100644 new mode 100755 index ff3a9323..27b9af8e --- a/docs/glob.3m_strings.html +++ b/docs/glob.3m_strings.html @@ -162,7 +162,7 @@

EXAMPLES

    program demo_glob
    implicit none
-   ! This main() routine passes a bunch of test strings
+   ! This main routine passes a bunch of test strings
    ! into the above code.  In performance comparison mode,
    ! it does that over and over. Otherwise, it does it just
    ! once. Either way, it outputs a passed/failed result.
@@ -400,7 +400,7 @@ 

LICENSE

Public Domain


-
Nemo Release 3.1 glob (3m_strings) September 21, 2024
Generated by manServer 1.08 from 7699700f-06ab-412b-bcee-0cbd0e3f4daa using man macros. +
Nemo Release 3.1 glob (3m_strings) January 10, 2025
Generated by manServer 1.08 from 5c85769e-c629-4b0e-89d5-9f81a4df7038 using man macros.

diff --git a/docs/images/M_strings.gif b/docs/images/M_strings.gif old mode 100755 new mode 100644 diff --git a/docs/images/strings.gif b/docs/images/strings.gif old mode 100755 new mode 100644 diff --git a/docs/images/strings_small.gif b/docs/images/strings_small.gif old mode 100755 new mode 100644 diff --git a/docs/indent.3m_strings.html b/docs/indent.3m_strings.html old mode 100644 new mode 100755 index 11e5c313..f84366c5 --- a/docs/indent.3m_strings.html +++ b/docs/indent.3m_strings.html @@ -141,7 +141,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 indent (3m_strings) September 21, 2024
Generated by manServer 1.08 from 6e51f3e4-69cd-4d99-a2d2-b5743e7467db using man macros. +
Nemo Release 3.1 indent (3m_strings) January 10, 2025
Generated by manServer 1.08 from 1e14b398-d4b6-4bd9-bcf9-7dbd405cf203 using man macros.

diff --git a/docs/index.html b/docs/index.html old mode 100644 new mode 100755 index 39815709..c2113c32 --- a/docs/index.html +++ b/docs/index.html @@ -4,7 +4,7 @@ - + +
+
+
+


Manual Reference Pages  - lower_quoted (3m_strings)

+
+ + +

NAME

+ +
+
+lower_quoted(3f) - [M_strings:CASE] elemental function converts string to +lowercase skipping strings quoted per Fortran syntax rules +(LICENSE:PD) +

+

+

CONTENTS

+
+Synopsis
+Description
+Options
+Returns
+Examples
+See Also
+Author
+License
+
+ + +

SYNOPSIS

+ +
+
+elemental pure function lower_quoted(str) result (string) +

+

+    character(*), intent(in)    :: str
+    character(len(str))         :: string  ! output string
+

+

+
+ + +

DESCRIPTION

+ +
+
+lower_quoted(string) returns a copy of the input string with all not-quoted +characters converted to lowercase, assuming ASCII character sets +are being used. The quoting rules are the same as for Fortran source. +Either a single or double quote starts a quoted string, and a quote +character of the same type is doubled when it appears internally in +the quoted string. If a double quote quotes the string single quotes +may appear in the quoted string as single characters, and vice-versa +for single quotes. +
+ + +

OPTIONS

+ +
+
+ + +
+str +string to convert to lowercase +
+ + +

RETURNS

+ +
+
+ + +
+lower +copy of the input string with all unquoted characters converted +to lowercase +
+ + +

EXAMPLES

+ +
+
+Sample program: +

+

+    program demo_lower_quoted
+    use M_strings, only: lower_quoted
+    implicit none
+    character(len=:),allocatable  :: s
+    s=’ ABCDEFG abcdefg "Double-Quoted" ’’Single-Quoted’’ "with ""&
+       & Quote" everything else’
+       write(*,*) ’mixed-case input string is ....’,s
+       write(*,*) ’lower-case output string is ...’,lower_quoted(s)
+       write(*,’(1x,a,*(a:,"+"))’) ’lower_quoted(3f) is elemental ==>’, &
+       & lower_quoted(["abc","def","ghi"])
+    end program demo_lower_quoted
+

+

+Results: +

+

+ >  mixed-case input string is .... ABCDEFG abcdefg "Double-Quoted" ...
+    ... ’Single-Quoted’ "with "" Quote" everything else
+ >  lower-case output string is ... abcdefg abcdefg "Double-Quoted" ...
+    ... ’Single-Quoted’ "with "" Quote" everything else
+ >  lower_quoted(3f) is elemental ==>abc+def+ghi
+

+

+
+ + +

SEE ALSO

+ +
+
+flower(1) +
+ + +

AUTHOR

+ +
+
+John S. Urban +
+ + +

LICENSE

+ +
+
+Public Domain +
+


+
Nemo Release 3.1 lower_quoted (3m_strings) January 10, 2025
Generated by manServer 1.08 from ab8f40e7-78ca-40e8-9679-852b88ced03e using man macros. +

+
+
+ + diff --git a/docs/lpad.3m_strings.html b/docs/lpad.3m_strings.html old mode 100755 new mode 100644 index fad7b717..62c20d99 --- a/docs/lpad.3m_strings.html +++ b/docs/lpad.3m_strings.html @@ -180,7 +180,7 @@

LICENSE

Public Domain


-
Nemo Release 3.1 lpad (3m_strings) September 21, 2024
Generated by manServer 1.08 from cd4cae23-4305-42d5-aa38-11720aeaaa29 using man macros. +
Nemo Release 3.1 lpad (3m_strings) January 10, 2025
Generated by manServer 1.08 from 30a113c3-9b7a-40c1-8730-32d733be164c using man macros.

diff --git a/docs/man3.html b/docs/man3.html old mode 100644 new mode 100755 index ac6f5fd2..414f3f11 --- a/docs/man3.html +++ b/docs/man3.html @@ -45,7 +45,7 @@ [GPF Home Page]
-

M_strings man(3) pages

+

M_strings__oop man(3) pages