radhika holani

Greenhorn
+ Follow
since Mar 28, 2006
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by radhika holani

i am non using AXIS. its a normal java client
17 years ago
following is the code i am using for calling the deployed service.

// Create SOAP RPC Call Object
Call call = new Call ( );
// Set Encoding Style to standard SOAP encoding
call.setEncodingStyleURI(Constants.NS_URI_SOAP_ENC);
// Set Object URI and Method Name
call.setTargetObjectURI ("urn:examples:helloservice");
call.setMethodName ("sayGreeting");
// Set Method Parameters
Parameter param = new Parameter("name", String.class,
firstName, Constants.NS_URI_SOAP_ENC);
Vector paramList = new Vector ( );
paramList.addElement (param);
call.setParams (paramList);
// Set the URL for the Web Service
URL url = new URL ("http://localhost:8070/soap/servlet/rpcrouter");
// Invoke the Service
Response resp = call.invoke (url, "");
// Check for Faults
if (!resp.generatedFault( )) {
// Extract Return value
Parameter result = resp.getReturnValue ( );
String greeting = (String) result.getValue( );
return greeting;
}
else {
// Extract Fault Code and String
Fault f = resp.getFault( );
String faultCode = f.getFaultCode( );
String faultString = f.getFaultString( );
System.err.println("Fault Occurred (details follow):");
System.err.println("Fault Code: "+faultCode);
System.err.println("Fault String: "+faultString);
return new String ("Fault Occurred. No greeting for you!");
}

there is a service deployed with urn "urn:examples:helloservice"
17 years ago
Hi,
I am new to web services.
I have tomcat5.0 server running on my m/c.
I tried deploying my first helloservice and was successful.
But when i tried to call that service it gives me the following error.

Hello SOAP Client
Fault Occurred (details follow):
Fault Code: SOAP-ENV:Server.BadTargetObjectURI
Fault String: Unable to resolve target object: com.pspl.soap.SoapService
Fault Occurred. No greeting for you!

following is my classpath detail.
CLASSPATH=c:\jars\xerces.jar;c:\jars\activation.jar;c:\jars\mail.jar;c:\jars\soa
p.jar;c:\jars\xercesImpl.jar;e:\junit3.8.1\junit.jar;C:\soap

I have service class file at location c:\soap.
I think i have set all the classpath correctly. Even though its unable to find SoapService.
Please help me..
17 years ago
I am developing an web application wherein i have to play movie trailers which is available on other websites like imdb.com.Is there any way to access trailer stream from such sites and play it in my own web application.
17 years ago
well the application that i wanted to develop is web application using AJAX therefore posted topic here.
I want to develop the email client application.
The client should be able to send request to the pop3 / imap /smtp server to get no. of messages in the inbox,write new mails,read mails,etc.
Now my question is what should i use to send request to server i.e use perl modules or use php modules or or something other that u suggest.

thanks in advance
i am able to run perl script but not getting results as required. (as those i used to get when run on apachi http server)
I am using apachi tomcat server for running my web application.

i hosted some perl scripts in my web application under WEBINF/cgi folder.
among them one perl script sends "GET" request to some server and parse the received response and generate o/p in the form of xml. when i run the script directly through perl interpretor i get correct xml data as required but when invoking the script from browser i get empty xml .

Also when i host the scripts on apachi http server and invoke the script from browser i get the correct xml.

is there any difference in hosting scripts on apachi http server and apachi tomcat server?

any help will be appritiated.
//File A.java
package a;
public class A
{
A(){ }
public void print(){ System.out.println("A"); }
}
//File B.java
package b;
import a.*;
public class B extends A
{
B(){ }
public void print(){ System.out.println("B"); }
public static void main(String[] args)
{
new B();
}
}

What will be printed when you try to compile and run class B?

Select 1 correct option.
a It will print A.
b It will print B.
c It will not compile.
d It will compile but will not run.
e None of the above.


i thought if there is no access modifier to constructor as in class A above,it takes the modifier of the class i.e. public and the ans is e.
But the given ans is c.
Can anybody plz tell me why this?
//File A.java
package a;
public class A
{
A(){ }
public void print(){ System.out.println("A"); }
}
//File B.java
package b;
import a.*;
public class B extends A
{
B(){ }
public void print(){ System.out.println("B"); }
public static void main(String[] args)
{
new B();
}
}

please explain me the o/p of the above program.
Integer i = new Integer("1000");
int j = 1000;
System.out.pintln(i==j);

while printing i==j, please tell me whether Integer is converted to int (unboxing) OR int is converted to Integer(boxing)
question mark works when declaring a reference for a variable ,it doesn't work for generic class and method declaration.

hence the above code will give u err.
class A implements Runnable {
public void run() {System.out.print(Thread.currentThread().getName());}
}
class B implements Runnable {
public void run() {
new A().run();
new Thread(new A(),"T2").run();
new Thread(new A(),"T3").start();
}}
class C {
public static void main (String[] args) {
new Thread(new B(),"T1").start();
}}


Please explain me why the o/p here is T1T1T3