@@ -205,24 +205,37 @@ public ResponseEntity<?> generate(final String msgProtocol, final String msgType
205
205
}
206
206
}
207
207
208
-
209
208
/**
210
209
* To display response in browser or application
211
- * @param status response code for the HTTP request
210
+ * @param status response code for the HTTP request
212
211
* @param responseMessage the message according to response
213
- * @param resultMessage whatever the result this message gives you idea about that
214
- * @param errorResponse is to collect all the responses here.
212
+ * @param resultMessage whatever the result this message gives you idea about that
213
+ * @param errorResponse is to collect all the responses here.
215
214
* @return ResponseEntity
216
215
*/
217
216
public ResponseEntity <JsonObject > createResponseEntity (HttpStatus status , String responseMessage , String resultMessage ,
218
217
JsonObject errorResponse ) {
219
218
initializeResponse (status , responseMessage , resultMessage , errorResponse );
220
219
return new ResponseEntity <>(errorResponse , status );
221
220
}
221
+
222
+ /**
223
+ * To display response in browser or application
224
+ * @param status response code for the HTTP request
225
+ * @param responseMessage the message according to response
226
+ * @param resultMessage whatever the result this message gives you idea about that
227
+ * @return ResponseEntity
228
+ */
222
229
public ResponseEntity <JsonObject > createResponseEntity (HttpStatus status , String responseMessage , String resultMessage ) {
223
230
return createResponseEntity (status , responseMessage , resultMessage , new JsonObject ());
224
231
}
225
232
233
+ /**
234
+ * To initialize in the @{createResponseEntity} method
235
+ * @param status response code for the HTTP request
236
+ * @param resultMessage whatever the result this message gives you idea about that
237
+ * @param errorResponse is to collect all the responses here.
238
+ */
226
239
public void initializeResponse (HttpStatus status , String errorMessage , String resultMessage , JsonObject errorResponse ) {
227
240
errorResponse .addProperty (JSON_STATUS_CODE , status .value ());
228
241
errorResponse .addProperty (JSON_STATUS_RESULT , resultMessage );
@@ -268,7 +281,6 @@ private ResponseEntity<JsonObject> handleException(Exception e) {
268
281
* @param jsonObject The content of the message which is used in creating the event details.
269
282
* @return JsonObject generated event
270
283
*/
271
-
272
284
public JsonObject processEvent (String msgProtocol , String msgType , Boolean failIfMultipleFound ,
273
285
Boolean failIfNoneFound , Boolean lookupInExternalERs , int lookupLimit ,
274
286
Boolean okToLeaveOutInvalidOptionalFields , JsonObject jsonObject ) throws REMGenerateException , JsonSyntaxException {
0 commit comments