02-05-2012, 04:10 PM
spring technology
Introduction to the Spring Framework.ppt (Size: 814.5 KB / Downloads: 108)
What does Spring provide?
Lightweight container and framework
Most of your code will be unaware of the Spring framework
Use only the parts you of Spring you want
Manages dependencies between your objects
Encourages use of interfaces
Lessens “coupling” between objects
Cleaner separation of responsibilities
Put logic that applies to many objects in one single place
Separate the class’s core responsibility from other duties
Simplifies database integration
Spring JDBC
Hibernate
iBATIS
Java Persistence
Example Application
Contacts – store and retrieve contacts
Created using MyEclipse 7
Uses Maven 2 to manage libraries
Demonstrates basic Spring capabilities
Contact has a Person, collection of Email, and collection of Phone objects
Can use an XML file or database as repository
User interface is via the console
See READ_ME file under project folder
External Configuration
Configuration options
Properties files
XML configuration files
Annotations
XML Configuration
Specify the creation of objects
Specify the dependencies between objects
Implementing AOP in Spring
Advice
Several different ways to configure Advice objects
Implement interfaces and XML configuration
Use @AspectJ annotations
Integrate with AspectJ
Advice is commonly applied to a method
Different ways to apply advice to an object
Before advice
After returning advice
After throwing advice
After advice
Around advice
Introduction to the Spring Framework.ppt (Size: 814.5 KB / Downloads: 108)
What does Spring provide?
Lightweight container and framework
Most of your code will be unaware of the Spring framework
Use only the parts you of Spring you want
Manages dependencies between your objects
Encourages use of interfaces
Lessens “coupling” between objects
Cleaner separation of responsibilities
Put logic that applies to many objects in one single place
Separate the class’s core responsibility from other duties
Simplifies database integration
Spring JDBC
Hibernate
iBATIS
Java Persistence
Example Application
Contacts – store and retrieve contacts
Created using MyEclipse 7
Uses Maven 2 to manage libraries
Demonstrates basic Spring capabilities
Contact has a Person, collection of Email, and collection of Phone objects
Can use an XML file or database as repository
User interface is via the console
See READ_ME file under project folder
External Configuration
Configuration options
Properties files
XML configuration files
Annotations
XML Configuration
Specify the creation of objects
Specify the dependencies between objects
Implementing AOP in Spring
Advice
Several different ways to configure Advice objects
Implement interfaces and XML configuration
Use @AspectJ annotations
Integrate with AspectJ
Advice is commonly applied to a method
Different ways to apply advice to an object
Before advice
After returning advice
After throwing advice
After advice
Around advice