• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Liutauras Vilda
  • Paul Clapham
Sheriffs:
  • paul wheaton
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Piet Souris
Bartenders:
  • Mike London

Spring in Action: A Question

 
Ranch Hand
Posts: 10198
3
Mac PPC Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have read the older version of this book and I really enjoyed reading it. Though I was not able to read it cover to cover, I got to understand the basics from this book. Apart from the Spring version that this book covers, how different is this book from the older version?
 
Greenhorn
Posts: 16
Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
HI ..Every One

Even i had the earlier version , but i found the terminology/concept used in example code snippets , was little confusing .But its just my feeling.

So now this "Spring in Action " differs the way it explains the things or its just a book to cover and include latest develpoments along with existing features of the Spring frame work ???.

THanks in Advance
Visu
 
Ranch Hand
Posts: 93
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Same here. I had read the earlier version in which the configuration was done in XML.
The new Annotation based configuration should be interesting to understand.
 
Joe San
Ranch Hand
Posts: 10198
3
Mac PPC Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Padmarag Lokhande wrote:The new Annotation based configuration should be interesting to understand.



And tie your source code to Spring.
 
author
Posts: 422
13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Joe Harry wrote:

Padmarag Lokhande wrote:The new Annotation based configuration should be interesting to understand.



And tie your source code to Spring.



Nope...doesn't have to tie your code to Spring.

If you use @Component and @Autowired to automatically configure your beans, then yes...you've tied your code to Spring. (Which, BTW, I don't think is that horrible of a thing...but nonetheless.)

But instead of using @Component and @Autowired, you choose to use @Named and @Inject from JSR-330, then your beans can be wired up in Spring, Guice, or (I think) Picocontainer.
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Another thing to note about those Annotations, your are tying Spring is only at compile time where you need the definition of the annotation in your classpath to compile.

But you don't need anything at runtime in your classpath if you want it to ignore them. If you want something to act on those annotations at runtime, that is when you need the classes from Spring that act on those annotations.

This is the same with any annotation from anyone.

Mark
 
Joe San
Ranch Hand
Posts: 10198
3
Mac PPC Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Mark Spritzler wrote:Another thing to note about those Annotations, your are tying Spring is only at compile time where you need the definition of the annotation in your classpath to compile.

But you don't need anything at runtime in your classpath if you want it to ignore them. If you want something to act on those annotations at runtime, that is when you need the classes from Spring that act on those annotations.

This is the same with any annotation from anyone.

Mark



What are you trying to say here? It is obvious that if the Anotations are not found in the Classpath and if you have used any one of those Annotations, then you will end up with compilation failures. Annotations are just another type.
 
Mark Spritzler
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Joe Harry wrote:

Mark Spritzler wrote:Another thing to note about those Annotations, your are tying Spring is only at compile time where you need the definition of the annotation in your classpath to compile.

But you don't need anything at runtime in your classpath if you want it to ignore them. If you want something to act on those annotations at runtime, that is when you need the classes from Spring that act on those annotations.

This is the same with any annotation from anyone.

Mark



What are you trying to say here? It is obvious that if the Anotations are not found in the Classpath and if you have used any one of those Annotations, then you will end up with compilation failures. Annotations are just another type.



Exactly. But it doesn't throw an exception at runtime if the definition of the Annotation is not found in the classpath at runtime.

Mark
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic