Java Doc for List.java in  » 6.0-JDK-Modules-sun » javac-compiler » com » sun » tools » javac » util » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » 6.0 JDK Modules sun » javac compiler » com.sun.tools.javac.util 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


com.sun.tools.javac.util.List

List
public class List extends AbstractCollection implements java.util.List<A>(Code)
A class for generic linked lists. Links are supposed to be immutable, the only exception being the incremental construction of lists via ListBuffers. List is the main container class in GJC. Most data structures and algorthms in GJC use lists rather than arrays.

Lists are always trailed by a sentinel element, whose head and tail are both null.

This is NOT part of any API supported by Sun Microsystems. If you write code that depends on this, you do so at your own risk. This code and its internal interfaces are subject to change or deletion without notice.



Field Summary
public  Ahead
     The first element of the list, supposed to be immutable.
public  List<A>tail
     The remainder of the list except for its first element, supposed to be immutable.

Constructor Summary
 List(A head, List<A> tail)
     Construct a list given its head and tail.

Method Summary
public  voidadd(int index, A element)
    
public  booleanaddAll(int index, Collection<? extends A> c)
    
public  List<A>append(A x)
     Append given element at length, forming and returning a new list.
public  List<A>appendList(List<A> x)
     Append given list at length, forming and returning a new list.
public  List<A>appendList(ListBuffer<A> x)
     Append given list buffer at length, forming and returning a new list.
public  booleancontains(Object x)
    
public static  List<T>convert(Class<T> klass, List list)
    
public  booleanequals(Object other)
    
public static  booleanequals(List xs, List ys)
    
public static  List<A>fill(int len, A init)
     Construct a list consisting of a given number of identical elements.
public static  List<A>from(A[] array)
     Construct a list consisting all elements of given array.
public  Aget(int index)
    
public  inthashCode()
    
public  intindexOf(Object o)
    
public  booleanisEmpty()
    
public  Iterator<A>iterator()
    
public  Alast()
     The last element in the list, if any, or null.
public  intlastIndexOf(Object o)
    
public  intlength()
     Return the number of elements in this list.
public  ListIterator<A>listIterator()
    
public  ListIterator<A>listIterator(int index)
    
public static  List<A>nil()
     Construct an empty list.
public  booleannonEmpty()
    
public static  List<A>of(A x1)
     Construct a list consisting of given element.
public static  List<A>of(A x1, A x2)
     Construct a list consisting of given elements.
public static  List<A>of(A x1, A x2, A x3)
     Construct a list consisting of given elements.
public static  List<A>of(A x1, A x2, A x3, A... rest)
     Construct a list consisting of given elements.
public  List<A>prepend(A x)
     Prepend given element to front of list, forming and returning a new list.
public  List<A>prependList(List<A> xs)
     Prepend given list of elements to front of list, forming and returning a new list.
public  Aremove(int index)
    
public  List<A>reverse()
     Reverse list.
public  Aset(int index, A element)
    
public  List<A>setTail(List<A> tail)
    
public  intsize()
    
public  java.util.List<A>subList(int fromIndex, int toIndex)
    
public  T[]toArray(T[] vec)
     Copy successive elements of this list into given vector until list is exhausted or end of vector is reached.
public  Object[]toArray()
    
public  StringtoString(String sep)
     Form a string listing all elements with given separator character.
public  StringtoString()
     Form a string listing all elements with comma as the separator character.

Field Detail
head
public A head(Code)
The first element of the list, supposed to be immutable.



tail
public List<A> tail(Code)
The remainder of the list except for its first element, supposed to be immutable.




Constructor Detail
List
List(A head, List<A> tail)(Code)
Construct a list given its head and tail.




Method Detail
add
public void add(int index, A element)(Code)



addAll
public boolean addAll(int index, Collection<? extends A> c)(Code)



append
public List<A> append(A x)(Code)
Append given element at length, forming and returning a new list.



appendList
public List<A> appendList(List<A> x)(Code)
Append given list at length, forming and returning a new list.



appendList
public List<A> appendList(ListBuffer<A> x)(Code)
Append given list buffer at length, forming and returning a new list.



contains
public boolean contains(Object x)(Code)
Does the list contain the specified element?



convert
public static List<T> convert(Class<T> klass, List list)(Code)



equals
public boolean equals(Object other)(Code)
Is this list the same as other list?
See Also:   java.util.List.equals



equals
public static boolean equals(List xs, List ys)(Code)
Are the two lists the same?



fill
public static List<A> fill(int len, A init)(Code)
Construct a list consisting of a given number of identical elements.
Parameters:
  len - The number of elements in the list.
Parameters:
  init - The value of each element.



from
public static List<A> from(A[] array)(Code)
Construct a list consisting all elements of given array.
Parameters:
  array - an array; if null return an empty list



get
public A get(int index)(Code)



hashCode
public int hashCode()(Code)
Compute a hash code, overrides Object
See Also:   java.util.List.hashCode



indexOf
public int indexOf(Object o)(Code)



isEmpty
public boolean isEmpty()(Code)
Does list have no elements?



iterator
public Iterator<A> iterator()(Code)



last
public A last()(Code)
The last element in the list, if any, or null.



lastIndexOf
public int lastIndexOf(Object o)(Code)



length
public int length()(Code)
Return the number of elements in this list.



listIterator
public ListIterator<A> listIterator()(Code)



listIterator
public ListIterator<A> listIterator(int index)(Code)



nil
public static List<A> nil()(Code)
Construct an empty list.



nonEmpty
public boolean nonEmpty()(Code)
Does list have elements?



of
public static List<A> of(A x1)(Code)
Construct a list consisting of given element.



of
public static List<A> of(A x1, A x2)(Code)
Construct a list consisting of given elements.



of
public static List<A> of(A x1, A x2, A x3)(Code)
Construct a list consisting of given elements.



of
public static List<A> of(A x1, A x2, A x3, A... rest)(Code)
Construct a list consisting of given elements.



prepend
public List<A> prepend(A x)(Code)
Prepend given element to front of list, forming and returning a new list.



prependList
public List<A> prependList(List<A> xs)(Code)
Prepend given list of elements to front of list, forming and returning a new list.



remove
public A remove(int index)(Code)



reverse
public List<A> reverse()(Code)
Reverse list. If the list is empty or a singleton, then the same list is returned. Otherwise a new list is formed.



set
public A set(int index, A element)(Code)



setTail
public List<A> setTail(List<A> tail)(Code)



size
public int size()(Code)



subList
public java.util.List<A> subList(int fromIndex, int toIndex)(Code)



toArray
public T[] toArray(T[] vec)(Code)
Copy successive elements of this list into given vector until list is exhausted or end of vector is reached.



toArray
public Object[] toArray()(Code)



toString
public String toString(String sep)(Code)
Form a string listing all elements with given separator character.



toString
public String toString()(Code)
Form a string listing all elements with comma as the separator character.



www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.