2006 aw applying domain driven design and patterns wit

923 28 0
  • Loading ...
1/923 trang
Tải xuống

Thông tin tài liệu

Ngày đăng: 25/03/2019, 17:10

ApplyingDomain-DrivenDesignandPatterns:With ExamplesinC#and NET,1/e ByJimmyNilsson Publisher:AddisonWesleyProfessional PubDate:May08,2006 PrintISBN-10:0-321-26820-2 PrintISBN-13:978-0-321-26820-4 Pages:576 TableofContents |Index "[This]isabookaboutdesigninthe NETworld,driveninanagilemannerandinfused withtheproductsoftheenterprisepatternscommunity [It]showsyouhowtobegin applyingsuchthingsasTDD,objectrelationalmapping,andDDDto NET projects techniquesthatmanydevelopersthinkarethekeytofuturesoftware development Asthetechnologygetsmorecapableandsophisticated,itbecomesmore importanttounderstandhowtouseitwell Thisbookisavaluablesteptowardadvancing thatunderstanding." MartinFowler,authorofRefactoringandPatternsofEnterpriseApplicationArchitecture Patterns,Domain-DrivenDesign(DDD),andTest-DrivenDevelopment(TDD)enable architectsanddeveloperstocreatesystemsthatarepowerful,robust,andmaintainable Now,there'sacomprehensive,practicalguidetoleveragingallthesetechniquesprimarily inMicrosoft NETenvironments,butthediscussionsarejustasusefulforJavadevelopers DrawingonseminalworkbyMartinFowler(PatternsofEnterpriseApplicationArchitecture) andEricEvans(Domain-DrivenDesign),JimmyNilssonshowshowtocreatereal-world architecturesforany NETapplication Nilssonilluminateseachprinciplewithclear,wellannotatedcodeexamplesbasedonC#1.1and2.0 Hisexamplesanddiscussionswillbe valuablebothtoC#developersandthoseworkingwithother NETlanguagesandany databasesevenwithotherplatforms,suchasJ2EE Coverageincludes · Quickprimersonpatterns,TDD,andrefactoring · Usingarchitecturaltechniquestoimprovesoftwarequality · Usingdomainmodelstosupportbusinessrulesandvalidation · ApplyingenterprisepatternstoprovidepersistencesupportviaNHibernate · PlanningeffectivelyforthepresentationlayerandUItesting · DesigningforDependencyInjection,AspectOrientation,andothernewparadigms ApplyingDomain-DrivenDesignandPatterns:With ExamplesinC#and NET,1/e ByJimmyNilsson Publisher:AddisonWesleyProfessional PubDate:May08,2006 PrintISBN-10:0-321-26820-2 PrintISBN-13:978-0-321-26820-4 Pages:576 TableofContents |Index Copyright PraiseforApplyingDomain-DrivenDesignandPatterns AbouttheAuthor Forewords Preface:BridgingGaps Acknowledgments PartI: Background Chapter1 ValuestoValue:OrEmbarrassingRamblingsWhenSelf-Reflecting ontheLastFewYears OverallValues ArchitectureStylestoValue ProcessIngredientstoValue ContinuousIntegration Don'tForgetAboutOperations Summary Chapter2 AHeadStartonPatterns ALittleBitAboutPatterns DesignPatterns ArchitecturalPatterns DesignPatternsforSpecificTypesofApplications DomainPatterns Summary Chapter3 TDDandRefactoring Test-DrivenDevelopment(TDD) MocksandStubs Refactoring Summary PartII: ApplyingDDD Chapter4 ANewDefaultArchitecture TheBasisoftheNewDefaultArchitecture AFirstSketch MakingaFirstAttemptatHookingtheUItotheDomainModel YetAnotherDimension Summary Chapter5 MovingFurtherwithDomain-DrivenDesign RefiningtheDomainModelThroughSimpleTDDExperimentation FluentInterface Summary Chapter6 PreparingforInfrastructure POCOasaLifestyle DealingwithSaveScenarios Let'sBuildtheFakeMechanism DatabaseTesting Querying Summary Chapter7 LettheRulesRule CategorizationofRules PrinciplesforRulesandTheirUsage StartingtoCreateanAPI RequirementsforaBasicRulesAPIRelatedtoPersistence FocusonDomain-RelatedRules ExtendingtheAPI RefiningtheImplementation BindingtothePersistenceAbstraction GenericsandAnonymousMethodstotheRescue WhatOthersHaveDone Summary PartIII: ApplyingPoEaa Chapter8 InfrastructureforPersistence RequirementsonthePersistenceInfrastructure WheretoStoreData Approach Classification AnotherClassification:InfrastructurePatterns Summary Chapter9 PuttingNHibernateintoAction WhyNHibernate? AShortIntroductiontoNHibernate RequirementsofthePersistenceInfrastructure Classification AnotherClassification:InfrastructurePatterns NHibernateandDDD Summary PartIV: What'sNext? Chapter10 DesignTechniquestoEmbrace ContextIsKing AnIntroductiontoSOA InversionofControlandDependencyInjection Aspect-OrientedProgramming(AOP) Summary Chapter11 FocusontheUI APrepilogue TheModel-View-ControllerPattern Test-DrivingaWebForm MappingandWrapping Summary Epilogue PartV: Appendices AppendixA OtherDomainModelStyles Object-OrientedDataModel,SmartServiceLayer,andDocuments TheDatabaseModelIstheDomainModel PragmatismandtheNontraditionalApproach Summary AppendixB CatalogofDiscussedPatterns AbstractFactory[GoFDesignPatterns] Aggregate[EvansDDD] BoundedContext[EvansDDD] ChainofResponsibility[GoFDesignPatterns] ClassTableInheritance[FowlerPoEAA] Coarse-GrainedLock[FowlerPoEAA] CollectingParameterPattern[BeckSBPP] ConcreteTableInheritance[FowlerPoEAA] DataMapper[FowlerPoEAA] DataTransferObjects[FowlerPoEAA] Decorator[GoFDesignPatterns] DependencyInjection DomainModel[FowlerPoEAA] EmbeddedValue[FowlerPoEAA] Entity[EvansDDD] Factory[EvansDDD] FactoryMethod[GoFDesignPatterns] ForeignKeyMapping[FowlerPoEAA] GenerationGap[VlissidesPatternHatching] IdentityField[FowlerPoEAA] IdentityMap[FowlerPoEAA] ImplicitLock[FowlerPoEAA] LayerSupertype[FowlerPoEAA] Layers[POSA] LazyLoad[FowlerPoEAA] MetadataMapping[FowlerPoEAA] ModelViewController[FowlerPoEAA] ModelViewPresenter[FowlerPoEAA2] Notification[FowlerPoEAA2] NullObject[WoolfNullObject] OptimisticOfflineLock[FowlerPoEAA] PartyArchetype[Arlow/NeustadtArchetypePatterns] PessimisticOfflineLock[FowlerPoEAA] PipesandFilters[POSA] PresentationModel[FowlerPoEAA2] Proxy[GoFDesignPatterns] QueryObject[FowlerPoEAA] Recordset[FowlerPoEAA] Reflection[POSA] Registry[FowlerPoEAA] RemoteFaỗade[FowlerPoEAA] Repository[EvansDDD] SeparatedPresentation[FowlerPoEAA2] ServiceLayer[FowlerPoEAA] ServiceLocator[Alur/Crupi/MalksCoreJ2EEPatterns] Services[EvansDDD] SingleTableInheritance[FowlerPoEAA] Singleton[GoFDesignPatterns] Specification[EvansDDD] State[GoFDesignPatterns] TableModule[FowlerPoEAA] TemplateMethod[GoFDesignPatterns] TransactionScript[FowlerPoEAA] UnitofWork[FowlerPoEAA] ValueObject[EvansDDD] References Index Copyright Manyofthedesignationsusedbymanufacturersandsellersto distinguishtheirproductsareclaimedastrademarks Where thosedesignationsappearinthisbook,andthepublisherwas awareofatrademarkclaim,thedesignationshavebeenprinted withinitialcapitallettersorinallcapitals Theauthorandpublisherhavetakencareinthepreparationof thisbook,butmakenoexpressedorimpliedwarrantyofany kindandassumenoresponsibilityforerrorsoromissions No liabilityisassumedforincidentalorconsequentialdamagesin connectionwithorarisingoutoftheuseoftheinformationor programscontainedherein Thepublisheroffersexcellentdiscountsonthisbookwhen orderedinquantityforbulkpurchasesorspecialsales,which mayincludeelectronicversionsand/orcustomcoversand contentparticulartoyourbusiness,traininggoals,marketing focus,andbrandinginterests Formoreinformation,please contact: U.S CorporateandGovernmentSales (800)382-3419 corpsales@pearsontechgroup.com ForsalesoutsidetheUnitedStatespleasecontact: InternationalSales international@pearsoned.com VisitusontheWeb:www.awprofessional.com LibraryofCongressCataloging-in-PublicationData Nilsson,Jimmy ApplyingdomaindrivendesignandpatternswithexamplesinC#and NET/JimmyNilsson p cm Includesbibliographicalreferences ISBN0-321-26820-2 Computersoftware-Development C#(Computerprogramlanguage)3 Microsoft NET I QA76.76.D47N6452006 005.1 dc22 2006004371 Copyright©2006PearsonEducation,Inc Allrightsreserved PrintedintheUnitedStatesofAmerica This publicationisprotectedbycopyright,andpermissionmustbe obtainedfromthepublisherpriortoanyprohibited reproduction,storageinaretrievalsystem,ortransmissionin anyformorbyanymeans,electronic,mechanical, photocopying,recording,orlikewise Forinformationregarding permissions,writeto: PearsonEducation,Inc RightsandContractsDepartment 75ArlingtonStreet,Suite300 Boston,MA02116 Fax:(617)848-7047 TextprintedintheUnitedStatesonrecycledpaperatR R DonnelleyinCrawfordsville,Indiana Firstprinting,May2006 Dedication ToLotta,Tim,andLeo:thecentersofmyuniverse mechanisms TDDproblems self-shunting Seovi´c,Aleksandar SeparatedPresentation2nd server-sidedatabasesversusclientsidedatabases ServiceLayer2nd example ServiceLocator2nd3rd versusDependencyInjection InversionofControl ServiceOrientation(SO) Services SOA designof interationswithotherservices policy scaling schema unavailableservices versioning Webservices servicevalidation,domain-relatedrules SessionFactory set-basedprocessingmethods locating SetController() SetFieldWhenReconstitutingFromPersistence()2nd SetterDependencyInjection sharednothingcluster sharinginstances SingleResponsibilityPrinciple(SRP)2nd3rd SingleTableInheritance single-entity-orientedBusinessLogic singletons2nd Skjoldborg,Christoffer MVCpattern SnapDAL snapshots SO(ServiceOrientation) partitioningDomainModel SOA2nd clientserverand complexmessagingprocesses one-wayasynchronousmessaging OO RichClientapplications scalability scalingservices services designof interactionswithotherservices policy schema unavailableservices Webservices WebService SoftwareFactories,up-frontarchitecturedesign Specification2nd complexrules generics queries speed,PI(costfor) Spolsky,Joel Spring.NET,DependencyInjection SQL,O/RMapper SrcPanel SRP(SingleResponsibilityPrinciple)2nd3rd StashPanel State2nd addingtoexistingclasses applicationstate userstate statefulDomainModelinstantiation statelessDomainModelinstantiation StateModifier Statepattern states location,principlesforrules principlesforrules savablestates,creatingAPIs storingdata(persistenceinfrastructure)2nd choosinghowtostoredata filesystem objectdatabase RAM relationaldatabase resourcemanagers Strategy,DesignPatterns strings stubs2nd teststubs styles sub-results,TDD subclassing sublists submittingdata,example subsetDomainModelinstantiation Szyperski Index [A][B][C][D][E][F][G][H][I][J][K][L][M][N][O][P][Q] [R][S][T][U][V][W][X][Y] TableModule2nd tables,mappingclassesontotablesversusmapptingtables ontoclasses TakeOrder() TDD(Test-DrivenDevelopment)2nd3rd API compilers demonstration designeffects clientcontrol coupling interfaces/factories sub-results documentation DomainModels flow2nd independence maintenance mockobjects problems losingtheoverview maintainingcode persistentdata security UI reasonsforusing refactoring2nd reusability testingstubs unittestingGUI displaydynamics displayingobjecttypes pickingobjects unittests workingwithdifficultcomponents TemplateMethod testing dataaccess databasetesting evolvingschemas maintainingthestateofthedatabaseduringtherun resettingdatausedbyatestbeforethetest resettingdatabasebeforeeachtest separatingthetestingoftheunitfromthetestingofthe calltothe problemsdoingsmallscaleintegrationtesting,Repositories problemstestingRepositories unittesting domainmodel example GUI mockingwithNMock TDDofGUI testingstubs consequences tests,naming teststub timeoutwatchers tools,cleaningtools(refactoring) ToString() TotalAmount TotalCredit TotalCreditService totalsforeachorder tracing mechanisms notracing tradeoffs transactionabstraction TransactionScript2nd3rd transactions2nd NHibernate transitions domain-relatedrules incorrecttransitions,APIs two-wayruleschecking typeexplosion Index [A][B][C][D][E][F][G][H][I][J][K][L][M][N][O][P][Q] [R][S][T][U][V][W][X][Y] ubiquitouslanguage UI(userinterface) DomainModel addingorders listordersforcustomers SeparatedPresentationpattern reusingrules TDDproblems testing UML(UnifiedModelingLanguage)2nd UnitofWorkpattern2nd3rd NHibernate savescenarios savingorders unittesting domainmodel example displayingcandytypes handlingdisplaydynamics pickingobjects GUI mocking:withNMock TDDofGUI displaydynamics displayingobjecttypes pickingobjects unittests Fake structureofRepositoryrelatedtests TDD up-frontarchitecturedesign consistency MDA reusingideas SoftwareFactories UpdateOrderStatus() usecases,modelfocus UserBC UserDao UserDaoStub UserInfo2nd userinterface(UI) DomainModel addingorders listordersforcustomers SeparatedPresentationpattern reusingrules TDDproblems testing usernumbers userstate Index [A][B][C][D][E][F][G][H][I][J][K][L][M][N][O][P][Q] [R][S][T][U][V][W][X][Y] validation,reactivevalidation validationhooks,NHibernate validationinterfaces,makingpluggable ValueObjects2nd PI values modelfocus DDD usecases VariationPoint() variations VB6(VisualBasic6) VB6,filteringindatabaseswithhugeparameters versioning Aggregates services,SOA versions,NHibernate viewinterfaces,simplifyingthroughadapters(MVC pattern) viewMock Views combiningwithControllers(MVCpattern) decouplingControllers VisualBasic6(VB6) Index [A][B][C][D][E][F][G][H][I][J][K][L][M][N][O][P][Q] [R][S][T][U][V][W][X][Y] waterfallprocess webforms domainmodel example GUI implementing mockingwithNMock TDDofGUI unittesting WebService howfine-grained? SOA Webservices Windsor WinForms ApplicationServerand withoutanApplicationServer wrapping considerationsforusing DomainModelwithPresentationModel Index [A][B][C][D][E][F][G][H][I][J][K][L][M][N][O][P][Q] [R][S][T][U][V][W][X][Y] XML,MetadataMappingpattern XP(ExtremeProgramming)2nd Index [A][B][C][D][E][F][G][H][I][J][K][L][M][N][O][P][Q] [R][S][T][U][V][W][X][Y] YAML Young,Gregory2nd codesmells snapshots ...· DesigningforDependencyInjection,AspectOrientation, and othernewparadigms Applying Domain- Driven Design and Patterns: With ExamplesinC# and NET,1/e ByJimmyNilsson... AHeadStarton Patterns ALittleBitAbout Patterns Design Patterns Architectural Patterns Design Patterns forSpecificTypesofApplications Domain Patterns Summary Chapter3 TDD and Refactoring... Iamcertainthat Applying Domain- Driven Design and Patterns willbecomeamandatorytitleinthe enterprisebookshelf." MikaelFreidlitz,vicepresidentofContent and Knowledge ProgramsatIASA "Domain- Driven Design isanimportanttechniquethatcan
- Xem thêm -

Xem thêm: 2006 aw applying domain driven design and patterns wit , 2006 aw applying domain driven design and patterns wit , Chapter 1. Values to Value: Or Embarrassing Ramblings When Self-Reflecting on the Last Few Years, Chapter 2. A Head Start on Patterns, Chapter 4. A New Default Architecture, Chapter 5. Moving Further with Domain-Driven Design, Chapter 7. Let the Rules Rule, Chapter 9. Putting NHibernate into Action, Chapter 10. Design Techniques to Embrace, Chapter 11. Focus on the UI, Appendix A. Other Domain Model Styles, Appendix B. Catalog of Discussed Patterns

Mục lục

Xem thêm

Gợi ý tài liệu liên quan cho bạn