Copyright
Brief Table of Contents
Table of Contents
Foreword
Preface
Acknowledgments
About this Book
1. Getting started with AOP
Chapter 1. Introducing AOP
1.1. What is AOP?
1.1.1. Features
1.1.2. Benefits
1.1.3. AOP in your daily life
1.2. Hello, World
1.3. Summary
Chapter 2. Acme Car Rental
2.1. Start a new project
2.1.1. Business requirements
2.1.2. Necessary nonfunctional requirements
2.2. Life without AOP
2.2.1. Write the business logic
2.2.2. Testing the business logic
2.2.3. Add logging
2.2.4. Introducing defensive programming
2.2.5. Working with transactions and retries
2.2.6. Handling exceptions
2.2.7. Refactor without AOP
2.3. The cost of change
2.3.1. Requirements will change
2.3.2. Small versus large projects
2.3.3. Signature changes
2.3.4. Working on a team
2.4. Refactor with AOP
2.4.1. Start simple and isolate the logging
2.4.2. Refactor defensive programming
2.4.3. Creating an aspect for transactions and retries
2.4.4. Put exception handling into its own class
2.5. Summary
2. The Fundamentals of AOP
Chapter 3. Call this instead: intercepting methods
3.1. Method interception
3.1.1. PostSharp method interception
3.1.2. Castle DynamicProxy method interception
3.2. Real-world example: data transactions
3.2.1. Ensuring data integrity with begin and commit
3.2.2. When transactions go bad: rollback
3.2.3. When all else fails, retry
3.3. Real-world example: threading
3.3.1. The basics of .NET threading