spring.net introduction
DESCRIPTION
Introduction to Spring.NETTRANSCRIPT
Spring.NETIntroduction
Oliver Paulus
Spring.NET Introduction
Oliver Paulus
21. April 2007
Spring.NETIntroduction
Oliver Paulus
Table of contentsPart I / IV
1 Sample application overviewLayersAOP
2 What is Spring(.NET)?Benefits
3 Spring overview
Spring.NETIntroduction
Oliver Paulus
Table of contentsPart I / IV
1 Sample application overviewLayersAOP
2 What is Spring(.NET)?Benefits
3 Spring overview
Spring.NETIntroduction
Oliver Paulus
Table of contentsPart I / IV
1 Sample application overviewLayersAOP
2 What is Spring(.NET)?Benefits
3 Spring overview
Spring.NETIntroduction
Oliver Paulus
Table of contentsPart II / IV
4 Spring object containerwithout DIP/IoC object containerwith DIP/IoC object containerFeaturesBenefits
Spring.NETIntroduction
Oliver Paulus
Table of contentsPart III / IV
5 Spring AOPwithout AOPwith AOPAOP grammarBenefits
Spring.NETIntroduction
Oliver Paulus
Table of contentsPart IV / IV
6 Spring WebFeatures
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
Part I
Sample application / Spring overview
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
Sample application overviewLayers
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
Sample application overviewAOP
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
What is Spring(.NET)?
Spring is a famous open source application framework forenterprise application development in Java.
The project started 2002 from infrastructure code publishedfor ”Expert One-to-one J2EE Design and Development”book ([RodJohnson]).
Spring.NET is a port of Spring for the .NET platform.
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
What is Spring(.NET)?Benefits
modular and comprehensivecode that is easier to testnon-invasiveprovides consistent framework for data accessconsistent configurationeasy to extenddoes not reinvent the wheel...
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
What is Spring(.NET)?Benefits
modular and comprehensivecode that is easier to testnon-invasiveprovides consistent framework for data accessconsistent configurationeasy to extenddoes not reinvent the wheel...
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
What is Spring(.NET)?Benefits
modular and comprehensivecode that is easier to testnon-invasiveprovides consistent framework for data accessconsistent configurationeasy to extenddoes not reinvent the wheel...
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
What is Spring(.NET)?Benefits
modular and comprehensivecode that is easier to testnon-invasiveprovides consistent framework for data accessconsistent configurationeasy to extenddoes not reinvent the wheel...
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
What is Spring(.NET)?Benefits
modular and comprehensivecode that is easier to testnon-invasiveprovides consistent framework for data accessconsistent configurationeasy to extenddoes not reinvent the wheel...
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
What is Spring(.NET)?Benefits
modular and comprehensivecode that is easier to testnon-invasiveprovides consistent framework for data accessconsistent configurationeasy to extenddoes not reinvent the wheel...
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
What is Spring(.NET)?Benefits
modular and comprehensivecode that is easier to testnon-invasiveprovides consistent framework for data accessconsistent configurationeasy to extenddoes not reinvent the wheel...
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
What is Spring(.NET)?Benefits
modular and comprehensivecode that is easier to testnon-invasiveprovides consistent framework for data accessconsistent configurationeasy to extenddoes not reinvent the wheel...
Spring.NETIntroduction
Oliver Paulus
SampleapplicationoverviewLayers
AOP
What isSpring(.NET)?Benefits
Springoverview
Spring overview
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Part II
Spring object container
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerwithout DIP/IoC object container
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerwith DIP/IoC object container
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerFeatures
object creation with constructor, static factory orinctance factory methodobjects as singletons or prototypes1
constructor and property injection1
possibility to set any type of property or constructorargument (null values, collections, indexer, ...)1
method injection / replacementautowiringobject lifecycle interfacetype conversionthreading and concurrency supportobject pooling...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerFeatures
object creation with constructor, static factory orinctance factory methodobjects as singletons or prototypes1
constructor and property injection1
possibility to set any type of property or constructorargument (null values, collections, indexer, ...)1
method injection / replacementautowiringobject lifecycle interfacetype conversionthreading and concurrency supportobject pooling...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerFeatures
object creation with constructor, static factory orinctance factory methodobjects as singletons or prototypes1
constructor and property injection1
possibility to set any type of property or constructorargument (null values, collections, indexer, ...)1
method injection / replacementautowiringobject lifecycle interfacetype conversionthreading and concurrency supportobject pooling...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerFeatures
object creation with constructor, static factory orinctance factory methodobjects as singletons or prototypes1
constructor and property injection1
possibility to set any type of property or constructorargument (null values, collections, indexer, ...)1
method injection / replacementautowiringobject lifecycle interfacetype conversionthreading and concurrency supportobject pooling...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerFeatures
object creation with constructor, static factory orinctance factory methodobjects as singletons or prototypes1
constructor and property injection1
possibility to set any type of property or constructorargument (null values, collections, indexer, ...)1
method injection / replacementautowiringobject lifecycle interfacetype conversionthreading and concurrency supportobject pooling...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerFeatures
object creation with constructor, static factory orinctance factory methodobjects as singletons or prototypes1
constructor and property injection1
possibility to set any type of property or constructorargument (null values, collections, indexer, ...)1
method injection / replacementautowiringobject lifecycle interfacetype conversionthreading and concurrency supportobject pooling...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerFeatures
object creation with constructor, static factory orinctance factory methodobjects as singletons or prototypes1
constructor and property injection1
possibility to set any type of property or constructorargument (null values, collections, indexer, ...)1
method injection / replacementautowiringobject lifecycle interfacetype conversionthreading and concurrency supportobject pooling...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerFeatures
object creation with constructor, static factory orinctance factory methodobjects as singletons or prototypes1
constructor and property injection1
possibility to set any type of property or constructorargument (null values, collections, indexer, ...)1
method injection / replacementautowiringobject lifecycle interfacetype conversionthreading and concurrency supportobject pooling...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerFeatures
object creation with constructor, static factory orinctance factory methodobjects as singletons or prototypes1
constructor and property injection1
possibility to set any type of property or constructorargument (null values, collections, indexer, ...)1
method injection / replacementautowiringobject lifecycle interfacetype conversionthreading and concurrency supportobject pooling...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerFeatures
object creation with constructor, static factory orinctance factory methodobjects as singletons or prototypes1
constructor and property injection1
possibility to set any type of property or constructorargument (null values, collections, indexer, ...)1
method injection / replacementautowiringobject lifecycle interfacetype conversionthreading and concurrency supportobject pooling...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerFeatures
object creation with constructor, static factory orinctance factory methodobjects as singletons or prototypes1
constructor and property injection1
possibility to set any type of property or constructorargument (null values, collections, indexer, ...)1
method injection / replacementautowiringobject lifecycle interfacetype conversionthreading and concurrency supportobject pooling...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerBenefits
less coupling between classeseasier to test codeno singleton or factory objects neededhigh pluggabilitynon-invasiveeasy to understand...
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerBenefits
less coupling between classeseasier to test codeno singleton or factory objects neededhigh pluggabilitynon-invasiveeasy to understand...
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerBenefits
less coupling between classeseasier to test codeno singleton or factory objects neededhigh pluggabilitynon-invasiveeasy to understand...
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerBenefits
less coupling between classeseasier to test codeno singleton or factory objects neededhigh pluggabilitynon-invasiveeasy to understand...
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerBenefits
less coupling between classeseasier to test codeno singleton or factory objects neededhigh pluggabilitynon-invasiveeasy to understand...
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerBenefits
less coupling between classeseasier to test codeno singleton or factory objects neededhigh pluggabilitynon-invasiveeasy to understand...
Spring.NETIntroduction
Oliver Paulus
Spring objectcontainerwithout DIP/IoCobject container
with DIP/IoC objectcontainer
Features
Benefits
Spring object containerBenefits
less coupling between classeseasier to test codeno singleton or factory objects neededhigh pluggabilitynon-invasiveeasy to understand...
Spring.NETIntroduction
Oliver Paulus
Spring AOPwithout AOP
with AOP
AOP grammar
Benefits
Part III
Spring AOP
Spring.NETIntroduction
Oliver Paulus
Spring AOPwithout AOP
with AOP
AOP grammar
Benefits
Spring AOPwithout AOP
Spring.NETIntroduction
Oliver Paulus
Spring AOPwithout AOP
with AOP
AOP grammar
Benefits
Spring AOPwith AOP
Spring.NETIntroduction
Oliver Paulus
Spring AOPwithout AOP
with AOP
AOP grammar
Benefits
Spring AOPAOP grammar
Aspect defines pointcuts and advicesAdvice is an extension or modification
Joinpoint is an event during program execution whichcan be extended or modified by advices
Pointcut defines on which joinpoints an advice will beinserted
Spring.NETIntroduction
Oliver Paulus
Spring AOPwithout AOP
with AOP
AOP grammar
Benefits
Spring AOPBenefits
better SoC1
easier to understand business codehigher productivityno coupling of business code and cross cuttingconcernseasier reuse of business codeeasier to extendpossibility to delay design decisions for system (cross)level concerns
1Separation of concerns
Spring.NETIntroduction
Oliver Paulus
Spring AOPwithout AOP
with AOP
AOP grammar
Benefits
Spring AOPBenefits
better SoC1
easier to understand business codehigher productivityno coupling of business code and cross cuttingconcernseasier reuse of business codeeasier to extendpossibility to delay design decisions for system (cross)level concerns
1Separation of concerns
Spring.NETIntroduction
Oliver Paulus
Spring AOPwithout AOP
with AOP
AOP grammar
Benefits
Spring AOPBenefits
better SoC1
easier to understand business codehigher productivityno coupling of business code and cross cuttingconcernseasier reuse of business codeeasier to extendpossibility to delay design decisions for system (cross)level concerns
1Separation of concerns
Spring.NETIntroduction
Oliver Paulus
Spring AOPwithout AOP
with AOP
AOP grammar
Benefits
Spring AOPBenefits
better SoC1
easier to understand business codehigher productivityno coupling of business code and cross cuttingconcernseasier reuse of business codeeasier to extendpossibility to delay design decisions for system (cross)level concerns
1Separation of concerns
Spring.NETIntroduction
Oliver Paulus
Spring AOPwithout AOP
with AOP
AOP grammar
Benefits
Spring AOPBenefits
better SoC1
easier to understand business codehigher productivityno coupling of business code and cross cuttingconcernseasier reuse of business codeeasier to extendpossibility to delay design decisions for system (cross)level concerns
1Separation of concerns
Spring.NETIntroduction
Oliver Paulus
Spring AOPwithout AOP
with AOP
AOP grammar
Benefits
Spring AOPBenefits
better SoC1
easier to understand business codehigher productivityno coupling of business code and cross cuttingconcernseasier reuse of business codeeasier to extendpossibility to delay design decisions for system (cross)level concerns
1Separation of concerns
Spring.NETIntroduction
Oliver Paulus
Spring AOPwithout AOP
with AOP
AOP grammar
Benefits
Spring AOPBenefits
better SoC1
easier to understand business codehigher productivityno coupling of business code and cross cuttingconcernseasier reuse of business codeeasier to extendpossibility to delay design decisions for system (cross)level concerns
1Separation of concerns
Spring.NETIntroduction
Oliver Paulus
Spring WebFeatures
Part IV
Spring Web
Spring.NETIntroduction
Oliver Paulus
Spring WebFeatures
Spring WebFeatures
Dependency injection for ASP.NET pages and controls1
Master pages for ASP .NET 1.1Bidirectional data binding and model management1
LocalisationResult mapping1
Client-side scriptingValidation framework...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring WebFeatures
Spring WebFeatures
Dependency injection for ASP.NET pages and controls1
Master pages for ASP .NET 1.1Bidirectional data binding and model management1
LocalisationResult mapping1
Client-side scriptingValidation framework...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring WebFeatures
Spring WebFeatures
Dependency injection for ASP.NET pages and controls1
Master pages for ASP .NET 1.1Bidirectional data binding and model management1
LocalisationResult mapping1
Client-side scriptingValidation framework...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring WebFeatures
Spring WebFeatures
Dependency injection for ASP.NET pages and controls1
Master pages for ASP .NET 1.1Bidirectional data binding and model management1
LocalisationResult mapping1
Client-side scriptingValidation framework...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring WebFeatures
Spring WebFeatures
Dependency injection for ASP.NET pages and controls1
Master pages for ASP .NET 1.1Bidirectional data binding and model management1
LocalisationResult mapping1
Client-side scriptingValidation framework...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring WebFeatures
Spring WebFeatures
Dependency injection for ASP.NET pages and controls1
Master pages for ASP .NET 1.1Bidirectional data binding and model management1
LocalisationResult mapping1
Client-side scriptingValidation framework...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring WebFeatures
Spring WebFeatures
Dependency injection for ASP.NET pages and controls1
Master pages for ASP .NET 1.1Bidirectional data binding and model management1
LocalisationResult mapping1
Client-side scriptingValidation framework...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Spring WebFeatures
Spring WebFeatures
Dependency injection for ASP.NET pages and controls1
Master pages for ASP .NET 1.1Bidirectional data binding and model management1
LocalisationResult mapping1
Client-side scriptingValidation framework...
1used in SpringSample application
Spring.NETIntroduction
Oliver Paulus
Bibliography
Spring Framework Homepage -http://www.springframework.org
Spring Framework .NET Homepage -http://www.springframework.net
Expert One-on-One J2EE Design and Development -Rod Johnson - Wrox Press - 2002
Spring in Action - Craig Walls, Ryan Breidenbach -Manning - 2005
Spring - Framework fur die Java-Entwicklung - EberhardWolff - dpunkt.verlag - 2006
Spring 2.0 im Einsatz - Guido Schmutz, PeterWelkenbach - entwickler.press - 2007
Martin Fowler Homepage - http://www.martinfowler.com