1. Trang chủ
  2. » Công Nghệ Thông Tin

Tài liệu PHP Objects, Patterns and Practice- P1 doc

50 513 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Cấu trúc

  • Prelim

  • Contents at a Glance

  • Contents

  • About the Author

  • About the Technical Reviewer

  • Acknowledgments

  • Introduction to the Third Edition

  • Part 1: Introduction

    • PHP: Design and Management

      • The Problem

      • PHP and Other Languages

      • About This Book

        • Objects

        • Patterns

        • Practice

        • What’s New in the Third Edition

      • Summary

  • Part 2: Objects

    • PHP and Objects

      • The Accidental Success of PHP Objects

        • In the Beginning: PHP/FI

        • Syntactic Sugar: PHP 3

        • PHP 4 and the Quiet Revolution

        • Change Embraced: PHP 5

      • Into the Future

      • Advocacy and Agnosticism: The Object Debate

      • Summary

    • Object Basics

      • Classes and Objects

        • A First Class

        • A First Object (or Two)

      • Setting Properties in a Class

      • Working with Methods

        • Creating a Constructor Method

      • Arguments and Types

        • Primitive Types

        • Primitive Types Matter: An Example

        • Taking the Hint: Object Types

      • Inheritance

        • The Inheritance Problem

        • Working with Inheritance

        • Constructors and Inheritance

        • Invoking an Overridden Method

        • Public, Private, and Protected: Managing Access to Your Classes

        • Accessor Methods

        • The ShopProduct Classes

      • Summary

    • Advanced Features

      • Static Methods and Properties

      • Constant Properties

      • Abstract Classes

      • Interfaces

      • Late Static Bindings: The static Keyword

      • Handling Errors

        • Exceptions

        • Throwing an Exception

        • Subclassing Exception

      • Final Classes and Methods

      • Working with Interceptors

      • Defining Destructor Methods

      • Copying Objects with __clone()

      • Defining String Values for Your Objects

      • Callbacks, Anonymous Functions and Closures

      • Summary

    • Object Tools

      • PHP and Packages

        • PHP Packages and Namespaces

        • Namespaces to the Rescue

        • Using the File System to Simulate Packages

        • Naming the PEAR Way

        • Include Paths

        • Autoload

      • The Class and Object Functions

        • Looking for Classes

        • Learning About an Object or Class

        • Learning About Methods

        • Learning About Properties

        • Learning About Inheritance

        • Method Invocation

      • The Reflection API

        • Getting Started

        • Time to Roll Up Your Sleeves

        • Class

        • Examining Methods

        • Examining Method Arguments

        • Using the Reflection API

      • Summary

    • Objects and Design

      • Defining Code Design

      • Object-Oriented and Procedural Programming

        • Responsibility

        • Cohesion

        • Coupling

        • Orthogonality

      • Choosing Your Classes

      • Polymorphism

      • Encapsulation

      • Forget How to Do It

      • Four Signposts

        • Code Duplication

        • The Class Who Knew Too Much

        • The Jack of All Trades

        • Conditional Statements

      • The UML

        • Class Diagrams

        • Representing Classes

        • Attributes

        • Operations

        • Describing Inheritance and Implementation

        • Associations

        • Aggregation and Composition

        • Describing Use

        • Using Notes

        • Sequence Diagrams

      • Summary

  • Part 3: Patterns

    • What Are Design Patterns? Why Use Them?

      • What Are Design Patterns?

      • A Design Pattern Overview

        • Name

        • The Problem

        • The Solution

        • Consequences

      • The Gang of Four Format

      • Why Use Design Patterns?

        • A Design Pattern Defines a Problem

        • A Design Pattern Defines a Solution

        • Design Patterns Are Language Independent

        • Patterns Define a Vocabulary

        • Patterns Are Tried and Tested

        • Patterns Are Designed for Collaboration

        • Design Patterns Promote Good Design

      • PHP and Design Patterns

      • Summary

    • Some Pattern Principles

      • The Pattern Revelation

      • Composition and Inheritance

        • The Problem

        • Using Composition

      • Decoupling

        • The Problem

        • Loosening Your Coupling

      • Code to an Interface, Not to an Implementation

      • The Concept That Varies

      • Patternitis

      • The Patterns

        • Patterns for Generating Objects

        • Patterns for Organizing Objects and Classes

        • Task-Oriented Patterns

        • Enterprise Patterns

        • Database Patterns

      • Summary

    • Generating Objects

      • Problems and Solutions in Generating Objects

      • The Singleton Pattern

        • The Problem

        • Implementation

        • Consequences

      • Factory Method Pattern

        • The Problem

        • Implementation

        • Consequences

      • Abstract Factory Pattern

        • The Problem

        • Implementation

        • Consequences

        • Prototype

        • The Problem

        • Implementation

      • But That’s Cheating!

      • Summary

    • Patterns for Flexible Object Programming

      • Structuring Classes to Allow Flexible Objects

      • The Composite Pattern

        • The Problem

        • Implementation

        • Consequences

        • Composite in Summary

      • The Decorator Pattern

        • The Problem

        • Implementation

        • Consequences

      • The Facade Pattern

        • The Problem

        • Implementation

        • Consequences

      • Summary

    • Performing and Representing Tasks

      • The Interpreter Pattern

        • The Problem

        • Implementation

        • Interpreter Issues

      • The Strategy Pattern

        • The Problem

        • Implementation

      • The Observer Pattern

        • Implementation

      • The Visitor Pattern

        • The Problem

        • Implementation

        • Visitor Issues

      • The Command Pattern

        • The Problem

        • Implementation

      • Summary

    • Enterprise Patterns

      • Architecture Overview

        • The Patterns

        • Applications and Layers

      • Cheating Before We Start

        • Registry

        • The Problem

        • Implementation

        • Registry, Scope, and PHP

        • Consequences

      • The Presentation Layer

        • Front Controller

        • The Problem

        • Implementation

        • Consequences

        • Application Controller

        • The Problem

        • Implementation

        • Consequences

        • Page Controller

        • The Problem

        • Implementation

        • Consequences

        • Template View and View Helper

        • The Problem

        • Implementation

        • Consequences

      • The Business Logic Layer

        • Transaction Script

        • The Problem

        • Implementation

        • Consequences

        • Domain Model

        • The Problem

        • Implementation

        • Consequences

      • Summary

    • Database Patterns

      • The Data Layer

      • Data Mapper

        • The Problem

        • Implementation

        • Handling Multiple Rows

        • Consequences

      • Identity Map

        • The Problem

        • Implementation

        • Consequences

      • Unit of Work

        • The Problem

        • Implementation

        • Consequences

        • Lazy Load

        • The Problem

        • Implementation

        • Consequences

      • Domain Object Factory

        • The Problem

        • Implementation

        • Consequences

      • The Identity Object

        • The Problem

        • Implementation

        • Consequences

      • The Selection Factory and Update Factory Patterns

        • The Problem

        • Implementation

        • Consequences

      • What’s Left of Data Mapper Now?

      • Summary

  • Part 4: Practice

    • Good (and Bad) Practice

      • Beyond Code

      • Borrowing a Wheel

      • Playing Nice

      • Giving Your Code Wings

      • Documentation

      • Testing

      • Continuous Integration

      • Summary

    • An Introduction to PEAR and Pyrus

      • What Is PEAR?

      • Phar Out with Pyrus

      • Installing a Package

        • PEAR Channels

      • Using a PEAR Package

        • Handling PEAR Errors

      • Creating Your Own PEAR Package

        • package.xml

        • Package Elements

        • The contents Element

        • Dependencies

        • Tweaking Installation with phprelease

        • Preparing a Package for Shipment

        • Setting Up Your Own Channel

        • Defining a Channel with PEAR2_SimpleChannelServer

        • Managing a PEAR Channel with PEAR2_SimpleChannelFrontend

        • Managing a Package

      • Summary

    • Generating Documentation with phpDocumentor

      • Why Document?

      • Installation

      • Generating Documentation

      • DocBlock Comments

      • Documenting Classes

      • File-Level Documentation

      • Documenting Properties

      • Documenting Methods

      • Creating Links in Documentation

      • Summary

    • Version Control with Subversion

      • Why Use Version Control?

      • Getting Subversion

      • Configuring a Subversion Repository

        • Creating a Repository

      • Beginning a Project

      • Updating and Committing

      • Adding and Removing Files and Directories

        • Adding a File

        • Removing a File

        • Adding a Directory

        • Removing Directories

      • Tagging and Exporting a Release

        • Tagging a Project

        • Exporting a Project

      • Branching a Project

      • Summary

    • Testing with PHPUnit

      • Functional Tests and Unit Tests

      • Testing by Hand

      • Introducing PHPUnit

        • Creating a Test Case

        • Assertion Methods

        • Testing Exceptions

        • Running Test Suites

        • Constraints

        • Mocks and Stubs

        • Tests Succeed When They Fail

      • Writing Web Tests

        • Refactoring a Web Application for Testing

        • Simple Web Testing

        • Introducing Selenium

        • Getting Selenium

        • Creating a Test

      • A Note of Caution

      • Summary

    • Automated Build with Phing

      • What Is Phing?

      • Getting and Installing Phing

      • Composing the Build Document

        • Targets

        • Properties

        • Types

        • FileSet

        • PatternSet

        • FilterChain

        • Tasks

        • Echo

        • Copy

        • Input

        • Delete

      • Summary

    • Continuous Integration

      • What Is Continuous Integration?

        • Preparing a Project for CI

        • CI and Version Control

        • Unit Tests

        • Documentation

        • Code Coverage

        • Coding Standards

        • PHP Code Browser

        • Build

      • CruiseControl and phpUnderControl

        • Installing CruiseControl

        • Installing phpUnderControl

        • Installing Your Project

        • Running phpUnderControl / CruiseControl

        • Test Failures

        • Failure Notification

        • Adding Your Own Build Targets

      • Summary

  • Part 5: Conclusion

    • Objects, Patterns, Practice

      • Objects

        • Choice

        • Encapsulation and Delegation

        • Decoupling

        • Reusability

        • Aesthetics

      • Patterns

        • What Patterns Buy Us

        • Tried and Tested

        • Patterns Suggest Other Patterns

        • A Common Vocabulary

        • Patterns Promote Design

        • Patterns and Principles of Design

        • Favor Composition over Inheritance

        • Avoid Tight Coupling

        • Code to an Interface, Not an Implementation

        • Encapsulate the Concept That Varies

      • Practice

        • Testing

        • Documentation

        • Version Control

        • Automated Build

        • Continuous Integration

        • What I Missed

      • Summary

    • Bibliography

      • Books

      • Articles

      • Sites

    • A Simple Parser

      • The Scanner

      • The Parser

  • Index

    • ¦ ¦ ¦

    • ¦ A

    • ¦ B

    • ¦ C

    • ¦ D

    • ¦ E

    • ¦ F

    • ¦ G

    • ¦ H

    • ¦ I

    • ¦ J

    • ¦ K

    • ¦ M

    • ¦ L

    • ¦ N

    • ¦ O

    • ¦ P

    • ¦ Q

    • ¦ R

    • S

    • ¦

    • ¦ T

    • ¦ U

    • ¦ V

    • ¦ X

    • ¦ W ¦ Z

