lamp_mac/FIGARO/
strings_utilities.pro
:Author: pellegrini
Routines
result = search_uppercase_letters(str)
result = strreplace(str, substr1, substr2)
result = valtostr(value)
result = strtoarr(original)
result = strcap(strs, Lowerize=Lowerize)
result = str_to_complex(str)
result = complex_to_str(complexes, format=format)
result = str_array_split(array, separator=separator, reform=reform)
result = str_centerize(str, siz)
strings_utilities
Routine details
top search_uppercase_letters
result = search_uppercase_letters(str)
:Description: Returns the indexes of a string corresponding to upper case letter. :Params: str : in, required, type="str" The input string to search for capital letters. :Returns: A 1D integer array storing the indexes of the upper case letters found in the string. -1 if no upper case letter was found. :Author: pellegrini :History: pellegrini, 11 févr. 2011 :Categories: core, strings
Parameters
- str
top strreplace
result = strreplace(str, substr1, substr2)
:Description: Replace all occurences of substring 'substr1' with 'substr2'. :Params: str : in, required, type="str" The input string. substr1 : in, required, type="str" The substring to be replaced. substr2 : in, required, type="str" The new substring. :Returns: A string where all occurences of substr1 substring have been replaced by substr2 substring. :Author: pellegrini :History: pellegrini, 11 févr. 2011 :Categories: core, string
Parameters
- str
- substr1
- substr2
top valtostr
result = valtostr(value)
:Description: Convert number to string as printed. :Params: value : in, required, type="any" :Returns: The string resulting from the conversion. :Author: unknown :History: unknown, 11 févr. 2011 :Categories: core, string
Parameters
- value
top strtoarr
result = strtoarr(original)
:Description: Separate string into a 1D array of component strings (separator is ',' or '+', keeping the separator at the front of each string) :Params: original : in, required, type="str" The input string. :Returns: The 1D array resulting from the splitting of the input string. :Author: unknown :History: unknown, 11 févr. 2011 :Categories: core, string
Parameters
- original
top strcap
result = strcap(strs, Lowerize=Lowerize)
:Description: Capitalize the first letter of each element of an array of string. :Params: strs : in, required, type="strarr" The input array of strings. :Keywords: lowerize : in, optional, type="int" If set to 1. The rest of the string will be lowerized. :Returns: :Author: pellegrini :History: pellegrini, 11 févr. 2011 :Categories: core, strings
Parameters
- strs
Keywords
- Lowerize
top str_to_complex
result = str_to_complex(str)
:Description: This function convert a string representing a complex number written in the form a + bi to the IDL complex number internal format. :Params: str: in, required, type="str" The input string representing the complex number to convert. MUST be in the form 'a + bi' :Returns: The IDL complex number corresponding to the input string. :Author: pellegrini :History: pellegrini, 11 févr. 2011 :Categories: core, strings
Parameters
- str
top complex_to_str
result = complex_to_str(complexes, format=format)
:Description: Convert an IDL complex number to a complex string of the form a + bi. :Params: complexes : in, required, type="Complex array" The array of IDL complex number to convert to an array of complex string. :Keywords: Format : in, optional, type="format str" The format for the real and imaginary part of the complex. Default is '(F8.4)'. :Returns: An array of complex strings. If a single complex number is given as input return a single string. :Author: pellegrini :History: pellegrini, 15 févr. 2011 :Categories: core, strings
Parameters
- complexes
Keywords
- format
top str_array_split
result = str_array_split(array, separator=separator, reform=reform)
Parameters
- array
Keywords
- separator
- reform
top strings_utilities
strings_utilities
:Description: The module constructor. :Author: pellegrini :History: pellegrini, 18 Feb. 2011 :Categories: strings utilities
File attributes
Modification date: | Tue Oct 1 14:42:05 2013 |
Lines: | 433 |