PacktLib: Persistence in PHP with Doctrine ORM

Persistence in PHP with Doctrine ORM

Credits

About the Author

About the Reviewers

www.PacktPub.com

Preface

Getting Started with Doctrine 2

Prerequisites

Understanding the concepts behind Doctrine

Creating a project structure

Installing Composer

Installing Doctrine

Bootstrapping the app

Using Doctrine's Entity Manager

Configuring Doctrine command-line tools

Summary

Entities and Mapping Information

Creating the Entity class

Generating getters and setters

Mapping with Doctrine annotations

Understanding Doctrine Mapping Types

Creating the database schema

Installing Data fixtures

Creating a simple UI

Summary

Associations

Getting started with the Doctrine associations

Understanding the @ManyToOne and @OneToMany annotations with the comment system

Understanding the @ManyToMany annotation with tags

Summary

Building Queries

Understanding DQL

Using the entity repositories

Getting started with Query Builder

Filtering by tag

Counting comments

Summary

Going Further

Implementing inheritance

Getting started with events

Writing native queries

Summary

Index