Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » ServerTools (WTP) » Creating Web Service in Eclipse with Axis and Tomcat
Creating Web Service in Eclipse with Axis and Tomcat [message #174303] Thu, 13 July 2006 09:34 Go to next message
Eclipse UserFriend
Originally posted by: tommy.commfides.com

Hi I'm quite new to web services. But I got a compiled class that i want to create a web service of. Since this class is compiled and lies in a package I can't just use the WTP and create a Bottom Up Web Service. So I created a wrapper class to this class to see if that would solve the problem, but i still get error messages that it's not JAX-RPC compliant. I've decompiled the class file I want to create a web service of and made a wrapper class with an interface around this class.

package org.ejbca.core.protocol.ocsp;

import org.bouncycastle.ocsp.*;

public class OCSPResponse
{

public OCSPResponse()
{
resp = null;
fnr = null;
httpReturnCode = 200;
errCode = 0;
}

public OCSPResponse(OCSPResp ocspresp)
{
resp = null;
fnr = null;
httpReturnCode = 200;
errCode = 0;
resp = ocspresp;
}

public int getHttpReturnCode()
{
return httpReturnCode;
}

public void setHttpReturnCode(int code)
{
httpReturnCode = code;
}

public int getErrorCode()
{
return errCode;
}

public void setErrorCode(int code)
{
errCode = code;
}

public String getFnr()
{
return fnr;
}

public void setFnr(String fnr)
{
this.fnr = fnr;
}

public OCSPResp getResp()
{
return resp;
}

public void setResp(OCSPResp resp)
{
this.resp = resp;
}

public int getStatus()
{
-
Something
-
}

private OCSPResp resp;
private String fnr;
private int httpReturnCode;
private int errCode;
}

OCSPResp is an object from boncycastle, as i found out one of the problems is that OCSPResponse is a non Non-Built-In Data Type and don't just contain bulit-in datatypes.

So can anybody give me a detailed input on how to solve this problem, including some hints on how to create a wrapper incase I've done something wrong.

Tommy
Re: Creating Web Service in Eclipse with Axis and Tomcat [message #174346 is a reply to message #174303] Thu, 13 July 2006 13:00 Go to previous message
Chris Brealey is currently offline Chris BrealeyFriend
Messages: 104
Registered: July 2009
Senior Member
Tommy,
you should be able to create a Web service bottom-up from classes in a jar provided the jar is included in the WEB-INF/lib directory of your Web project (and is in the project's build path). If you're getting an error from the Web service wizard when you try this, please open a bug against the jst.ws component [1]. That aside, what is the specific JAX-RPC complaint message you're getting? Except possibly for OCSPResp, everything else about OCSPResponse looks compliant. The problem
could therefore be with OCSPResp, such as an unsupported property type, or the absence of a public default CTOR, etc.

Cheers - CB.

[1] https://bugs.eclipse.org/bugs/enter_bug.cgi?product=Web%20To ols&component=jst.ws&rep_platform=all&op_sys=all

Tommt Kristiansen wrote:

> Hi I'm quite new to web services. But I got a compiled class that i want to create a web service of. Since this class is compiled and lies in a package I can't just use the WTP and create a Bottom Up Web Service. So I created a wrapper class to this class to see if that would solve the problem, but i still get error messages that it's not JAX-RPC compliant. I've decompiled the class file I want to create a web service of and made a wrapper class with an interface around this class.
>
> package org.ejbca.core.protocol.ocsp;
>
> import org.bouncycastle.ocsp.*;
>
> public class OCSPResponse
> {
>
> public OCSPResponse()
> {
> resp = null;
> fnr = null;
> httpReturnCode = 200;
> errCode = 0;
> }
>
> public OCSPResponse(OCSPResp ocspresp)
> {
> resp = null;
> fnr = null;
> httpReturnCode = 200;
> errCode = 0;
> resp = ocspresp;
> }
>
> public int getHttpReturnCode()
> {
> return httpReturnCode;
> }
>
> public void setHttpReturnCode(int code)
> {
> httpReturnCode = code;
> }
>
> public int getErrorCode()
> {
> return errCode;
> }
>
> public void setErrorCode(int code)
> {
> errCode = code;
> }
>
> public String getFnr()
> {
> return fnr;
> }
>
> public void setFnr(String fnr)
> {
> this.fnr = fnr;
> }
>
> public OCSPResp getResp()
> {
> return resp;
> }
>
> public void setResp(OCSPResp resp)
> {
> this.resp = resp;
> }
>
> public int getStatus()
> {
> -
> Something
> -
> }
>
> private OCSPResp resp;
> private String fnr;
> private int httpReturnCode;
> private int errCode;
> }
>
> OCSPResp is an object from boncycastle, as i found out one of the problems is that OCSPResponse is a non Non-Built-In Data Type and don't just contain bulit-in datatypes.
>
> So can anybody give me a detailed input on how to solve this problem, including some hints on how to create a wrapper incase I've done something wrong.
>
> Tommy
Previous Topic:whats is wrong with thejsp editor???
Next Topic:Serving Web Content out of Root
Goto Forum:
  


Current Time: Tue Apr 23 09:00:17 GMT 2024

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

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

Back to the top