Tính trừu tượng (abstraction) là một trong bốn tính chất cơ bản của lập trình hướng đối tượng trong Java.
Tính trừu tượng là một tiến trình ẩn các chi tiết trình triển khai và chỉ hiển thị tính năng tới người dùng. Tính trừu tượng cho phép bạn loại bỏ tính chất phức tạp của đối tượng bằng cách chỉ đưa ra các thuộc tính và phương thức cần thiết của đối tượng trong lập trình.
Tính trừu tượng giúp bạn tập trung vào những cốt lõi cần thiết của đối tượng thay vì quan tâm đến cách nó thực hiện.
Trong Java, chúng là sử dụng abstract class và abstract interface để có tính trừu tượng. Chi tiết các bạn xem thêm ở bài viết: Abstract class và Interface trong Java.
Related posts:
Java Program to Implement Sorted Circularly Singly Linked List
Check If a String Is Numeric in Java
Java Program to Perform Postorder Recursive Traversal of a Given Binary Tree
Using Java Assertions
Guide to java.util.concurrent.Future
Handle EML file with JavaMail
Refactoring Design Pattern với tính năng mới trong Java 8
Giới thiệu Java 8
Spring MVC Async vs Spring WebFlux
Java Program to Perform Preorder Recursive Traversal of a Given Binary Tree
Guide to ThreadLocalRandom in Java
Hướng dẫn Java Design Pattern – Dependency Injection
Java Program to Implement LinkedHashMap API
Java Program to Find the Minimum Element of a Rotated Sorted Array using Binary Search approach
Jackson JSON Views
Updating your Password
Java Program to Find Path Between Two Nodes in a Graph
So sánh Array và ArrayList trong Java
A Guide To UDP In Java
Read an Outlook MSG file
Java Program to Implement ConcurrentLinkedQueue API
Spring Boot - Creating Docker Image
Java Program to Represent Graph Using Adjacency List
A Guide to JUnit 5
Bootstrap a Web Application with Spring 5
Sử dụng CountDownLatch trong Java
Java – Delete a File
Java Program to Perform Inorder Recursive Traversal of a Given Binary Tree
REST Web service: HTTP Status Code và xử lý ngoại lệ RESTful web service với Jersey 2.x
Instance Profile Credentials using Spring Cloud
Java Program to Sort an Array of 10 Elements Using Heap Sort Algorithm
Getting Started with Custom Deserialization in Jackson