Class DriversController

java.lang.Object
edu.ucsb.cs156.gauchoride.controllers.ApiController
edu.ucsb.cs156.gauchoride.controllers.DriversController

@RequestMapping("/api/drivers") @RestController public class DriversController extends ApiController
  • Constructor Details

    • DriversController

      public DriversController()
  • Method Details

    • drivers

      @PreAuthorize("hasRole(\'ROLE_ADMIN\') || hasRole(\'ROLE_DRIVER\') || hasRole(\'ROLE_USER\')") @GetMapping("/all") public org.springframework.http.ResponseEntity<String> drivers() throws com.fasterxml.jackson.core.JsonProcessingException
      Throws:
      com.fasterxml.jackson.core.JsonProcessingException
    • driver

      @PreAuthorize("hasRole(\'ROLE_ADMIN\') || hasRole(\'ROLE_DRIVER\') || hasRole(\'ROLE_USER\')") @GetMapping("/get") public DriverInfo driver(@RequestParam Long id) throws com.fasterxml.jackson.core.JsonProcessingException
      Throws:
      com.fasterxml.jackson.core.JsonProcessingException