Java generics and collections

This comprehensive guide shows you how to master the most importantchanges to Java since it was first released. Generics and the greatlyexpanded collection libraries have tremendously increased the power ofJava 5 and Java 6. But they have also confused many developers whohaven't known how to...

Descripción completa

Detalles Bibliográficos
Autor principal: Naftalin, Maurice, 1951- (-)
Otros Autores: Wadler, Philip, 1956-
Formato: Libro electrónico
Idioma:Inglés
Publicado: Beijing ; Sebastopol, California : O'Reilly 2006.
Edición:1st edition
Materias:
Ver en Biblioteca Universitat Ramon Llull:https://discovery.url.edu/permalink/34CSUC_URL/1im36ta/alma991009627213906719
Tabla de Contenidos:
  • Java Generics and Collections; How to Contact Us; Conventions Used in This Book; Using Code Examples; Safari® Books Online; Acknowledgments; I. Generics; Boxing and Unboxing; Foreach; Generic Methods and Varargs; Assertions; 2. Subtyping and Wildcards; Wildcards with extends; Wildcards with super; The Get and Put Principle; Arrays; Wildcards Versus Type Parameters; Wildcard Capture; Restrictions on Wildcards; 3. Comparison and Bounds; Maximum of a Collection; A Fruity Example; Comparator; Enumerated Types; Multiple Bounds; Bridges; Covariant Overriding; 4. Declarations; Static Members
  • Nested ClassesHow Erasure Works; 5. Evolution, Not Revolution; Generic Library with Generic Client; Generic Library with Legacy Client; Legacy Library with Generic Client; Evolving a Library using Stubs; Evolving a Library using Wrappers; Conclusions; 6. Reification; Instance Tests and Casts; Exception Handling; Array Creation; The Principle of Truth in Advertising; The Principle of Indecent Exposure; How to Define ArrayList; Array Creation and Varargs; Arrays as a Deprecated Type?; Summing Up; 7. Reflection; Reflected Types are Reifiable Types; Reflection for Primitive Types
  • A Generic Reflection LibraryReflection for Generics; Reflecting Generic Types; 8. Effective Generics; Use Checked Collections to Enforce Security; Specialize to Create Reifiable Types; Maintain Binary Compatibility; 9. Design Patterns; Interpreter; Function; Strategy; Subject-Observer; II. Collections; 11. Preliminaries; Implementations; Efficiency and the O-Notation; Contracts; Collections and Thread Safety; JDK 1.2: Synchronized Collections and Fail-Fast Iterators; Concurrent Collections: Java 5 and Beyond; 12. The Collection Interface; Implementing Collection; Collection Constructors
  • 13. SetsLinkedHashSet; CopyOnWriteArraySet; EnumSet; SortedSet and NavigableSet; TreeSet; ConcurrentSkipListSet; Comparing Set Implementations; 14. Queues; Implementing Queue; ConcurrentLinkedQueue; BlockingQueue; Implementing BlockingQueue; ArrayBlockingQueue; PriorityBlockingQueue; DelayQueue; SynchronousQueue; Deque; LinkedList; BlockingDeque; Comparing Queue Implementations; 15. Lists; Implementing List; LinkedList; CopyOnWriteArrayList; Comparing List Implementations; 16. Maps; Implementing Map; LinkedHashMap; WeakHashMap; IdentityHashMap; EnumMap; SortedMap and NavigableMap; TreeMap
  • ConcurrentMapConcurrentNavigableMap; Comparing Map Implementations; 17. The Collections Class; Changing the Contents of a List; Finding Extreme Values in a Collection; Finding Specific Values in a List; Collection Factories; Wrappers; Unmodifiable Collections; Checked Collections; Other Methods; Index; Colophon