A method for detecting and locating occurrence in a data stream of any
complex string belonging to a predefined complex dictionary is disclosed.
A complex string may comprise an arbitrary number of interleaving
coherent strings and ambiguous strings. The method comprises a first
process for transforming the complex dictionary into a simple structure
to enable continuously conducting computationally efficient search, and a
second process for examining received data in real time using the simple
structure. The method may be realized by an article of manufacture
comprising at least one processor-readable medium and instructions
carried on the at least one medium. The instructions causes a processor
to match examined data to an object complex string belonging to the
complex dictionary, where the matching process is based on equality to
constituent coherent strings, and congruence to ambiguous strings, of the
object complex string.