collection.html

来自「j2se5-api-zh,java文档的中文版本」· HTML 代码 · 共 1,104 行 · 第 1/5 页

HTML
1,104
字号
<TD><CODE><B>ArrayList.</B><B><A HREF="../ArrayList.html#addAll(java.util.Collection)">addAll</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;? extends <A HREF="../ArrayList.html" title="ArrayList 中的类型参数">E</A>&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;按照指定 Collection 的迭代器所返回的元素顺序,将该 Collection 中的所有元素追加到此列表的尾部。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>LinkedList.</B><B><A HREF="../LinkedList.html#addAll(java.util.Collection)">addAll</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;? extends <A HREF="../LinkedList.html" title="LinkedList 中的类型参数">E</A>&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;追加指定 collection 中的所有元素到此列表的结尾,顺序是指定 collection 的迭代器返回这些元素的顺序。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>TreeSet.</B><B><A HREF="../TreeSet.html#addAll(java.util.Collection)">addAll</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;? extends <A HREF="../TreeSet.html" title="TreeSet 中的类型参数">E</A>&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;将指定 collection 中的所有元素添加到此 set 中。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>AbstractQueue.</B><B><A HREF="../AbstractQueue.html#addAll(java.util.Collection)">addAll</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;? extends <A HREF="../AbstractQueue.html" title="AbstractQueue 中的类型参数">E</A>&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;将指定 collection 中的所有元素都添加到此队列中。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY=""><TR ALIGN="right" VALIGN=""><TD NOWRAP><FONT SIZE="-1"><CODE>&lt;T&gt; boolean</CODE></FONT></TD></TR></TABLE></CODE></FONT></TD><TD><CODE><B>Collections.</B><B><A HREF="../Collections.html#addAll(java.util.Collection, T...)">addAll</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;? super T&gt;&nbsp;c,       T...&nbsp;a)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;将所有指定元素添加到指定 collection 中。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>List.</B><B><A HREF="../List.html#addAll(int, java.util.Collection)">addAll</A></B>(int&nbsp;index,       <A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;? extends <A HREF="../List.html" title="List 中的类型参数">E</A>&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;将指定 collection 中的所有元素都插入到列表中的指定位置(可选操作)。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>AbstractList.</B><B><A HREF="../AbstractList.html#addAll(int, java.util.Collection)">addAll</A></B>(int&nbsp;index,       <A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;? extends <A HREF="../AbstractList.html" title="AbstractList 中的类型参数">E</A>&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;将指定 collection 中的所有元素插入此列表的指定位置(可选操作)。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>Vector.</B><B><A HREF="../Vector.html#addAll(int, java.util.Collection)">addAll</A></B>(int&nbsp;index,       <A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;? extends <A HREF="../Vector.html" title="Vector 中的类型参数">E</A>&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;将指定 Collection 中的所有元素插入到此向量中的指定位置。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>ArrayList.</B><B><A HREF="../ArrayList.html#addAll(int, java.util.Collection)">addAll</A></B>(int&nbsp;index,       <A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;? extends <A HREF="../ArrayList.html" title="ArrayList 中的类型参数">E</A>&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;从指定的位置开始,将指定 Collection 中的所有元素插入到此列表中。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>AbstractSequentialList.</B><B><A HREF="../AbstractSequentialList.html#addAll(int, java.util.Collection)">addAll</A></B>(int&nbsp;index,       <A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;? extends <A HREF="../AbstractSequentialList.html" title="AbstractSequentialList 中的类型参数">E</A>&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;在此列表中指定的位置上插入指定 collection 中的所有元素。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>LinkedList.</B><B><A HREF="../LinkedList.html#addAll(int, java.util.Collection)">addAll</A></B>(int&nbsp;index,       <A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;? extends <A HREF="../LinkedList.html" title="LinkedList 中的类型参数">E</A>&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;将指定集合中的所有元素从指定位置开始插入此列表。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY=""><TR ALIGN="right" VALIGN=""><TD NOWRAP><FONT SIZE="-1"><CODE>&lt;E&gt; <A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;E&gt;</CODE></FONT></TD></TR></TABLE></CODE></FONT></TD><TD><CODE><B>Collections.</B><B><A HREF="../Collections.html#checkedCollection(java.util.Collection, java.lang.Class)">checkedCollection</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;E&gt;&nbsp;c,                  <A HREF="../../lang/Class.html" title="java.lang 中的类">Class</A>&lt;E&gt;&nbsp;type)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;返回指定 collection 的一个动态类型安全视图。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>Collection.</B><B><A HREF="../Collection.html#containsAll(java.util.Collection)">containsAll</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;?&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;如果此 collection 包含指定 collection 中的所有元素,则返回 <tt>true</tt>。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>List.</B><B><A HREF="../List.html#containsAll(java.util.Collection)">containsAll</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;?&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;如果列表包含指定 collection 的所有元素,则返回 <tt>true</tt>。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>AbstractCollection.</B><B><A HREF="../AbstractCollection.html#containsAll(java.util.Collection)">containsAll</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;?&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;如果此 collection 包含指定 collection 中的所有元素,则返回 <tt>true</tt>。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>Vector.</B><B><A HREF="../Vector.html#containsAll(java.util.Collection)">containsAll</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;?&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;如果此向量包含指定 Collection 中的所有元素,则返回 true。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>Set.</B><B><A HREF="../Set.html#containsAll(java.util.Collection)">containsAll</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;?&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;如果此 set 包含指定 collection 的所有元素,则返回 <tt>true</tt>。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY=""><TR ALIGN="right" VALIGN=""><TD NOWRAP><FONT SIZE="-1"><CODE>&lt;E extends <A HREF="../../lang/Enum.html" title="java.lang 中的类">Enum</A>&lt;E&gt;&gt; <BR><A HREF="../EnumSet.html" title="java.util 中的类">EnumSet</A>&lt;E&gt;</CODE></FONT></TD></TR></TABLE></CODE></FONT></TD><TD><CODE><B>EnumSet.</B><B><A HREF="../EnumSet.html#copyOf(java.util.Collection)">copyOf</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;E&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;创建一个从指定 collection 初始化的枚举 set。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>Collections.</B><B><A HREF="../Collections.html#disjoint(java.util.Collection, java.util.Collection)">disjoint</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;?&gt;&nbsp;c1,         <A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;?&gt;&nbsp;c2)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;如果两个指定 collection 中没有相同的元素,则返回 <tt>true</tt>。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;boolean</CODE></FONT></TD><TD><CODE><B>Collections.</B><B><A HREF="../Collections.html#disjoint(java.util.Collection, java.util.Collection)">disjoint</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;?&gt;&nbsp;c1,         <A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;?&gt;&nbsp;c2)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;如果两个指定 collection 中没有相同的元素,则返回 <tt>true</tt>。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY=""><TR ALIGN="right" VALIGN=""><TD NOWRAP><FONT SIZE="-1"><CODE>&lt;T&gt; <A HREF="../Enumeration.html" title="java.util 中的接口">Enumeration</A>&lt;T&gt;</CODE></FONT></TD></TR></TABLE></CODE></FONT></TD><TD><CODE><B>Collections.</B><B><A HREF="../Collections.html#enumeration(java.util.Collection)">enumeration</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;T&gt;&nbsp;c)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;返回一个指定 collection 上的枚举。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B>Collections.</B><B><A HREF="../Collections.html#frequency(java.util.Collection, java.lang.Object)">frequency</A></B>(<A HREF="../Collection.html" title="java.util 中的接口">Collection</A>&lt;?&gt;&nbsp;c,          <A HREF="../../lang/Object.html" title="java.lang 中的类">Object</A>&nbsp;o)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;返回指定 collection 中等于指定对象的元素数。</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY=""><TR ALIGN="right" VALIGN=""><TD NOWRAP><FONT SIZE="-1"><CODE>&lt;T extends <A HREF="../../lang/Object.html" title="java.lang 中的类">Object</A> & <A HREF="../../lang/Comparable.html" title="java.lang 中的接口">Comparable</A>&lt;? super T&gt;&gt; 

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?