import java.util.Iterator;
import java.util.List;

import org.mule.extras.client.MuleClient;
import org.mule.umo.UMOException;
import org.mule.umo.UMOMessage;

import com.ferienclub.beachclub.esb.messages.MenuItem;
import com.ferienclub.beachclub.esb.messages.MenuRequest;
import com.ferienclub.custadmin.beans.User;
import com.ferienclub.leisure.esb.messages.LeisureQuery;

public class StartBeachClub {

	public static void main(String[] args){
		try {
			System.out.println("Jetzt gehts los!");
			MuleClient client = new MuleClient();
			User u = new User();
			u.setUserId("95F6B374-9717-478D-A606-15CF8856B1BD");
			UMOMessage result = client.send("axis:http://localhost:8081/axis/services/BeachClubManagement?method=makeOrder",
					new Object[]{u, new MenuItem("Fanta",1.75),new Integer(3)},null);
			Object o = result.getPayload();              
			MenuRequest r = (MenuRequest)o;
			System.out.println(r);
		} catch (UMOException e) {
			e.printStackTrace();
		}
	}	
	
}
