Command: regex_replace

NEST HelpDesk Command Index NEST Quick Reference

Name:
 regex_replace - replace all occurences of a regex
Synopsis:
 string string istreamtype ostreamtype -> -
          regex  string istreamtype ostreamtype -> -
          string string string -> string
          regex  string string -> string
Description:
 regex_replace tries to match the regex in
  istream/string.  Any occurence of regex is replaced by 
  the given string.
Parameters:
 in: first argument  : a regex generated by regcomp
                               OR a string which will be converted
                                  to a regex by a regcomp call.
                second argument : the string with which regex should
                                  be replaced.
                third argument  : an istream or a string where this
                                  regex should be matched.
                fourth argument (if any): an ostream where the changes
                                  are saved.
           out: either a string or, if called with streams, the
                                ostream will now contain replaced stream.

Examples:
 
Bugs:
 
Diagnostics:
 if called with a string as first argument, will raise an
   /InvalidRegexError if regcomp fails to compile a regex.
Author:
 Hehl
FirstVersion:
 4.10.99
Remarks:
 
SeeAlso:regexec regcomp regex_find
Source:
 /home/abuild/rpmbuild/BUILD/nest-2.4.1/lib/sli/regexp.sli

NEST HelpDesk Command Index NEST Quick Reference

© 2000-2010 The NEST Initiative