• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
2<!--NewPage-->
3<HTML>
4<HEAD>
5<!-- Generated by javadoc (build 1.6.0-google-internal) on Mon Jan 04 20:47:59 PST 2010 -->
6<TITLE>
7ImmutableSortedSet (Guava Libraries 2010.01.04)
8</TITLE>
9
10<META NAME="date" CONTENT="2010-01-04">
11
12<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14<SCRIPT type="text/javascript">
15function windowTitle()
16{
17    if (location.href.indexOf('is-external=true') == -1) {
18        parent.document.title="ImmutableSortedSet (Guava Libraries 2010.01.04)";
19    }
20}
21</SCRIPT>
22<NOSCRIPT>
23</NOSCRIPT>
24
25</HEAD>
26
27<BODY BGCOLOR="white" onload="windowTitle();">
28<HR>
29
30
31<!-- ========= START OF TOP NAVBAR ======= -->
32<A NAME="navbar_top"><!-- --></A>
33<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35<TR>
36<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37<A NAME="navbar_top_firstrow"><!-- --></A>
38<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39  <TR ALIGN="center" VALIGN="top">
40  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/ImmutableSortedSet.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48  </TR>
49</TABLE>
50</TD>
51<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52</EM>
53</TD>
54</TR>
55
56<TR>
57<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58&nbsp;<A HREF="../../../../com/google/common/collect/ImmutableSortedMap.Builder.html" title="class in com.google.common.collect"><B>PREV CLASS</B></A>&nbsp;
59&nbsp;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="class in com.google.common.collect"><B>NEXT CLASS</B></A></FONT></TD>
60<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61  <A HREF="../../../../index.html?com/google/common/collect/ImmutableSortedSet.html" target="_top"><B>FRAMES</B></A>  &nbsp;
62&nbsp;<A HREF="ImmutableSortedSet.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
63&nbsp;<SCRIPT type="text/javascript">
64  <!--
65  if(window==top) {
66    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67  }
68  //-->
69</SCRIPT>
70<NOSCRIPT>
71  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72</NOSCRIPT>
73
74
75</FONT></TD>
76</TR>
77<TR>
78<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79  SUMMARY:&nbsp;<A HREF="#nested_class_summary">NESTED</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82</TR>
83</TABLE>
84<A NAME="skip-navbar_top"></A>
85<!-- ========= END OF TOP NAVBAR ========= -->
86
87<HR>
88<!-- ======== START OF CLASS DATA ======== -->
89<H2>
90<FONT SIZE="-1">
91com.google.common.collect</FONT>
92<BR>
93Class ImmutableSortedSet&lt;E&gt;</H2>
94<PRE>
95<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96  <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><A HREF="../../../../com/google/common/collect/ImmutableCollection.html" title="class in com.google.common.collect">com.google.common.collect.ImmutableCollection</A>&lt;E&gt;
97      <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><A HREF="../../../../com/google/common/collect/ImmutableSet.html" title="class in com.google.common.collect">com.google.common.collect.ImmutableSet</A>&lt;E&gt;
98          <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>com.google.common.collect.ImmutableSortedSet&lt;E&gt;</B>
99</PRE>
100<DL>
101<DT><B>All Implemented Interfaces:</B> <DD><A HREF="http://java.sun.com/javase/6/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</A>&lt;E&gt;, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</A>&lt;E&gt;, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</A>&lt;E&gt;, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util">SortedSet</A>&lt;E&gt;</DD>
102</DL>
103<HR>
104<DL>
105<DT><PRE>public abstract class <B>ImmutableSortedSet&lt;E&gt;</B><DT>extends <A HREF="../../../../com/google/common/collect/ImmutableSet.html" title="class in com.google.common.collect">ImmutableSet</A>&lt;E&gt;<DT>implements <A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util">SortedSet</A>&lt;E&gt;</DL>
106</PRE>
107
108<P>
109An immutable <code>SortedSet</code> that stores its elements in a sorted array.
110 Some instances are ordered by an explicit comparator, while others follow the
111 natural sort ordering of their elements. Either way, null elements are not
112 supported.
113
114 <p>Unlike <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Collections.html?is-external=true#unmodifiableSortedSet(java.util.SortedSet)" title="class or interface in java.util"><CODE>Collections.unmodifiableSortedSet(java.util.SortedSet<T>)</CODE></A>, which is a <i>view</i>
115 of a separate collection that can still change, an instance of <code>ImmutableSortedSet</code> contains its own private data and will <i>never</i>
116 change. This class is convenient for <code>public static final</code> sets
117 ("constant sets") and also lets you easily make a "defensive copy" of a set
118 provided to your class by a caller.
119
120 <p>The sets returned by <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#headSet(E)"><CODE>headSet(E)</CODE></A>, <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#tailSet(E)"><CODE>tailSet(E)</CODE></A>, and
121 <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#subSet(E, E)"><CODE>subSet(E, E)</CODE></A> methods share the same array as the original set, preventing
122 that array from being garbage collected. If this is a concern, the data may
123 be copied into a correctly-sized array by calling <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#copyOfSorted(java.util.SortedSet)"><CODE>copyOfSorted(java.util.SortedSet<E>)</CODE></A>.
124
125 <p><b>Note on element equivalence:</b> The <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#contains(java.lang.Object)"><CODE>ImmutableCollection.contains(Object)</CODE></A>,
126 <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#containsAll(java.util.Collection)"><CODE>ImmutableCollection.containsAll(Collection)</CODE></A>, and <A HREF="../../../../com/google/common/collect/ImmutableSet.html#equals(java.lang.Object)"><CODE>ImmutableSet.equals(Object)</CODE></A>
127 implementations must check whether a provided object is equivalent to an
128 element in the collection. Unlike most collections, an
129 <code>ImmutableSortedSet</code> doesn't use <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang"><CODE>Object.equals(java.lang.Object)</CODE></A> to determine if
130 two elements are equivalent. Instead, with an explicit comparator, the
131 following relation determines whether elements <code>x</code> and <code>y</code> are
132 equivalent: <pre>   <code>{(x, y) | comparator.compare(x, y) == 0}</code></pre>
133
134 With natural ordering of elements, the following relation determines whether
135 two elements are equivalent: <pre>   <code>{(x, y) | x.compareTo(y) == 0}</code></pre>
136
137 <b>Warning:</b> Like most sets, an <code>ImmutableSortedSet</code> will not
138 function correctly if an element is modified after being placed in the set.
139 For this reason, and to avoid general confusion, it is strongly recommended
140 to place only immutable objects into this collection.
141
142 <p><b>Note</b>: Although this class is not final, it cannot be subclassed as
143 it has no public or protected constructors. Thus, instances of this type are
144 guaranteed to be immutable.
145<P>
146
147<P>
148<DL>
149<DT><B>Since:</B></DT>
150  <DD>2010.01.04 <b>stable</b> (imported from Google Collections Library)</DD>
151<DT><B>Author:</B></DT>
152  <DD>Jared Levy</DD>
153<DT><B>See Also:</B><DD><A HREF="../../../../com/google/common/collect/ImmutableSet.html" title="class in com.google.common.collect"><CODE>ImmutableSet</CODE></A>,
154<A HREF="../../../../serialized-form.html#com.google.common.collect.ImmutableSortedSet">Serialized Form</A></DL>
155<HR>
156
157<P>
158<!-- ======== NESTED CLASS SUMMARY ======== -->
159
160<A NAME="nested_class_summary"><!-- --></A>
161<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
162<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
163<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
164<B>Nested Class Summary</B></FONT></TH>
165</TR>
166<TR BGCOLOR="white" CLASS="TableRowColor">
167<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
168<CODE>static&nbsp;class</CODE></FONT></TD>
169<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="class in com.google.common.collect">ImmutableSortedSet.Builder</A>&lt;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="type parameter in ImmutableSortedSet.Builder">E</A>&gt;</B></CODE>
170
171<BR>
172&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A builder for creating immutable sorted set instances, especially
173 <code>public static final</code> sets ("constant sets"), with a given
174 comparator.</TD>
175</TR>
176</TABLE>
177&nbsp;
178<!-- ========== METHOD SUMMARY =========== -->
179
180<A NAME="method_summary"><!-- --></A>
181<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
182<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
183<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
184<B>Method Summary</B></FONT></TH>
185</TR>
186<TR BGCOLOR="white" CLASS="TableRowColor">
187<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
188<CODE>static
189<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
190<TR ALIGN="right" VALIGN="">
191<TD NOWRAP><FONT SIZE="-1">
192<CODE>&lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="class in com.google.common.collect">ImmutableSortedSet.Builder</A>&lt;E&gt;</CODE></FONT></TD>
193</TR>
194</TABLE>
195</CODE></FONT></TD>
196<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#builder()">builder</A></B>()</CODE>
197
198<BR>
199&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;<I>Use <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#naturalOrder()"><CODE>naturalOrder()</CODE></A>, which offers
200     better type-safety.</I></TD>
201</TR>
202<TR BGCOLOR="white" CLASS="TableRowColor">
203<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
204<CODE>&nbsp;<A HREF="http://java.sun.com/javase/6/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</A>&lt;? super <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&gt;</CODE></FONT></TD>
205<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#comparator()">comparator</A></B>()</CODE>
206
207<BR>
208&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the comparator that orders the elements, which is
209 <A HREF="../../../../com/google/common/collect/Ordering.html#natural()"><CODE>Ordering.natural()</CODE></A> when the natural ordering of the
210 elements is used.</TD>
211</TR>
212<TR BGCOLOR="white" CLASS="TableRowColor">
213<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
214<CODE>static
215<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
216<TR ALIGN="right" VALIGN="">
217<TD NOWRAP><FONT SIZE="-1">
218<CODE>&lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt;</CODE></FONT></TD>
219</TR>
220</TABLE>
221</CODE></FONT></TD>
222<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#copyOf(java.util.Comparator, java.lang.Iterable)">copyOf</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</A>&lt;? super E&gt;&nbsp;comparator,
223       <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</A>&lt;? extends E&gt;&nbsp;elements)</CODE>
224
225<BR>
226&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an immutable sorted set containing the given elements sorted by
227 the given <code>Comparator</code>.</TD>
228</TR>
229<TR BGCOLOR="white" CLASS="TableRowColor">
230<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
231<CODE>static
232<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
233<TR ALIGN="right" VALIGN="">
234<TD NOWRAP><FONT SIZE="-1">
235<CODE>&lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt;</CODE></FONT></TD>
236</TR>
237</TABLE>
238</CODE></FONT></TD>
239<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#copyOf(java.util.Comparator, java.util.Iterator)">copyOf</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</A>&lt;? super E&gt;&nbsp;comparator,
240       <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;? extends E&gt;&nbsp;elements)</CODE>
241
242<BR>
243&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an immutable sorted set containing the given elements sorted by
244 the given <code>Comparator</code>.</TD>
245</TR>
246<TR BGCOLOR="white" CLASS="TableRowColor">
247<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
248<CODE>static
249<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
250<TR ALIGN="right" VALIGN="">
251<TD NOWRAP><FONT SIZE="-1">
252<CODE>&lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt;</CODE></FONT></TD>
253</TR>
254</TABLE>
255</CODE></FONT></TD>
256<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#copyOf(java.lang.Iterable)">copyOf</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</A>&lt;? extends E&gt;&nbsp;elements)</CODE>
257
258<BR>
259&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an immutable sorted set containing the given elements sorted by
260 their natural ordering.</TD>
261</TR>
262<TR BGCOLOR="white" CLASS="TableRowColor">
263<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
264<CODE>static
265<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
266<TR ALIGN="right" VALIGN="">
267<TD NOWRAP><FONT SIZE="-1">
268<CODE>&lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt;</CODE></FONT></TD>
269</TR>
270</TABLE>
271</CODE></FONT></TD>
272<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#copyOf(java.util.Iterator)">copyOf</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;? extends E&gt;&nbsp;elements)</CODE>
273
274<BR>
275&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an immutable sorted set containing the given elements sorted by
276 their natural ordering.</TD>
277</TR>
278<TR BGCOLOR="white" CLASS="TableRowColor">
279<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
280<CODE>static
281<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
282<TR ALIGN="right" VALIGN="">
283<TD NOWRAP><FONT SIZE="-1">
284<CODE>&lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt;</CODE></FONT></TD>
285</TR>
286</TABLE>
287</CODE></FONT></TD>
288<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#copyOfSorted(java.util.SortedSet)">copyOfSorted</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util">SortedSet</A>&lt;E&gt;&nbsp;sortedSet)</CODE>
289
290<BR>
291&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an immutable sorted set containing the elements of a sorted set,
292 sorted by the same <code>Comparator</code>.</TD>
293</TR>
294<TR BGCOLOR="white" CLASS="TableRowColor">
295<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
296<CODE>&nbsp;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&gt;</CODE></FONT></TD>
297<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#headSet(E)">headSet</A></B>(<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&nbsp;toElement)</CODE>
298
299<BR>
300&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
301</TR>
302<TR BGCOLOR="white" CLASS="TableRowColor">
303<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
304<CODE>static
305<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
306<TR ALIGN="right" VALIGN="">
307<TD NOWRAP><FONT SIZE="-1">
308<CODE>&lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;E&gt;&gt;
309<BR>
310<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="class in com.google.common.collect">ImmutableSortedSet.Builder</A>&lt;E&gt;</CODE></FONT></TD>
311</TR>
312</TABLE>
313</CODE></FONT></TD>
314<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#naturalOrder()">naturalOrder</A></B>()</CODE>
315
316<BR>
317&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a builder that creates immutable sorted sets whose elements are
318 ordered by their natural ordering.</TD>
319</TR>
320<TR BGCOLOR="white" CLASS="TableRowColor">
321<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
322<CODE>static
323<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
324<TR ALIGN="right" VALIGN="">
325<TD NOWRAP><FONT SIZE="-1">
326<CODE>&lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt;</CODE></FONT></TD>
327</TR>
328</TABLE>
329</CODE></FONT></TD>
330<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#of()">of</A></B>()</CODE>
331
332<BR>
333&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the empty immutable sorted set.</TD>
334</TR>
335<TR BGCOLOR="white" CLASS="TableRowColor">
336<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
337<CODE>static
338<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
339<TR ALIGN="right" VALIGN="">
340<TD NOWRAP><FONT SIZE="-1">
341<CODE>&lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;? super E&gt;&gt;
342<BR>
343<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt;</CODE></FONT></TD>
344</TR>
345</TABLE>
346</CODE></FONT></TD>
347<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#of(E...)">of</A></B>(E...&nbsp;elements)</CODE>
348
349<BR>
350&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an immutable sorted set containing the given elements sorted by
351 their natural ordering.</TD>
352</TR>
353<TR BGCOLOR="white" CLASS="TableRowColor">
354<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
355<CODE>static
356<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
357<TR ALIGN="right" VALIGN="">
358<TD NOWRAP><FONT SIZE="-1">
359<CODE>&lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;? super E&gt;&gt;
360<BR>
361<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt;</CODE></FONT></TD>
362</TR>
363</TABLE>
364</CODE></FONT></TD>
365<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#of(E)">of</A></B>(E&nbsp;element)</CODE>
366
367<BR>
368&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an immutable sorted set containing a single element.</TD>
369</TR>
370<TR BGCOLOR="white" CLASS="TableRowColor">
371<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
372<CODE>static
373<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
374<TR ALIGN="right" VALIGN="">
375<TD NOWRAP><FONT SIZE="-1">
376<CODE>&lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;? super E&gt;&gt;
377<BR>
378<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt;</CODE></FONT></TD>
379</TR>
380</TABLE>
381</CODE></FONT></TD>
382<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#of(E, E)">of</A></B>(E&nbsp;e1,
383   E&nbsp;e2)</CODE>
384
385<BR>
386&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an immutable sorted set containing the given elements sorted by
387 their natural ordering.</TD>
388</TR>
389<TR BGCOLOR="white" CLASS="TableRowColor">
390<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
391<CODE>static
392<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
393<TR ALIGN="right" VALIGN="">
394<TD NOWRAP><FONT SIZE="-1">
395<CODE>&lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;? super E&gt;&gt;
396<BR>
397<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt;</CODE></FONT></TD>
398</TR>
399</TABLE>
400</CODE></FONT></TD>
401<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#of(E, E, E)">of</A></B>(E&nbsp;e1,
402   E&nbsp;e2,
403   E&nbsp;e3)</CODE>
404
405<BR>
406&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an immutable sorted set containing the given elements sorted by
407 their natural ordering.</TD>
408</TR>
409<TR BGCOLOR="white" CLASS="TableRowColor">
410<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
411<CODE>static
412<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
413<TR ALIGN="right" VALIGN="">
414<TD NOWRAP><FONT SIZE="-1">
415<CODE>&lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;? super E&gt;&gt;
416<BR>
417<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt;</CODE></FONT></TD>
418</TR>
419</TABLE>
420</CODE></FONT></TD>
421<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#of(E, E, E, E)">of</A></B>(E&nbsp;e1,
422   E&nbsp;e2,
423   E&nbsp;e3,
424   E&nbsp;e4)</CODE>
425
426<BR>
427&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an immutable sorted set containing the given elements sorted by
428 their natural ordering.</TD>
429</TR>
430<TR BGCOLOR="white" CLASS="TableRowColor">
431<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
432<CODE>static
433<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
434<TR ALIGN="right" VALIGN="">
435<TD NOWRAP><FONT SIZE="-1">
436<CODE>&lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;? super E&gt;&gt;
437<BR>
438<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt;</CODE></FONT></TD>
439</TR>
440</TABLE>
441</CODE></FONT></TD>
442<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#of(E, E, E, E, E)">of</A></B>(E&nbsp;e1,
443   E&nbsp;e2,
444   E&nbsp;e3,
445   E&nbsp;e4,
446   E&nbsp;e5)</CODE>
447
448<BR>
449&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an immutable sorted set containing the given elements sorted by
450 their natural ordering.</TD>
451</TR>
452<TR BGCOLOR="white" CLASS="TableRowColor">
453<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
454<CODE>static
455<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
456<TR ALIGN="right" VALIGN="">
457<TD NOWRAP><FONT SIZE="-1">
458<CODE>&lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="class in com.google.common.collect">ImmutableSortedSet.Builder</A>&lt;E&gt;</CODE></FONT></TD>
459</TR>
460</TABLE>
461</CODE></FONT></TD>
462<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#orderedBy(java.util.Comparator)">orderedBy</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</A>&lt;E&gt;&nbsp;comparator)</CODE>
463
464<BR>
465&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a builder that creates immutable sorted sets with an explicit
466 comparator.</TD>
467</TR>
468<TR BGCOLOR="white" CLASS="TableRowColor">
469<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
470<CODE>static
471<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
472<TR ALIGN="right" VALIGN="">
473<TD NOWRAP><FONT SIZE="-1">
474<CODE>&lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;E&gt;&gt;
475<BR>
476<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="class in com.google.common.collect">ImmutableSortedSet.Builder</A>&lt;E&gt;</CODE></FONT></TD>
477</TR>
478</TABLE>
479</CODE></FONT></TD>
480<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#reverseOrder()">reverseOrder</A></B>()</CODE>
481
482<BR>
483&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a builder that creates immutable sorted sets whose elements are
484 ordered by the reverse of their natural ordering.</TD>
485</TR>
486<TR BGCOLOR="white" CLASS="TableRowColor">
487<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
488<CODE>&nbsp;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&gt;</CODE></FONT></TD>
489<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#subSet(E, E)">subSet</A></B>(<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&nbsp;fromElement,
490       <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&nbsp;toElement)</CODE>
491
492<BR>
493&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
494</TR>
495<TR BGCOLOR="white" CLASS="TableRowColor">
496<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
497<CODE>&nbsp;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&gt;</CODE></FONT></TD>
498<TD><CODE><B><A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#tailSet(E)">tailSet</A></B>(<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&nbsp;fromElement)</CODE>
499
500<BR>
501&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
502</TR>
503</TABLE>
504&nbsp;<A NAME="methods_inherited_from_class_com.google.common.collect.ImmutableSet"><!-- --></A>
505<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
506<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
507<TH ALIGN="left"><B>Methods inherited from class com.google.common.collect.<A HREF="../../../../com/google/common/collect/ImmutableSet.html" title="class in com.google.common.collect">ImmutableSet</A></B></TH>
508</TR>
509<TR BGCOLOR="white" CLASS="TableRowColor">
510<TD><CODE><A HREF="../../../../com/google/common/collect/ImmutableSet.html#equals(java.lang.Object)">equals</A>, <A HREF="../../../../com/google/common/collect/ImmutableSet.html#hashCode()">hashCode</A>, <A HREF="../../../../com/google/common/collect/ImmutableSet.html#iterator()">iterator</A></CODE></TD>
511</TR>
512</TABLE>
513&nbsp;<A NAME="methods_inherited_from_class_com.google.common.collect.ImmutableCollection"><!-- --></A>
514<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
515<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
516<TH ALIGN="left"><B>Methods inherited from class com.google.common.collect.<A HREF="../../../../com/google/common/collect/ImmutableCollection.html" title="class in com.google.common.collect">ImmutableCollection</A></B></TH>
517</TR>
518<TR BGCOLOR="white" CLASS="TableRowColor">
519<TD><CODE><A HREF="../../../../com/google/common/collect/ImmutableCollection.html#add(E)">add</A>, <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#addAll(java.util.Collection)">addAll</A>, <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#asList()">asList</A>, <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#clear()">clear</A>, <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#contains(java.lang.Object)">contains</A>, <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#containsAll(java.util.Collection)">containsAll</A>, <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#isEmpty()">isEmpty</A>, <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#remove(java.lang.Object)">remove</A>, <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#removeAll(java.util.Collection)">removeAll</A>, <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#retainAll(java.util.Collection)">retainAll</A>, <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#toArray()">toArray</A>, <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#toArray(T[])">toArray</A>, <A HREF="../../../../com/google/common/collect/ImmutableCollection.html#toString()">toString</A></CODE></TD>
520</TR>
521</TABLE>
522&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
523<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
524<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
525<TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
526</TR>
527<TR BGCOLOR="white" CLASS="TableRowColor">
528<TD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
529</TR>
530</TABLE>
531&nbsp;<A NAME="methods_inherited_from_class_java.util.SortedSet"><!-- --></A>
532<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
533<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
534<TH ALIGN="left"><B>Methods inherited from interface java.util.<A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util">SortedSet</A></B></TH>
535</TR>
536<TR BGCOLOR="white" CLASS="TableRowColor">
537<TD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true#first()" title="class or interface in java.util">first</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true#last()" title="class or interface in java.util">last</A></CODE></TD>
538</TR>
539</TABLE>
540&nbsp;<A NAME="methods_inherited_from_class_java.util.Set"><!-- --></A>
541<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
542<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
543<TH ALIGN="left"><B>Methods inherited from interface java.util.<A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</A></B></TH>
544</TR>
545<TR BGCOLOR="white" CLASS="TableRowColor">
546<TD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#add(E)" title="class or interface in java.util">add</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#addAll(java.util.Collection)" title="class or interface in java.util">addAll</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#clear()" title="class or interface in java.util">clear</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#contains(java.lang.Object)" title="class or interface in java.util">contains</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#containsAll(java.util.Collection)" title="class or interface in java.util">containsAll</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.util">equals</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#hashCode()" title="class or interface in java.util">hashCode</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#isEmpty()" title="class or interface in java.util">isEmpty</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#iterator()" title="class or interface in java.util">iterator</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#remove(java.lang.Object)" title="class or interface in java.util">remove</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#removeAll(java.util.Collection)" title="class or interface in java.util">removeAll</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#retainAll(java.util.Collection)" title="class or interface in java.util">retainAll</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#size()" title="class or interface in java.util">size</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#toArray()" title="class or interface in java.util">toArray</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true#toArray(T[])" title="class or interface in java.util">toArray</A></CODE></TD>
547</TR>
548</TABLE>
549&nbsp;
550<P>
551
552<!-- ============ METHOD DETAIL ========== -->
553
554<A NAME="method_detail"><!-- --></A>
555<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
556<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
557<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
558<B>Method Detail</B></FONT></TH>
559</TR>
560</TABLE>
561
562<A NAME="of()"><!-- --></A><H3>
563of</H3>
564<PRE>
565public static &lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt; <B>of</B>()</PRE>
566<DL>
567<DD>Returns the empty immutable sorted set.
568<P>
569<DD><DL>
570</DL>
571</DD>
572<DD><DL>
573</DL>
574</DD>
575</DL>
576<HR>
577
578<A NAME="of(java.lang.Comparable)"><!-- --></A><A NAME="of(E)"><!-- --></A><H3>
579of</H3>
580<PRE>
581public static &lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;? super E&gt;&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt; <B>of</B>(E&nbsp;element)</PRE>
582<DL>
583<DD>Returns an immutable sorted set containing a single element.
584<P>
585<DD><DL>
586</DL>
587</DD>
588<DD><DL>
589</DL>
590</DD>
591</DL>
592<HR>
593
594<A NAME="of(java.lang.Comparable,java.lang.Comparable)"><!-- --></A><A NAME="of(E, E)"><!-- --></A><H3>
595of</H3>
596<PRE>
597public static &lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;? super E&gt;&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt; <B>of</B>(E&nbsp;e1,
598                                                                         E&nbsp;e2)</PRE>
599<DL>
600<DD>Returns an immutable sorted set containing the given elements sorted by
601 their natural ordering. When multiple elements are equivalent according to
602 <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true#compareTo(T)" title="class or interface in java.lang"><CODE>Comparable.compareTo(T)</CODE></A>, only the first one specified is included.
603<P>
604<DD><DL>
605</DL>
606</DD>
607<DD><DL>
608
609<DT><B>Throws:</B>
610<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if any element is null</DL>
611</DD>
612</DL>
613<HR>
614
615<A NAME="of(java.lang.Comparable,java.lang.Comparable,java.lang.Comparable)"><!-- --></A><A NAME="of(E, E, E)"><!-- --></A><H3>
616of</H3>
617<PRE>
618public static &lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;? super E&gt;&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt; <B>of</B>(E&nbsp;e1,
619                                                                         E&nbsp;e2,
620                                                                         E&nbsp;e3)</PRE>
621<DL>
622<DD>Returns an immutable sorted set containing the given elements sorted by
623 their natural ordering. When multiple elements are equivalent according to
624 <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true#compareTo(T)" title="class or interface in java.lang"><CODE>Comparable.compareTo(T)</CODE></A>, only the first one specified is included.
625<P>
626<DD><DL>
627</DL>
628</DD>
629<DD><DL>
630
631<DT><B>Throws:</B>
632<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if any element is null</DL>
633</DD>
634</DL>
635<HR>
636
637<A NAME="of(java.lang.Comparable,java.lang.Comparable,java.lang.Comparable,java.lang.Comparable)"><!-- --></A><A NAME="of(E, E, E, E)"><!-- --></A><H3>
638of</H3>
639<PRE>
640public static &lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;? super E&gt;&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt; <B>of</B>(E&nbsp;e1,
641                                                                         E&nbsp;e2,
642                                                                         E&nbsp;e3,
643                                                                         E&nbsp;e4)</PRE>
644<DL>
645<DD>Returns an immutable sorted set containing the given elements sorted by
646 their natural ordering. When multiple elements are equivalent according to
647 <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true#compareTo(T)" title="class or interface in java.lang"><CODE>Comparable.compareTo(T)</CODE></A>, only the first one specified is included.
648<P>
649<DD><DL>
650</DL>
651</DD>
652<DD><DL>
653
654<DT><B>Throws:</B>
655<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if any element is null</DL>
656</DD>
657</DL>
658<HR>
659
660<A NAME="of(java.lang.Comparable,java.lang.Comparable,java.lang.Comparable,java.lang.Comparable,java.lang.Comparable)"><!-- --></A><A NAME="of(E, E, E, E, E)"><!-- --></A><H3>
661of</H3>
662<PRE>
663public static &lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;? super E&gt;&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt; <B>of</B>(E&nbsp;e1,
664                                                                         E&nbsp;e2,
665                                                                         E&nbsp;e3,
666                                                                         E&nbsp;e4,
667                                                                         E&nbsp;e5)</PRE>
668<DL>
669<DD>Returns an immutable sorted set containing the given elements sorted by
670 their natural ordering. When multiple elements are equivalent according to
671 <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true#compareTo(T)" title="class or interface in java.lang"><CODE>Comparable.compareTo(T)</CODE></A>, only the first one specified is included.
672<P>
673<DD><DL>
674</DL>
675</DD>
676<DD><DL>
677
678<DT><B>Throws:</B>
679<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if any element is null</DL>
680</DD>
681</DL>
682<HR>
683
684<A NAME="of(java.lang.Comparable[])"><!-- --></A><A NAME="of(E...)"><!-- --></A><H3>
685of</H3>
686<PRE>
687public static &lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;? super E&gt;&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt; <B>of</B>(E...&nbsp;elements)</PRE>
688<DL>
689<DD>Returns an immutable sorted set containing the given elements sorted by
690 their natural ordering. When multiple elements are equivalent according to
691 <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true#compareTo(T)" title="class or interface in java.lang"><CODE>Comparable.compareTo(T)</CODE></A>, only the first one specified is included.
692<P>
693<DD><DL>
694</DL>
695</DD>
696<DD><DL>
697
698<DT><B>Throws:</B>
699<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if any of <code>elements</code> is null</DL>
700</DD>
701</DL>
702<HR>
703
704<A NAME="copyOf(java.lang.Iterable)"><!-- --></A><H3>
705copyOf</H3>
706<PRE>
707public static &lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt; <B>copyOf</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</A>&lt;? extends E&gt;&nbsp;elements)</PRE>
708<DL>
709<DD>Returns an immutable sorted set containing the given elements sorted by
710 their natural ordering. When multiple elements are equivalent according to
711 <code>compareTo()</code>, only the first one specified is included. To create a
712 copy of a <code>SortedSet</code> that preserves the comparator, call
713 <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#copyOfSorted(java.util.SortedSet)"><CODE>copyOfSorted(java.util.SortedSet<E>)</CODE></A> instead. This method iterates over <code>elements</code>
714 at most once.
715
716 <p>Note that if <code>s</code> is a <code>Set&lt;String&gt;</code>, then
717 <code>ImmutableSortedSet.copyOf(s)</code> returns an
718 <code>ImmutableSortedSet&lt;String&gt;</code> containing each of the strings in
719 <code>s</code>, while <code>ImmutableSortedSet.of(s)</code> returns an
720 <code>ImmutableSortedSet&lt;Set&lt;String&gt;&gt;</code> containing one element (the given
721 set itself).
722
723 <p><b>Note:</b> Despite what the method name suggests, if <code>elements</code>
724 is an <code>ImmutableSortedSet</code>, it may be returned instead of a copy.
725
726 <p>This method is not type-safe, as it may be called on elements that are
727 not mutually comparable.
728<P>
729<DD><DL>
730</DL>
731</DD>
732<DD><DL>
733
734<DT><B>Throws:</B>
735<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the elements are not mutually comparable
736<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if any of <code>elements</code> is null</DL>
737</DD>
738</DL>
739<HR>
740
741<A NAME="copyOf(java.util.Iterator)"><!-- --></A><H3>
742copyOf</H3>
743<PRE>
744public static &lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt; <B>copyOf</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;? extends E&gt;&nbsp;elements)</PRE>
745<DL>
746<DD>Returns an immutable sorted set containing the given elements sorted by
747 their natural ordering. When multiple elements are equivalent according to
748 <code>compareTo()</code>, only the first one specified is included.
749
750 <p>This method is not type-safe, as it may be called on elements that are
751 not mutually comparable.
752<P>
753<DD><DL>
754</DL>
755</DD>
756<DD><DL>
757
758<DT><B>Throws:</B>
759<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the elements are not mutually comparable
760<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if any of <code>elements</code> is null</DL>
761</DD>
762</DL>
763<HR>
764
765<A NAME="copyOf(java.util.Comparator, java.lang.Iterable)"><!-- --></A><H3>
766copyOf</H3>
767<PRE>
768public static &lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt; <B>copyOf</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</A>&lt;? super E&gt;&nbsp;comparator,
769                                               <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</A>&lt;? extends E&gt;&nbsp;elements)</PRE>
770<DL>
771<DD>Returns an immutable sorted set containing the given elements sorted by
772 the given <code>Comparator</code>. When multiple elements are equivalent
773 according to <code>compare()</code>, only the first one specified is
774 included. This method iterates over <code>elements</code> at most once.
775
776 <p><b>Note:</b> Despite what the method name suggests, if <code>elements</code>
777 is an <code>ImmutableSortedSet</code>, it may be returned instead of a copy.
778<P>
779<DD><DL>
780</DL>
781</DD>
782<DD><DL>
783
784<DT><B>Throws:</B>
785<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if <code>comparator</code> or any of
786     <code>elements</code> is null</DL>
787</DD>
788</DL>
789<HR>
790
791<A NAME="copyOf(java.util.Comparator, java.util.Iterator)"><!-- --></A><H3>
792copyOf</H3>
793<PRE>
794public static &lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt; <B>copyOf</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</A>&lt;? super E&gt;&nbsp;comparator,
795                                               <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;? extends E&gt;&nbsp;elements)</PRE>
796<DL>
797<DD>Returns an immutable sorted set containing the given elements sorted by
798 the given <code>Comparator</code>. When multiple elements are equivalent
799 according to <code>compareTo()</code>, only the first one specified is
800 included.
801<P>
802<DD><DL>
803</DL>
804</DD>
805<DD><DL>
806
807<DT><B>Throws:</B>
808<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if <code>comparator</code> or any of
809     <code>elements</code> is null</DL>
810</DD>
811</DL>
812<HR>
813
814<A NAME="copyOfSorted(java.util.SortedSet)"><!-- --></A><H3>
815copyOfSorted</H3>
816<PRE>
817public static &lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;E&gt; <B>copyOfSorted</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util">SortedSet</A>&lt;E&gt;&nbsp;sortedSet)</PRE>
818<DL>
819<DD>Returns an immutable sorted set containing the elements of a sorted set,
820 sorted by the same <code>Comparator</code>. That behavior differs from
821 <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#copyOf(java.lang.Iterable)"><CODE>copyOf(Iterable)</CODE></A>, which always uses the natural ordering of the
822 elements.
823
824 <p><b>Note:</b> Despite what the method name suggests, if <code>sortedSet</code>
825 is an <code>ImmutableSortedSet</code>, it may be returned instead of a copy.
826<P>
827<DD><DL>
828</DL>
829</DD>
830<DD><DL>
831
832<DT><B>Throws:</B>
833<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if any of <code>elements</code> is null</DL>
834</DD>
835</DL>
836<HR>
837
838<A NAME="orderedBy(java.util.Comparator)"><!-- --></A><H3>
839orderedBy</H3>
840<PRE>
841public static &lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="class in com.google.common.collect">ImmutableSortedSet.Builder</A>&lt;E&gt; <B>orderedBy</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</A>&lt;E&gt;&nbsp;comparator)</PRE>
842<DL>
843<DD>Returns a builder that creates immutable sorted sets with an explicit
844 comparator. If the comparator has a more general type than the set being
845 generated, such as creating a <code>SortedSet&lt;Integer&gt;</code> with a
846 <code>Comparator&lt;Number&gt;</code>, use the <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="class in com.google.common.collect"><CODE>ImmutableSortedSet.Builder</CODE></A> constructor instead.
847<P>
848<DD><DL>
849</DL>
850</DD>
851<DD><DL>
852
853<DT><B>Throws:</B>
854<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if <code>comparator</code> is null</DL>
855</DD>
856</DL>
857<HR>
858
859<A NAME="reverseOrder()"><!-- --></A><H3>
860reverseOrder</H3>
861<PRE>
862public static &lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;E&gt;&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="class in com.google.common.collect">ImmutableSortedSet.Builder</A>&lt;E&gt; <B>reverseOrder</B>()</PRE>
863<DL>
864<DD>Returns a builder that creates immutable sorted sets whose elements are
865 ordered by the reverse of their natural ordering.
866
867 <p>Note: the type parameter <code>E</code> extends <code>Comparable&lt;E&gt;</code> rather
868 than <code>Comparable&lt;? super E&gt;</code> as a workaround for javac <a
869 href="http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6468354">bug
870 6468354</a>.
871<P>
872<DD><DL>
873</DL>
874</DD>
875<DD><DL>
876</DL>
877</DD>
878</DL>
879<HR>
880
881<A NAME="naturalOrder()"><!-- --></A><H3>
882naturalOrder</H3>
883<PRE>
884public static &lt;E extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;E&gt;&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="class in com.google.common.collect">ImmutableSortedSet.Builder</A>&lt;E&gt; <B>naturalOrder</B>()</PRE>
885<DL>
886<DD>Returns a builder that creates immutable sorted sets whose elements are
887 ordered by their natural ordering. The sorted sets use <A HREF="../../../../com/google/common/collect/Ordering.html#natural()"><CODE>Ordering.natural()</CODE></A> as the comparator. This method provides more
888 type-safety than <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#builder()"><CODE>builder()</CODE></A>, as it can be called only for classes
889 that implement <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang"><CODE>Comparable</CODE></A>.
890
891 <p>Note: the type parameter <code>E</code> extends <code>Comparable&lt;E&gt;</code> rather
892 than <code>Comparable&lt;? super E&gt;</code> as a workaround for javac <a
893 href="http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6468354">bug
894 6468354</a>.
895<P>
896<DD><DL>
897</DL>
898</DD>
899<DD><DL>
900</DL>
901</DD>
902</DL>
903<HR>
904
905<A NAME="comparator()"><!-- --></A><H3>
906comparator</H3>
907<PRE>
908public <A HREF="http://java.sun.com/javase/6/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util">Comparator</A>&lt;? super <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&gt; <B>comparator</B>()</PRE>
909<DL>
910<DD>Returns the comparator that orders the elements, which is
911 <A HREF="../../../../com/google/common/collect/Ordering.html#natural()"><CODE>Ordering.natural()</CODE></A> when the natural ordering of the
912 elements is used. Note that its behavior is not consistent with
913 <A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true#comparator()" title="class or interface in java.util"><CODE>SortedSet.comparator()</CODE></A>, which returns <code>null</code> to indicate
914 natural ordering.
915<P>
916<DD><DL>
917<DT><B>Specified by:</B><DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true#comparator()" title="class or interface in java.util">comparator</A></CODE> in interface <CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util">SortedSet</A>&lt;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&gt;</CODE></DL>
918</DD>
919<DD><DL>
920</DL>
921</DD>
922</DL>
923<HR>
924
925<A NAME="headSet(java.lang.Object)"><!-- --></A><A NAME="headSet(E)"><!-- --></A><H3>
926headSet</H3>
927<PRE>
928public <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&gt; <B>headSet</B>(<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&nbsp;toElement)</PRE>
929<DL>
930<DD>
931
932 <p>This method returns a serializable <code>ImmutableSortedSet</code>.
933
934 <p>The <A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true#headSet(E)" title="class or interface in java.util"><CODE>SortedSet.headSet(E)</CODE></A> documentation states that a subset of a
935 subset throws an <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang"><CODE>IllegalArgumentException</CODE></A> if passed a
936 <code>toElement</code> greater than an earlier <code>toElement</code>. However, this
937 method doesn't throw an exception in that situation, but instead keeps the
938 original <code>toElement</code>.
939<P>
940<DD><DL>
941<DT><B>Specified by:</B><DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true#headSet(E)" title="class or interface in java.util">headSet</A></CODE> in interface <CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util">SortedSet</A>&lt;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&gt;</CODE></DL>
942</DD>
943<DD><DL>
944</DL>
945</DD>
946</DL>
947<HR>
948
949<A NAME="subSet(java.lang.Object,java.lang.Object)"><!-- --></A><A NAME="subSet(E, E)"><!-- --></A><H3>
950subSet</H3>
951<PRE>
952public <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&gt; <B>subSet</B>(<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&nbsp;fromElement,
953                                    <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&nbsp;toElement)</PRE>
954<DL>
955<DD>
956
957 <p>This method returns a serializable <code>ImmutableSortedSet</code>.
958
959 <p>The <A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true#subSet(E, E)" title="class or interface in java.util"><CODE>SortedSet.subSet(E, E)</CODE></A> documentation states that a subset of a
960 subset throws an <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang"><CODE>IllegalArgumentException</CODE></A> if passed a
961 <code>fromElement</code> smaller than an earlier <code>fromElement</code>. However,
962 this method doesn't throw an exception in that situation, but instead keeps
963 the original <code>fromElement</code>. Similarly, this method keeps the
964 original <code>toElement</code>, instead of throwing an exception, if passed a
965 <code>toElement</code> greater than an earlier <code>toElement</code>.
966<P>
967<DD><DL>
968<DT><B>Specified by:</B><DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true#subSet(E, E)" title="class or interface in java.util">subSet</A></CODE> in interface <CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util">SortedSet</A>&lt;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&gt;</CODE></DL>
969</DD>
970<DD><DL>
971</DL>
972</DD>
973</DL>
974<HR>
975
976<A NAME="tailSet(java.lang.Object)"><!-- --></A><A NAME="tailSet(E)"><!-- --></A><H3>
977tailSet</H3>
978<PRE>
979public <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="class in com.google.common.collect">ImmutableSortedSet</A>&lt;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&gt; <B>tailSet</B>(<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&nbsp;fromElement)</PRE>
980<DL>
981<DD>
982
983 <p>This method returns a serializable <code>ImmutableSortedSet</code>.
984
985 <p>The <A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true#tailSet(E)" title="class or interface in java.util"><CODE>SortedSet.tailSet(E)</CODE></A> documentation states that a subset of a
986 subset throws an <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang"><CODE>IllegalArgumentException</CODE></A> if passed a
987 <code>fromElement</code> smaller than an earlier <code>fromElement</code>. However,
988 this method doesn't throw an exception in that situation, but instead keeps
989 the original <code>fromElement</code>.
990<P>
991<DD><DL>
992<DT><B>Specified by:</B><DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true#tailSet(E)" title="class or interface in java.util">tailSet</A></CODE> in interface <CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util">SortedSet</A>&lt;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html" title="type parameter in ImmutableSortedSet">E</A>&gt;</CODE></DL>
993</DD>
994<DD><DL>
995</DL>
996</DD>
997</DL>
998<HR>
999
1000<A NAME="builder()"><!-- --></A><H3>
1001builder</H3>
1002<PRE>
1003<FONT SIZE="-1"><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</A>
1004</FONT>public static &lt;E&gt; <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="class in com.google.common.collect">ImmutableSortedSet.Builder</A>&lt;E&gt; <B>builder</B>()</PRE>
1005<DL>
1006<DD><B>Deprecated.</B>&nbsp;<I>Use <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#naturalOrder()"><CODE>naturalOrder()</CODE></A>, which offers
1007     better type-safety.</I>
1008<P>
1009<DD>Not supported. Use <A HREF="../../../../com/google/common/collect/ImmutableSortedSet.html#naturalOrder()"><CODE>naturalOrder()</CODE></A>, which offers
1010 better type-safety, instead. This method exists only to hide
1011 <A HREF="../../../../com/google/common/collect/ImmutableSet.html#builder()"><CODE>ImmutableSet.builder()</CODE></A> from consumers of <code>ImmutableSortedSet</code>.
1012<P>
1013<DD><DL>
1014
1015<DT><B>Throws:</B>
1016<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/UnsupportedOperationException.html?is-external=true" title="class or interface in java.lang">UnsupportedOperationException</A></CODE> - always</DL>
1017</DD>
1018</DL>
1019<!-- ========= END OF CLASS DATA ========= -->
1020<HR>
1021
1022
1023<!-- ======= START OF BOTTOM NAVBAR ====== -->
1024<A NAME="navbar_bottom"><!-- --></A>
1025<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
1026<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
1027<TR>
1028<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
1029<A NAME="navbar_bottom_firstrow"><!-- --></A>
1030<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
1031  <TR ALIGN="center" VALIGN="top">
1032  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
1033  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
1034  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
1035  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/ImmutableSortedSet.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
1036  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
1037  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
1038  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
1039  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
1040  </TR>
1041</TABLE>
1042</TD>
1043<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
1044</EM>
1045</TD>
1046</TR>
1047
1048<TR>
1049<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
1050&nbsp;<A HREF="../../../../com/google/common/collect/ImmutableSortedMap.Builder.html" title="class in com.google.common.collect"><B>PREV CLASS</B></A>&nbsp;
1051&nbsp;<A HREF="../../../../com/google/common/collect/ImmutableSortedSet.Builder.html" title="class in com.google.common.collect"><B>NEXT CLASS</B></A></FONT></TD>
1052<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
1053  <A HREF="../../../../index.html?com/google/common/collect/ImmutableSortedSet.html" target="_top"><B>FRAMES</B></A>  &nbsp;
1054&nbsp;<A HREF="ImmutableSortedSet.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
1055&nbsp;<SCRIPT type="text/javascript">
1056  <!--
1057  if(window==top) {
1058    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
1059  }
1060  //-->
1061</SCRIPT>
1062<NOSCRIPT>
1063  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
1064</NOSCRIPT>
1065
1066
1067</FONT></TD>
1068</TR>
1069<TR>
1070<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
1071  SUMMARY:&nbsp;<A HREF="#nested_class_summary">NESTED</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
1072<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
1073DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
1074</TR>
1075</TABLE>
1076<A NAME="skip-navbar_bottom"></A>
1077<!-- ======== END OF BOTTOM NAVBAR ======= -->
1078
1079<HR>
1080
1081</BODY>
1082</HTML>
1083