官术网_书友最值得收藏!

Fowler's patterns

In 2002, Martin Fowler wrote Patterns of Enterprise Application Architecture, which described 40 or so patterns he often encountered while building enterprise applications.

Unlike the GoF book, which described design patterns, Fowler's book was about architectural patterns. Hence, they describe patterns at a much higher level of abstraction and are largely programming language agnostic.

Fowler's patterns are organized as follows:

  • Domain logic patterns: These include domain model, transaction script, service layer, and table module
  • Data source architectural patterns: These include row data gateway, table data gateway, data mapper, and active record
  • Object-relational behavioral patterns: These include Identity Map, Unit of Work, and Lazy Load
  • Object-relational structural patterns: These include Foreign Key Mapping, Mapping, Dependent Mapping, Association Table Mapping, Identity Field, Serialized LOB, Embedded Value, Inheritance Mappers, Single Table Inheritance, Concrete Table Inheritance, and Class Table Inheritance
  • Object-relational metadata mapping patterns: These include Query Object, Metadata Mapping, and repository
  • Web presentation patterns: These include Page Controller, Front Controller, Model View Controller, Transform View, Template View, Application Controller, and Two-Step View
  • Distribution patterns: These include Data Transfer Object and Remote Facade
  • Offline concurrency patterns: These include Coarse-Grained Lock, Implicit Lock, Optimistic Offline Lock, and Pessimistic Offline Lock
  • Session state patterns: These include Database Session State, Client Session State, and Server Session State
  • Base patterns: These include Mapper, Gateway, Layer Supertype, Registry, Value Object, Separated Interface, Money, Plugin, Special Case, Service Stub, and Record Set

Almost all of these patterns would be useful to know while architecting a Django application. In fact, Fowler's website at http://martinfowler.com/eaaCatalog/ has an excellent catalog of these patterns online. I highly recommend that you check them out.

Django also implements a number of these patterns. The following table lists a few of them:

主站蜘蛛池模板: 儋州市| 南乐县| 洛川县| 赤峰市| 松滋市| 洛南县| 郓城县| 墨玉县| 泗阳县| 蓬安县| 南华县| 普陀区| 温州市| 吉隆县| 平远县| 南川市| 荔波县| 湘乡市| 新乡县| 建湖县| 东台市| 获嘉县| 遵化市| 萨嘎县| 镇江市| 仁寿县| 饶阳县| 阿克苏市| 始兴县| 罗源县| 葵青区| 海盐县| 佛坪县| 阿荣旗| 华安县| 弋阳县| 连云港市| 兴宁市| 兴安县| 墨脱县| 安康市|