use of com.tvd12.ezyfoxserver.response.EzyRequestAppResponseParams in project ezyfox-server by youngmonkeys.
the class EzyAppSendResponseImpl method newResponse.
protected EzyResponse newResponse(EzyData data) {
EzyAppSetting setting = context.getApp().getSetting();
EzyRequestAppResponseParams params = new EzyRequestAppResponseParams();
params.setAppId(setting.getId());
params.setData(data);
return new EzyRequestAppResponse(params);
}
use of com.tvd12.ezyfoxserver.response.EzyRequestAppResponseParams in project ezyfox-server by youngmonkeys.
the class EzyRequestAppResponseTest method test.
@Test
public void test() {
EzyRequestAppResponseParams params = new EzyRequestAppResponseParams();
EzyData data = EzyEntityFactory.EMPTY_ARRAY;
params.setData(data);
params.setAppId(1);
assert params.getAppId() == 1;
assert params.getData() == data;
EzyRequestAppResponse response = new EzyRequestAppResponse(params);
assert response.getParams() == params;
assert response.getCommand() == EzyCommand.APP_REQUEST;
assert response.serialize().size() > 0;
response.release();
}
Aggregations