Gentee Programming Language > Documentation > Libraries Download documentation

Initializing the search pattern

The spattern type is used to search through the string for another string. Before search start-up, call the spattern.init method in order to initialize the search pattern. Then do a search of the specified pattern with the help of spattern.search.
 
spattern spattern.init(
      str   pattern,
      uint   flag
)

Parameters

patternSearch string (pattern).
flagSearch-flags.
$QS_IGNCASECase-insensitive.
$QS_WORDSearch the whole word only.
$QS_BEGINWORDSearch words which start with the specified pattern.

Return value

Returns the object which method has been called.

See also

    Strings


 Copyright © 2004-2006 Gentee Inc. All rights reserved.