Java

ภาษา OOP ที่ได้รับความนิยมมากที่สุดตัวหนึ่ง สร้างโดย Sun Microsystems (ปัจจุบัน Oracle) ใช้เป็นหลักในการพัฒนา backend

จุดเด่น

  • Write Once, Run Anywhere — เขียนครั้งเดียว รันได้ทุก platform ผ่าน JVM
  • Strong typing — ตรวจจับ error ตั้งแต่ตอน compile
  • ทุกอย่างอยู่ใน class — เป็น OOP เต็มรูปแบบ
  • Syntax คล้าย Dart — คนเขียน Java เรียน Dart ได้เร็ว

Ecosystem

  • Spring / Spring Boot — framework หลักสำหรับ backend ใช้ Dependency Injection ผ่าน IoC Container
  • Maven / Gradle — จัดการ dependency ของ project
  • Hibernate — ORM สำหรับจัดการ database (ใช้กับ Spring Data JPA)

เปรียบเทียบกับ Dart

ด้านJavaDart
แนวคิดOOPOOP
Framework หลักSpring Boot (backend)Flutter (mobile)
DI@Autowired (อัตโนมัติผ่าน IoC Container)Provider / get_it (manual)
TypingStrong, staticStrong, static + inference
  • OOP — แนวคิดหลักของ Java
  • Spring — framework ตัวแม่
  • Spring Boot — framework เวอร์ชันใช้งานง่าย
  • Dependency Injection — pattern ที่ Spring ใช้เป็นหลัก