import org.apache.axis.client.Call;
import org.apache.axis.client.Service;
import javax.xml.namespace.QName;
import java.io.*;
import java.net.URL;
  
public class Client
{
	public static void main(String [] args) 
	{
		try 
		{
			String endpoint = "http://localhost:8080/axis/services/Lifetime";
			
			Service service = new Service();
			Call call = (Call) service.createCall();

			call.setProperty(Call.SESSION_MAINTAIN_PROPERTY, new Boolean(true));
			
			call.setTargetEndpointAddress(new URL(endpoint));
			call.setOperationName(new QName("http://soapinterop.org", "getInfo"));
			
			System.out.println(call.invoke(new Object[]{}));
			Thread.sleep(2000);
			System.out.println(call.invoke(new Object[]{}));
			Thread.sleep(2000);
			System.out.println(call.invoke(new Object[]{}));
         	}
		catch (Exception e) 
		{
             		System.err.println(e.toString());
		}
	}
}