INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES

indexing

description: "Structures that may be traversed forward and backward"
title: "EiffelBase: library of reusable components for Eiffel. ", "Based on EiffelBase library for ISE Eiffel, ", "used with permission. "
project: "EiffelBase Library"
copyright: "(c) 1986-1997 Interactive Software Engineering Inc. ", "Modifications and extensions: ", "(c) 1997 Object Tools ", "All rights reserved. Duplication and distribution prohibited", "May be used only with Visual Eiffel under terms of user ", "license "
key: bidirectional, traversing
cluster: eiffelbase
deferred class BILINEAR [G]
inherit

LINEAR [G]
rename
search as sequential_search
export
{NONE}
sequential_search
redefine
off
end

LINEAR [G]
redefine
off,
search
select
search
end
feature -- Access

off: BOOLEAN
-- Is there no current item?
feature -- Cursor movement

before: BOOLEAN
-- Is there no valid position to the left of current one?

back
-- Move to previous position.
require
not_before: not before
ensure
moved_back: index = index - 1

search (v: G)
-- Move to first position (at or after current
-- position) where `item' and `v' are equal.
-- If structure does not include `v' ensure that
-- `exhausted' will be true.
-- (Reference or object equality,
-- based on `object_comparison'.)
invariant

not_both: not (after and before)
empty_property: empty implies (after or before)
before_constraint: before implies off
end -- class BILINEAR

INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES