File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Web Services and the fly likes Type mismatch error in ParamConverterProvider Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "Type mismatch error in ParamConverterProvider" Watch "Type mismatch error in ParamConverterProvider" New topic
Author

Type mismatch error in ParamConverterProvider

Anirudh Gupta
Ranch Hand

Joined: Dec 08, 2010
Posts: 48

Hi All,

While attempting to write a custom ParamConverterProvider I am facing a compile error which is a little strange. I am quiet sure it is trivial but am not able to quiet point it out.
The error is in the provider class on the return statement. "Type mismatch: cannot convert from DemoParamConverter to ParamConverter<T>"


Attaching the 3 artifacts of concern,

1. Provider


2. ParamConverter


3. The type to be converted


Regards,
Anirudh
Abhay Agarwal
Ranch Hand

Joined: Feb 29, 2008
Posts: 1154
    
    1

although i have not ran it, i guess error is due to type information missing in private final DemoParamConverter dpc = new DemoParamConverter() line.
Btw, please post code of DemoParamConverter class.
Anirudh Gupta
Ranch Hand

Joined: Dec 08, 2010
Posts: 48

Abhay,

The 2nd code item listing IS that very class - DemoParamConverter.class.

Thanks.
Anirudh.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Type mismatch error in ParamConverterProvider