Nội dung

this print for content only—size & color not accurate   CYAN   MAGENTA   YELLOW   BLACK   PANTONE 123 C BOOKS FOR PROFESSIONALS BY PROFESSIONALS ® Matt Zandstra, Author of Sams Teach Yourself PHP in 24 Hours US $44.99 Shelve in: PHP User level: Intermediate www.apress.com SOURCE CODE ONLINE Companion eBook See last page for details on $10 eBook version ISBN 978-1-4302-2925-4 9 781430 229254 5 44 9 9 PHP Objects, Patterns, and Practice THIRD EDITION Dear Reader, Over the past decade, PHP has embraced the object-oriented revolution. The language itself, the developers who work with it, and the applications they build, all increasingly share a focus on objects and object-oriented design. Another movement, separate but related, has taken root as well. That is the use of tools and techniques that help to ensure the success of projects, the efficacy of teams, and the quality of code. You’ll begin with an overview of PHP's object-oriented features, introducing key topics like class declaration, object instantiation, inheritance, and method and property encapsulation. You'll also learn about advanced topics including static methods and properties, abstract classes, interfaces, exception handling, object cloning, namespaces, closures and more. The next part of this book is devoted to design patterns, a vocabulary for applying elegant solutions to common problems in software development. You’ll learn about pattern concepts and discover how to implement several key pat- terns in your PHP applications. You’ll also find chapters on enterprise and data- base patterns. In the last section of this book, you will find practices and tools for managing your codebase and for collaborating with others in development. These include Phing, PHPUnit, phpDocumentor, PEAR, and Subversion. You’ll also learn how to use Continuous Integration, a system that brings all these tools together and automates them. I wrote PHP Objects, Patterns, and Practice to provide the kind of overview of code design and project practice I wish had been available when I first started to develop serious PHP applications. I hope this book inspires pleasure in coding and teaches you to build systems that are elegant in both design and management. Matt Zandstra THE APRESS ROADMAP Pro PHP: Patterns, Frameworks, Testing, and More PHP Objects, Patterns, and Practice, Third Edition Pro PHP Refactoring with Test Driven Design PHP Object-Oriented Solutions Pro PHP and jQuery Practical Web 2.0 Applications with PHP PHP for Absolute Beginners Beginning PHP and MySQL, Third Edition Zandstra Companion eBook Available PHP Objects, Patterns, and Practice 7.5 x 9.25 spine = 1.000" 536 page count THE EXPERT’S VOICE ®  IN OPEN SOURCE THIRD EDITION Matt Zandstra Build powerful code by mastering PHP’s object-oriented enhancements, design patterns, and essential development tools THIRD EDITION PHP Objects, Patterns, and Practice Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. i PHP Objects, Patterns, and Practice Third Edition ■ ■ ■ Matt Zandstra Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. ii PHP Objects, Patterns, and Practice, Third Edition Copyright © 2010 by Matt Zandstra All rights reserved. No part of this work may be reproduced or transmitted in any form or by any means, electronic or mechanical, including photocopying, recording, or by any information storage or retrieval system, without the prior written permission of the copyright owner and the publisher. ISBN-13 (pbk): 978-1-4302-2925-4 ISBN-13 (electronic): 978-1-4302-2926-1 Printed and bound in the United States of America 9 8 7 6 5 4 3 2 1 Trademarked names may appear in this book. Rather than use a trademark symbol with every occurrence of a trademarked name, we use the names only in an editorial fashion and to the benefit of the trademark owner, with no intention of infringement of the trademark. President and Publisher: Paul Manning Lead Editor: Michelle Lowman, Matt Wade Technical Reviewer: Wes Hunt Editorial Board: Clay Andres, Steve Anglin, Mark Beckner, Ewan Buckingham, Gary Cornell, Jonathan Gennick, Jonathan Hassell, Michelle Lowman, Matthew Moodie, Duncan Parkes, Jeffrey Pepper, Frank Pohlmann, Douglas Pundick, Ben Renow-Clarke, Dominic Shakeshaft, Matt Wade, Tom Welsh Coordinating Editor: Jim Markham Copy Editor: Tracy Brown Collins Compositor: MacPS, LLC Indexer: Toma Mulligan Artist: April Milne Cover Designer: Anna Ischenko Distributed to the book trade worldwide by Springer-Verlag New York, Inc., 233 Spring Street, 6th Floor, New York, NY 10013. Phone 1-800-SPRINGER, fax 201-348-4505, e-mail orders-ny@springer-sbm.com , or visit www.springeronline.com. For information on translations, please e-mail info@apress.com, or visit www.apress.com. Apress and friends of ED books may be purchased in bulk for academic, corporate, or promotional use. eBook versions and licenses are also available for most titles. For more information, reference our Special Bulk Sales–eBook Licensing web page at www.apress.com/info/bulksales. The information in this book is distributed on an “as is” basis, without warranty. Although every precaution has been taken in the preparation of this work, neither the author(s) nor Apress shall have any liability to any person or entity with respect to any loss or damage caused or alleged to be caused directly or indirectly by the information contained in this work. The source code for this book is available to readers at www.apress.com. You will need to answer questions pertaining to this book in order to successfully download the code. Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. iii Contents at a Glance ■Contents at a Glance iii ■Contents v ■About the Author xvii ■About the Technical Reviewer xviii ■Acknowledgments xix ■Introduction to the Third Edition xx Part 1: Introduction 1 ■Chapter 1: PHP: Design and Management 3 Part 2: Objects 9 ■Chapter 2: PHP and Objects 11 ■Chapter 3: Object Basics 15 ■Chapter 4: Advanced Features 41 ■Chapter 5: Object Tools 71 ■Chapter 6: Objects and Design 99 Part 3: Patterns 121 ■Chapter 7: What Are Design Patterns? Why Use Them? 123 ■Chapter 8: Some Pattern Principles 131 ■Chapter 9: Generating Objects 145 ■Chapter 10: Patterns for Flexible Object Programming 169 ■Chapter 11: Performing and Representing Tasks 189 ■Chapter 12: Enterprise Patterns 221 ■Chapter 13: Database Patterns 275 Part 4: Practice 315 ■Chapter 14: Good (and Bad) Practice 317 ■Chapter 15: An Introduction to PEAR and Pyrus 323 ■Chapter 16: Generating Documentation with phpDocumentor 347 ■Chapter 17: Version Control with Subversion 361 ■Chapter 18: Testing with PHPUnit 379 ■Chapter 19: Automated Build with Phing 407 ■Chapter 20: Continuous Integration 427 Part 5: Conclusion 451 ■Chapter 21: Objects, Patterns, Practice 453 ■Appendix A: Bibliography 463 ■Appendix B: A Simple Parser 467 ■Index 219 Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. iv Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. v Contents ■Contents at a Glance iii ■Contents v ■About the Author xvii ■About the Technical Reviewer xviii ■Acknowledgments xix ■Introduction to the Third Edition xx Part 1: Introduction 1 ■Chapter 1: PHP: Design and Management 3 The Problem 3 PHP and Other Languages 4 About This Book 5 Objects 6 Patterns 6 Practice 6 What’s New in the Third Edition 7 Summary 7 Part 2: Objects 9 ■Chapter 2: PHP and Objects 11 The Accidental Success of PHP Objects 11 In the Beginning: PHP/FI 11 Syntactic Sugar: PHP 3 11 PHP 4 and the Quiet Revolution 12 Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. ■ CONTENTS vi Change Embraced: PHP 5 13 Into the Future 14 Advocacy and Agnosticism: The Object Debate 14 Summary 14 ■Chapter 3: Object Basics 15 Classes and Objects 15 A First Class 15 A First Object (or Two) 16 Setting Properties in a Class 17 Working with Methods 19 Creating a Constructor Method 21 Arguments and Types 22 Primitive Types 22 Taking the Hint: Object Types 25 Inheritance 27 The Inheritance Problem 27 Working with Inheritance 31 Public, Private, and Protected: Managing Access to Your Classes 35 Summary 39 ■Chapter 4: Advanced Features 41 Static Methods and Properties 41 Constant Properties 44 Abstract Classes 45 Interfaces 47 Late Static Bindings: The static Keyword 48 Handling Errors 51 Exceptions 52 Final Classes and Methods 57 Working with Interceptors 58 Defining Destructor Methods 62 Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. ■ CONTENTS vii Copying Objects with __clone() 63 Defining String Values for Your Objects 65 Callbacks, Anonymous Functions and Closures 66 Summary 70 ■Chapter 5: Object Tools 71 PHP and Packages 71 PHP Packages and Namespaces 71 Autoload 80 The Class and Object Functions 81 Looking for Classes 82 Learning About an Object or Class 83 Learning About Methods 84 Learning About Properties 85 Learning About Inheritance 85 Method Invocation 86 The Reflection API 87 Getting Started 87 Time to Roll Up Your Sleeves 88 Examining a Class 90 Examining Methods 91 Examining Method Arguments 93 Using the Reflection API 94 Summary 97 ■Chapter 6: Objects and Design 99 Defining Code Design 99 Object-Oriented and Procedural Programming 100 Responsibility 103 Cohesion 104 Coupling 104 Orthogonality 104 Choosing Your Classes 105 Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. ■ CONTENTS viii Polymorphism 106 Encapsulation 107 Forget How to Do It 108 Four Signposts 109 Code Duplication 109 The Class Who Knew Too Much 109 The Jack of All Trades 109 Conditional Statements 110 The UML 110 Class Diagrams 110 Sequence Diagrams 117 Summary 119 Part 3: Patterns 121 ■Chapter 7: What Are Design Patterns? Why Use Them? 123 What Are Design Patterns? 123 A Design Pattern Overview 125 Name 125 The Problem 125 The Solution 126 Consequences 126 The Gang of Four Format 126 Why Use Design Patterns? 127 A Design Pattern Defines a Problem 127 A Design Pattern Defines a Solution 127 Design Patterns Are Language Independent 127 Patterns Define a Vocabulary 127 Patterns Are Tried and Tested 128 Patterns Are Designed for Collaboration 128 Design Patterns Promote Good Design 128 PHP and Design Patterns 129 Summary 129 Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. [...]... the success of a project Aside from this introduction and a brief conclusion, the book is divided into three main parts: objects, patterns, and practice Objects I begin Part 2 with a quick look at the history of PHP and objects, charting their shift from afterthought in PHP 3 to core feature in PHP 5 You can still be an experienced and successful PHP programmer with little or no knowledge of objects... development of PHP s object-oriented features We will look at • PHP/ FI 2.0: PHP, but not as we know it • PHP 3: Objects make their first appearance • PHP 4: Object-oriented programming grows up • PHP 5: Objects at the heart of the language • PHP 6: A glimpse of the future The Accidental Success of PHP Objects With so many object-oriented PHP libraries and applications in circulation, to say nothing of PHP 5’s... Matt Zandstra has worked as a web programmer, consultant, and writer for over a decade He is a senior developer at Yahoo, and a freelance coder and writer Matt is the author of Teach Yourself PHP in 24 Hours (SAMS) and a contributor to DHTML Unleashed (SAMS) He has written articles for Linux Magazine, Zend.com, IBM DeveloperWorks, and php| architect Magazine, among others He works primarily with PHP and. .. Leon Atkinson wrote a piece about PHP and patterns for Zend in 2001 , and Harry Fuecks launched his journal at www.phppatterns.com (now largely mothballed, it seems) in 2002 Pattern-based framework projects such as BinaryCloud began to emerge, as well as tools for automated testing and documentation The release of the first PHP 5 beta in 2003 ensured the future of PHP as a language for objectoriented... idea for PHP Objects, Patterns, and Practice, I felt I was swimming against the tide Many pattern implementations in PHP felt like glorified workarounds due to limitations in the language These days, though, it can be hard to keep up with pace of innovation in PHP objects, design, and project practice If that's a problem, well, it's the kind you want to have Especially if you have the tools at hand to... with phprelease 340 Preparing a Package for Shipment 341 Setting Up Your Own Channel 341 Summary 346 ■Chapter 16: Generating Documentation with phpDocumentor 347 Why Document? 347 Installation 348 Generating Documentation 349 DocBlock Comments 350 Documenting Classes 352 File-Level Documentation... watermark CHAPTER 1 ■ PHP: DESIGN AND MANAGEMENT The Java language itself deployed many core patterns in its API, but it wasn’t until the late ’90s that design patterns seeped into the consciousness of the coding community at large Patterns quickly infected the computer sections of High Street bookstores, and the first flame wars began on mailing lists and forums Whether you think that patterns are a powerful... tested early and hard As you will see in the next chapter, PHP started life as a set of macros for managing personal home pages With the advent of PHP 3 and, to a greater extent, PHP 4, the language rapidly became the successful power behind large enterprise Web sites In many ways, though, the legacy of PHP s beginnings carried through into script design and project management In some quarters, PHP retained... architects of PHP 3 were Zeev Suraski and Andi Gutmans PHP 3 was a complete rewrite of PHP/ FI 2.0, but objects were not deemed a necessary part of the new syntax Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark 11 CHAPTER 2 ■ PHP AND OBJECTS According to Zeev Suraski, support for classes was added almost as an afterthought (on 27 August 1997, to be precise) Classes and objects... Instead, I examine, in the context of PHP, some wellestablished design principles and some key patterns (particularly those inscribed in Design Patterns, the Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark 5 CHAPTER 1 ■ PHP: DESIGN AND MANAGEMENT classic Gang of Four book) Finally, I move beyond the strict limits of code to look at tools and techniques that can help to ensure . management. Matt Zandstra THE APRESS ROADMAP Pro PHP: Patterns, Frameworks, Testing, and More PHP Objects, Patterns, and Practice, Third Edition Pro PHP Refactoring. Driven Design PHP Object-Oriented Solutions Pro PHP and jQuery Practical Web 2.0 Applications with PHP PHP for Absolute Beginners Beginning PHP and MySQL, Third

Ngày đăng: 26/01/2014, 09:20

TỪ KHÓA LIÊN QUAN