Lecture 7: Collections

Lecture 7: Collections presents Collections, Interfaces, Implementations, Algorithm; A collection, also called a container, is an object that groups multiple elements into a single unit. | Lecture 7: Collections Lê Hồng Phương phuonglh@ Department of Mathematics, Mechanics and Informatics, Vietnam National University, Hanoi Content ● Collections ● Interfaces ● Implementations ● Algorithms ● Exercises August, 2012 2 Collections ● ● A collection, also called a container, is an object that groups multiple elements into a single unit. Collections are used to store, retrieve, manipulate data. – A collection of cards, a mail folders, a telephone directory. August, 2012 3 A collection framework ● ● A collection framework is a unified architecture for representing and manipulating collections. Three components of a collection framework: – Interfaces: abstracts data types that represent collections – Implementations: concrete implementations of collection interfaces – Algorithms: methods that perform useful computations such as searching and sorting on objects implementing collection interfaces. August, 2012 4 Benefits of the Java collection framework ● Reduces programming efforts ● Increases program speed and quality ● Allows interoperability among unrelated APIs ● Reduces effort to learn and to use new APIs ● Reduces effort to design new APIs ● Fosters software reuse August, .

Không thể tạo bản xem trước, hãy bấm tải xuống
TÀI LIỆU MỚI ĐĂNG
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.