use of dz.easy.androidclient.Util.CustomRequestArray in project easy by MehdiBenmesa.
the class ModuleService method getModulesByTeacher.
private void getModulesByTeacher(final IModule callBack) throws JSONException {
// dialogListner.showDialog();
/* Starting Download Service */
CustomRequestArray jsonReq = new CustomRequestArray(Request.Method.GET, GET_MODULES_BY_TEACHER + "/" + App.getInstance().getUser().getString("_id"), null, new Response.Listener<JSONArray>() {
@Override
public void onResponse(JSONArray response) {
callBack.onDataRecieved(response);
}
}, new Response.ErrorListener() {
@Override
public void onErrorResponse(VolleyError error) {
}
});
App.getInstance().addToRequestQueue(jsonReq);
}
use of dz.easy.androidclient.Util.CustomRequestArray in project easy by MehdiBenmesa.
the class GroupService method getGroupsByModuleByTeacher.
public void getGroupsByModuleByTeacher(final IGroupe callBack, String moduleId) {
try {
CustomRequestArray jsonReq = new CustomRequestArray(Request.Method.GET, GET_GROUPS_BY_TEACHER_MODULE + "/" + moduleId + "/" + App.getInstance().getUser().getString("_id"), null, new Response.Listener<JSONArray>() {
@Override
public void onResponse(JSONArray response) {
callBack.onDataRecieved(response);
}
}, new Response.ErrorListener() {
@Override
public void onErrorResponse(VolleyError error) {
}
});
App.getInstance().addToRequestQueue(jsonReq);
} catch (JSONException e) {
e.printStackTrace();
}
}
use of dz.easy.androidclient.Util.CustomRequestArray in project easy by MehdiBenmesa.
the class ModuleService method getTeachers.
private void getTeachers(final IModule callBack) {
CustomRequestArray jsonReq = new CustomRequestArray(Request.Method.GET, GET_TEACHERS, null, new Response.Listener<JSONArray>() {
@Override
public void onResponse(JSONArray response) {
//setup materialviewpager
callBack.onDataRecieved(response);
}
}, new Response.ErrorListener() {
@Override
public void onErrorResponse(VolleyError error) {
}
});
App.getInstance().addToRequestQueue(jsonReq);
}
use of dz.easy.androidclient.Util.CustomRequestArray in project easy by MehdiBenmesa.
the class AbsenceService method getAbsenceByStudent.
private void getAbsenceByStudent(final IAbsence callBack) throws JSONException {
CustomRequestArray jsonReq = new CustomRequestArray(Request.Method.GET, GET_ABSENCE_BY_STUDENT + "/" + App.getInstance().getUser().get("_id"), null, new Response.Listener<JSONArray>() {
@Override
public void onResponse(JSONArray response) {
callBack.onDataReceived(response);
}
}, new Response.ErrorListener() {
@Override
public void onErrorResponse(VolleyError error) {
}
});
App.getInstance().addToRequestQueue(jsonReq);
}
use of dz.easy.androidclient.Util.CustomRequestArray in project easy by MehdiBenmesa.
the class NoteService method getNotesByStudent.
private void getNotesByStudent(final INote callBack) throws JSONException {
CustomRequestArray jsonReq = new CustomRequestArray(Request.Method.GET, GET_NOTE_BY_STUDENT + "/" + App.getInstance().getUser().get("_id"), null, new Response.Listener<JSONArray>() {
@Override
public void onResponse(JSONArray response) {
callBack.onDataReceived(response);
}
}, new Response.ErrorListener() {
@Override
public void onErrorResponse(VolleyError error) {
}
});
App.getInstance().addToRequestQueue(jsonReq);
}
Aggregations