aspose file tools*
The moose likes Spring and the fly likes java.lang.InstantiationException Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Spring
Bookmark "java.lang.InstantiationException" Watch "java.lang.InstantiationException" New topic
Author

java.lang.InstantiationException

sam liya
Ranch Hand

Joined: Nov 25, 2008
Posts: 1223
in my spring example animal is abstract class.dos is concrete class.
here is my xml file.


here is the main class.

i cant understand why it gives error when i am going to instatiate a dog class.
sam liya
Ranch Hand

Joined: Nov 25, 2008
Posts: 1223
here is my animal class


here is my dog class

Vikas Kapoor
Ranch Hand

Joined: Aug 16, 2007
Posts: 1374
check you bean definition for 'dog'. The error is apparent.
sam liya
Ranch Hand

Joined: Nov 25, 2008
Posts: 1223
what is that mena? what is mean by apparent
sam liya
Ranch Hand

Joined: Nov 25, 2008
Posts: 1223
no, i need to extend's abstract animal class and make dog concrete class.but what is the erroe.dog class is not abstract.
Vikas Kapoor
Ranch Hand

Joined: Aug 16, 2007
Posts: 1374
You don't have 'class' attribute for you 'dog' bean definition in bean.xml?
sam liya
Ranch Hand

Joined: Nov 25, 2008
Posts: 1223
thanks Vishal Pandya.I nedd to get abstract clas method and nedd to practise inheritance working on spring.
Vikas Kapoor
Ranch Hand

Joined: Aug 16, 2007
Posts: 1374
You're Welcome Aruna.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: java.lang.InstantiationException