INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES

indexing

description: "Two-way lists, kept sorted"
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: sorted_two_way_list, sorted_struct, sequence
cluster: eiffelbase
class PART_SORTED_TWO_WAY_LIST [G -> COMPARABLE]
inherit

TWO_WAY_LIST [G]
undefine
has,
search
redefine
extend,
new_chain,
prune_all
end

PART_SORTED_LIST [G]
undefine
after,
before,
finish,
first,
go_i_th,
isfirst,
islast,
last,
move,
off,
prune,
prune_all,
readable,
remove,
start
end
creation

make
feature -- Element change

extend (v: G)
-- Put `v' at proper position in list.
-- The cursor ends up on the newly inserted
-- item.
feature -- Removal

prune_all (v: G)
-- Remove all items identical to `v'.
-- (Reference or object equality,
-- based on `object_comparison'.)
-- Leave cursor `off'.
feature -- Status report

sorted: BOOLEAN
-- is the structures topologically sorted
-- i.e i < j implies not i_th (i) > i_th (j)
feature -- Transformation

sort
-- sort the list
-- Has O(`count' * log (`count')) complexity.
--| Uses comb-sort (BYTE February '91)
end -- class PART_SORTED_TWO_WAY_LIST

INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES