SlideShare uma empresa Scribd logo
1 de 10
Baixar para ler offline
Java
49971011 方伯仁
49971012 蕭博元
 Java ,是一種可以撰寫跨平台應用軟體的物件導向的
程式語言,由當時任職昇陽電腦的詹姆斯·高斯林(等
人於1990年代初開發。它最初被命名為 Oak ,目標設
定在家用電器等小型系統的程式設計語言,來解決諸
如電視機、電話、鬧鐘、烤麵包機等家用電器的控制
和通訊問題。由於這些智慧型家電的市場需求沒有預
期的高, Sun 放棄了該項計劃。就在 Oak 幾近失敗之
時,隨著網際網路的發展, Sun 看到了 Oak 在電腦網
路上的廣闊應用前景,於是改造了 Oak ,在1995年
5月以「 Java 」的名稱正式發布了。 Java 伴隨著網際
網路的迅猛發展而發展,逐漸成為重要的網路程式語
言。
 Java 程式語言的風格十分接近 C++語言。繼
承了 C++ 語言物件導向技術的核心, Java 捨
棄了 C++ 語言中容易引起錯誤的指標(以參照
取代)、運算符過載( operator
overloading )、多重繼承(以介面取代)等
特性,增加了垃圾回收器功能用於回收不再被
參照的物件所佔據的內部記憶體空間。在
Java SE 1.5 版本中 Java 又引入了
泛型程式設計( Generic Programming )、
型別安全的列舉、不定長參數和自動裝/拆箱
等語言特性。
 Java 不同於一般的編譯執行電腦語言和
解釋執行電腦語言。它首先將原始碼編
譯成位元組碼( bytecode ),然後依賴
各種不同平台上的虛擬機器來解釋執行
位元組碼,從而實作了「一次編譯、到
處執行」的跨平台特性。不過,這同時
也在一定程度上降低了 Java 程式的執行
效率。但在 J2SE1.4.2 發布後, Java 的
執行速度有了大幅提升。
 與傳統程式不同 Sun 公司在推出 Java 之際就
將其作為一種開放的技術。全球數以萬計的
Java 開發公司被要求所設計的 Java 軟體必須
相互相容。「 Java 語言靠群體的力量而非公
司的力量」是 Sun 公司的口號之一,並獲得
了廣大軟體開發商的認同。這與微軟公司所倡
導的注重精英和封閉式的模式完全不同。
 Sun 公司對 Java 程式語言的解釋是: Java 程
式語言是個簡單、物件導向、分散式、解釋性
、健壯、安全與系統無關、可移植、高效能、
多執行緒和動態的語言。
 物件導向
 Java 的特點之一就是物件導向,是程式設計方
法的一種。「物件導向程式語言」的核心之一
就是開發者在設計軟體的時候可以使用自訂的
型別和關聯操作。程式碼和資料的實際集合體
叫做「物件」。一個物件可以想像成繫結了很
多「行為(程式碼)」和「狀態(資料)」的
物體。對於資料結構的改變需要和程式碼進行
通訊然後操作,反之亦然。物件導向設計讓大
型軟體工程的計劃和設計變得更容易管理,能
增強專案的健康度,減少失敗專案的數量。
 物件導向設計另外一個標的就是能產生很多的
有關聯的類,可以讓軟體的再開發變得簡單。
舉例來說,很多軟體工程都有同樣的功能,尤
其是很多應用了同一原理組織的軟體工程。軟
體的二次開發者想自己為軟體開發外掛程式以
增強功能的時候,絕對不想看到混亂的開發程
式碼和管理計劃。物件導向的目的就是不生產
難懂且難以使用的程式碼,為軟體各個功能群
之間建立有效的通訊通道。很多開源軟體社群
正在計劃給軟體作者提供更多的類來讓軟體的
二次開發變得簡便。
跨平台性
 Java 語言的第二個特性就是跨平臺性,
也就是說使用 Java 語言編寫的程式可以
在編譯後不用經過任何更改,就能在任
何硬體裝置條件下執行。這個特性經常
被稱為「一次編譯,到處執行」。
 軟體開發人員選擇 Java 的原因 :
 Java 經過千錘百鍊,由專屬開發團隊全面精心打造。共
有超過 650 萬名的開發人員參與其中, 是全球規模最大
且最積極研發的軟體。 Java 憑藉其多用途、高效率及可
攜性,已成為開發人員不可或缺的技術, 可讓他們:
 為某一平台撰寫的軟體可實際在其他任何平台上執行
 建立在 Web 瀏覽器和 Web 服務中執行的程式
 開發適用於線上論壇、商店、票選、 HTML 表格處理及
其他內容的伺服器端應用程式
 結合使用 Java 語言的應用程式或服務,以建立高度客製
化的應用程式或服務
 為行動電話、遠端處理器、低成本消費品以及幾乎所有的
數位裝置撰寫功能強大的高效率應用程式
 軟體開發人員選擇 Java 的原因 :
 Java 經過千錘百鍊,由專屬開發團隊全面精心打造。共
有超過 650 萬名的開發人員參與其中, 是全球規模最大
且最積極研發的軟體。 Java 憑藉其多用途、高效率及可
攜性,已成為開發人員不可或缺的技術, 可讓他們:
 為某一平台撰寫的軟體可實際在其他任何平台上執行
 建立在 Web 瀏覽器和 Web 服務中執行的程式
 開發適用於線上論壇、商店、票選、 HTML 表格處理及
其他內容的伺服器端應用程式
 結合使用 Java 語言的應用程式或服務,以建立高度客製
化的應用程式或服務
 為行動電話、遠端處理器、低成本消費品以及幾乎所有的
數位裝置撰寫功能強大的高效率應用程式

Mais conteúdo relacionado

Destaque

How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Applitools
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at WorkGetSmarter
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...DevGAMM Conference
 
Barbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationErica Santiago
 
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellGood Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellSaba Software
 
Introduction to C Programming Language
Introduction to C Programming LanguageIntroduction to C Programming Language
Introduction to C Programming LanguageSimplilearn
 

Destaque (20)

How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
 
ChatGPT webinar slides
ChatGPT webinar slidesChatGPT webinar slides
ChatGPT webinar slides
 
More than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike RoutesMore than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike Routes
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
 
Barbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy Presentation
 
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellGood Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
 
Introduction to C Programming Language
Introduction to C Programming LanguageIntroduction to C Programming Language
Introduction to C Programming Language
 

Java