1 /* readonlysortedmap.vala
3 * Copyright (C) 2009-2011 Maciej Piechotka
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20 * Maciej Piechotka <uzytkownik2@gmail.com>
23 public abstract class Gee.AbstractSortedMap<K, V> : AbstractMap<K,V>, SortedMap<K,V> {
27 public abstract SortedMap<K,V> head_map (K before);
32 public abstract SortedMap<K,V> tail_map (K after);
37 public abstract SortedMap<K,V> sub_map (K before, K after);
42 public abstract SortedSet<K> ascending_keys { owned get; }
47 public abstract SortedSet<Map.Entry<K,V>> ascending_entries { owned get; }
49 private weak SortedMap<K,V> _read_only_view;
51 * The read-only view this map.
53 public new SortedMap<K,V> read_only_view {
55 SortedMap<K,V> instance = _read_only_view;
56 if (_read_only_view == null) {
57 instance = new ReadOnlySortedMap<K,V> (this);
58 _read_only_view = instance;
59 instance.add_weak_pointer ((void**) (&_read_only_view));
66 internal new virtual void reserved0() {}
67 internal new virtual void reserved1() {}
68 internal new virtual void reserved2() {}
69 internal new virtual void reserved3() {}
70 internal new virtual void reserved4() {}
71 internal new virtual void reserved5() {}
72 internal new virtual void reserved6() {}
73 internal new virtual void reserved7() {}
74 internal new virtual void reserved8() {}
75 internal new virtual void reserved9() {}