/*
* LoadRunner Java script. (Build: _build_number_)
*
* Script Description: dengdagui
*
*/
import java.io.BufferedInputStream;
import java.io.ByteArrayOutputStream;
import java.io.InputStream;
import java.io.OutputStream;
import java.util.ArrayList;
import flex.messaging.io.MessageDeserializer;
import flex.messaging.io.MessageIOConstants;
import flex.messaging.io.amf.ActionMessage;
import flex.messaging.io.amf.AmfMessageDeserializer;
import flex.messaging.io.amf.AmfMessageSerializer;
import flex.messaging.io.amf.MessageBody;
import flex.messaging.io.amf.client.AMFConnection;
import flex.messaging.io.amf.client.exceptions.ClientStatu***ception;
import flex.messaging.io.amf.client.exceptions.ServerStatu***ception;
import lrapi.lr;
public class Actions
{
// private static int Conn_ok =1;
// private static int Call_ok =3;
// private int state;
public int init() throws Throwable {
return 0;
}//end of init
public int action() throws Throwable {
lr.start_transaction("查看房间列表");
AMFConnection conn=new AMFConnection();
try {
//conn.connect(""); 33
conn.setObjectEncoding(0);
// conn.connect("");
conn.connect("");
try {
//Object obj=conn.call("product.getProducts");//第一个参数是 destination.方法 ? ?参数是方法参 ?
//Object obj=conn.call("taskBean.getGameAffiche",1);//第一个参数是 destination.方法 ? ?参数是方法参 ?
// Object obj=conn.call("roomBean.getNewRoomByType","1",0);
// Object obj=conn.call("roomBean.getNewRoomByType",1,"");
Object obj=conn.call("roomBean.getNewRoomByType","A1",0);
// System.out.println(obj.toString());
lr.end_transaction("查看房间列表", lr.PASS);
conn.close();
} catch (ServerStatu***ception e) {
// TODO Auto-generated catch block
e.printStackTrace();
conn.close();
lr.end_transaction("查看房间列表", lr.FAIL);
}
} catch (ClientStatu***ception e) {
e.printStackTrace();
conn.close();
lr.end_transaction("查看房间列表", lr.FAIL);
}
return 0;
}//end of end
//
// }//end of end
public int end() throws Throwable {
return 0;
}//end of end
}
阅读(2013) | 评论(0) | 转发(0) |