Perl Medic : Transforming Legacy Code (Paperback)

Peter Scott

  • 出版商: Addison Wesley
  • 出版日期: 2004-03-15
  • 定價: $1,400
  • 售價: 6.0$840
  • 語言: 英文
  • 頁數: 336
  • 裝訂: Paperback
  • ISBN: 0201795264
  • ISBN-13: 9780201795264
  • 相關分類: Perl 程式語言
  • 立即出貨(限量) (庫存=2)

買這商品的人也買了...

商品描述

Table of Contents:

Preface.

Perl or perl? Obtaining Perl. Historical Perl. Who This Book Is For. Typographical Conventions. For Further Reference. Perl Versions. Perl 6. Acknowledgments.

1. Introduction (First Response).

First Things First. Reasons for Inheritance. What Next? Observe the Program in Its Natural Habitat. Get Personal. Strictness. Warnings.

2. Surveying the Scene.

Versions. Part or Whole? Find the Dependencies.

3. Test Now, Test Forever (Diagnosis).

Testing Your Patience. Extreme Testing. An Example Using Test: Modules. Testing Legacy Code. A Final Encouragement.

4. Rewriting (Transplants).

Strategizing. Why Are You Doing This? Style. Comments. Restyling. Variable Renaming. Editing. Line Editing. Antipatterns. Evolution.

5. The Disciplined Perl Program.

Package Variables vs Lexical Variables. Warnings and Strictness. use strict in Detail. use warnings in Detail. Selective Disabling. Caveat Programmer. Perl Poetry.

6. Restructuring (The Operating Table).

Keep It Brief. Cargo Cult Perl. Escaping the Global Variable Trap. Debugging Strategies.

7. Upgrading (Plastic Surgery).

Strategies. Perl 4. Perl 5.000. Perl 5.001. Perl 5.002. Perl 5.003. Perl 5.004. Perl 5.005. Perl 5.6.0. Perl 5.6.1. Perl 5.8.0. Perl 5.8.1. Perl 5.8.2. Perl 5.8.3.

8. Using Modules (Genetic Enhancement).

The Case for CPAN. Using CPAN. Improving Code with Modules. Custom Perls.

9. Analysis (Forensic Pathology).

Static Analysis. Eliminating Superfluous Code. Finding Inefficient Code. Debugging.

10. Increasing Maintainability (Prophylaxis).

Making It Robust. Advanced Brevity. Documentation. Custom Warnings. Version Control System Integration.

11. A Case Study.

The Setup. Triage. Desperately Seeking Sanity. Coming into the 21st Century. Incorporating Modules Effectively, Part 1. Incorporating Modules Effectively, Part 2. Making It Mature, Part 1. Making It Mature, Part 2. Making It Mature, Part 3. Advanced Modification.

12. Conclusion (Prognosis).

In Conclusion. Perl People. A Final Thought.

Appendix: Source Code.

Tie::Array::Bounded. Benchmark::TimeTick. smallprofpp.

Bibliography.

Index.

About the Author.

商品描述(中文翻譯)

目錄:


前言。



Perl還是perl?獲取Perl。Perl的歷史。這本書適合誰?排版慣例。進一步參考資料。Perl版本。Perl 6。致謝。

1. 簡介(第一回應)。


首要事項。繼承的原因。接下來做什麼?觀察程式在其自然環境中的運作。個人化。嚴格性。警告。

2. 環境調查。


版本。部分還是整體?找出相依性。

3. 現在測試,永遠測試(診斷)。


測試你的耐心。極端測試。使用Test:模組的範例。測試舊程式碼。最後的鼓勵。

4. 重寫(移植)。


策略。你為什麼要這樣做?風格。註解。重新排版。變數重新命名。編輯。行編輯。反模式。演化。



5. 純熟的Perl程式。


套件變數 vs 區域變數。警告和嚴格性。詳細介紹use strict。詳細介紹use warnings。選擇性停用。程式設計師注意事項。Perl詩歌。

6. 重組(手術台)。


保持簡潔。崇拜Perl。逃離全域變數陷阱。除錯策略。



7. 升級(整形手術)。


策略。Perl 4。Perl 5.000。Perl 5.001。Perl 5.002。Perl 5.003。Perl 5.004。Perl 5.005。Perl 5.6.0。Perl 5.6.1。Perl 5.8.0。Perl 5.8.1。Perl 5.8.2。Perl 5.8.3。

8. 使用模組(基因增強)。


使用CPAN的理由。使用CPAN。使用模組改進程式碼。自訂Perl。

9. 分析(法醫病理學)。


靜態分析。消除多餘的程式碼。找出效能低下的程式碼。除錯。

10. 提高可維護性(預防措施)。


使其堅固。高級簡潔。文件化。自訂警告。版本控制系統整合。

11. 案例研究。


設定。分流。迫切尋求理智。進入21世紀。有效整合模組,第1部分。有效整合模組,第2部分。使其成熟,第1部分。使其成熟,第2部分。使其成熟,第3部分。高級修改。

12. 結論(預後)。


結論。Perl人。最後的想法。

附錄:原始碼。


Tie::Array::Bounded。Benchmark::TimeTick。smallprofpp。

參考文獻。

索引。

關於作者。