INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES

indexing

description: "Very fast substring searcher"
cluster: matcher
class SUBSTRING
inherit

SEARCHER
end
creation

make,
make_insensitive,
make_sensitive
feature -- Modification

set_sensitive
-- Make the searcher case-sensitive.

set_insensitive
-- Make the searcher case-insensitive.
feature -- Searching

search_forward (s: STRING; s_from, s_to: INTEGER)
-- Search for `pattern' in string `s'. Start searching at index
-- position `s_from' and search until the pattern matches (while
-- ignoring any characters behind `s_to'). If pattern matches, set
-- `found' to true and `start_position' and `end_position'
-- to the corresponding index positions (relative to the beginning
-- of the string). If the pattern doesn't match, set `found' to
-- false, but do not modify `start_position' or `end_position'.

search_backward (s: STRING; s_from, s_to: INTEGER)
-- Search for `pattern' in string `s'. Start searching at index
-- position `s_to' and search backward until the pattern matches
-- (ignoring any characters before `s_from'). If pattern matches,
-- set `found' to true and `start_position' and `end_position'
-- to the corresponding index positions (relative to the beginning
-- of the string). If the pattern doesn't match, set `found' to
-- false, but do not modify `start_position' or `end_position'.
invariant

always_compiled: compiled
end -- class SUBSTRING

INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES