GpsDataController.java 875 Bytes
package com.bsth.controller;

import com.bsth.data.gps.GpsCacheData;
import com.bsth.entity.GpsEntity;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

@RestController
@RequestMapping("gps")
public class GpsDataController {

    @RequestMapping("findByStation")
    public List<GpsEntity> findByStation(@RequestParam String lineCode
            , @RequestParam String upDown
            , @RequestParam String name) {


        return null;
    }

    @RequestMapping("findByLineAndUpDown")
    public Map<String, Object> findByLineAndUpDown(@RequestParam String lineCode, @RequestParam int upDown) {
        return GpsCacheData.find(lineCode, upDown);
    }
}