Advertisement
Guest User

Untitled

a guest
Oct 21st, 2017
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.60 KB | None | 0 0
  1.  @GetMapping(value = "/api/pariwisata")
  2.     public ResponseEntity<?> getPariwisataFilter(
  3.             @RequestParam(value = "namaPariwisata", required = false) String namaPariwisata,
  4.             @RequestParam(value = "provinsi", required = false) String provinsi) {
  5.  
  6.         HateoasResource hateoasResource = new HateoasResource(pariwisataService.getPariwisataFilter(namaPariwisata, provinsi));
  7.         hateoasResource.add(linkTo(methodOn(PariwisataController.class).getPariwisataFilter(namaPariwisata, provinsi)).withSelfRel());
  8.         return new ResponseEntity<>(hateoasResource, HttpStatus.OK);
  9.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement