Advertisement
absjabed

server request and response

Dec 21st, 2017
386
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.75 KB | None | 0 0
  1. public class ServerRequest {
  2.  
  3.     @SerializedName("operation")
  4.     @Expose
  5.     private String operation;
  6.  
  7.     @SerializedName("studentModel")
  8.     @Expose
  9.     private StudentModel studentModel;
  10.  
  11.     public void setOperation(String operation) {
  12.         this.operation = operation;
  13.     }
  14.  
  15.     public void setStudentModel(StudentModel studentModel) {
  16.         this.studentModel = studentModel;
  17.     }
  18. }
  19.  
  20. public class ServerResponse {
  21.  
  22.     private String result;
  23.     private String message;
  24.     private StudentModel studentModel;
  25.  
  26.     public String getResult() {
  27.         return result;
  28.     }
  29.  
  30.     public String getMessage() {
  31.         return message;
  32.     }
  33.  
  34.     public StudentModel getStudentModel() {
  35.         return studentModel;
  36.     }
  37.  
  38. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement