Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Java > Java and JDK > Servlets
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Servlets section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Closed Thread
 
Thread Tools Display Modes
  #1 (permalink)  
Old January 20th, 2004, 05:55 AM
Registered User
 
Join Date: Jan 2004
Location: Noida, UP, India.
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default java webservices

The below mensioned program is showing error in the compilation time.
Error is:
gg.java:50: non-static method readWSDL(java.lang.String,org.xml.sax.I
nputSource) cannot be referenced from a static context

code:


import com.ibm.wsdl.xml.*;
import javax.wsdl.*;
import org.xml.sax.*;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.ServletException;
import javax.servlet.ServletConfig;
import java.io.PrintWriter;
import java.net.*;

public class gg extends HttpServlet
{
†String userName;
 String password;

 public void init(ServletConfig config)throws ServletException
 {
super.init(config);
}

public void processRequest(HttpServletRequest request,HttpServletResponse response)throws ServletException,java.io.IOException
{
response.setContentType("text/html");
java.io.PrintWriter out=response.getWriter();
try{

Definition def = javax.wsdl.xml.WSDLReader.readWSDL(null,new InputSource("http://localhost:8080/xx.wsdl"));

}catch(WSDLException ex){System.out.println(ex.getFaultCode());}
}
}
Closed Thread


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Question about webservices chobo2 ASP.NET 3.5 Basics 1 November 27th, 2008 11:58 PM
Reg. Java Webservices ABC_SUN XML 0 March 26th, 2007 04:44 AM
Encoding -webservices-why ? raghuraman_ace ASP.NET 1.0 and 1.1 Professional 0 August 28th, 2006 03:36 AM
Developing Webservices in java wakeup J2EE 2 March 27th, 2006 01:21 PM
webservices dkautilya ASP.NET 1.0 and 1.1 Professional 0 November 18th, 2005 07:57 AM



All times are GMT -4. The time now is 02:35 AM.


Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.