Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Newcomers » Newcomers » XMLGregorianCalendar error Eclipse Luna(WebService Interface Not Compiling because of Error described Below- Help )
XMLGregorianCalendar error Eclipse Luna [message #1429421] Tue, 23 September 2014 07:55 Go to next message
Khajan Joshi is currently offline Khajan JoshiFriend
Messages: 1
Registered: September 2014
Junior Member
I am getting the following error after generating the java code after wsimport.
Error
Abstract class javax.xml.datatype.XMLGregorianCalendar cannot be used as a runtime class because it is not extended by a non abstract class
which is suitable as a runtime class


I am using dateTime as argument to one method,
This is the service interface method.
public List<Weather> getForecast(
@WebParam(name = "arg0", targetNamespace = "xyzdotcom/")
XMLGregorianCalendar arg0,
@WebParam(name = "arg1", targetNamespace = "xyzdotcom/")
int arg1)
throws Exception_Exception
;
Because of the error the code is not compiling. Is this a bug or some thing i am missing. I am using Websphere Application Server runtime and "IBM Webshere JAX WS" as WebService Runtime. It actually should have been pretty simple.

The following is the commented first line of the generated code
Generated By:JAX-WS RI IBM 2.2.1-11/28/2011
Being a newcomer apologies if i am on a wrong place and will be helpful if anyone can guide to the correct forum
Re: XMLGregorianCalendar error Eclipse Luna [message #1429832 is a reply to message #1429421] Tue, 23 September 2014 20:29 Go to previous message
Tauno Voipio is currently offline Tauno VoipioFriend
Messages: 502
Registered: August 2014
Senior Member
Khajan Joshi wrote on Tue, 23 September 2014 10:55
I am getting the following error after generating the java code after wsimport.
Error
Abstract class javax.xml.datatype.XMLGregorianCalendar cannot be used as a runtime class because it is not extended by a non abstract class
which is suitable as a runtime class


I am using dateTime as argument to one method,
This is the service interface method.
public List<Weather> getForecast(
@WebParam(name = "arg0", targetNamespace = "xyzdotcom/")
XMLGregorianCalendar arg0,
@WebParam(name = "arg1", targetNamespace = "xyzdotcom/")
int arg1)
throws Exception_Exception


This is a Java question. An abstract class is a template for a class and it cannot be used directly. See the discussion at <http://stackoverflow.com/questions/835889/java-util-date-to-xmlgregoriancalendar>.


--

Tauno Voipio
Previous Topic:Disable line wrapping for all text files?
Next Topic:using eclipse for Pro*C
Goto Forum:
  


Current Time: Wed Oct 23 21:08:13 GMT 2019

Powered by FUDForum. Page generated in 0.03036 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top