// Collection of code snippets by Arne Vajhøj 
// (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) 
package testtest;

import javax.xml.rpc.*;

import stub.*;

public class TestTest {
    public static void main(String[] args) throws Exception {
        TestService service = new TestServiceLocator();
        Test tst = service.getTestService();
        ((Stub)tst)._setProperty(Stub.SESSION_MAINTAIN_PROPERTY, new Boolean(true));
        ((Stub)tst)._setProperty(Stub.USERNAME_PROPERTY, "wsuser1");
        ((Stub)tst)._setProperty(Stub.PASSWORD_PROPERTY, "hemmeligt");
        System.out.println(tst.getUser());
        int n = (int)(System.currentTimeMillis() % 1000);
        System.out.println(n);
        tst.setV(n);
        for(int i = 0; i < 10; i++) {
            System.out.println(tst.getV());
        }
    }
}
