protected RouteGpsCoordinates findLastRouteCoordinates(String client) {
        Query lastRouteCoordinatesQuery = new Query().addCriteria(where("client").is(client)).with(new Sort(DESC, "_id")).limit(1);
        return mongoTemplate.findOne(lastRouteCoordinatesQuery, RouteGpsCoordinates.class, collectionName(RouteGpsCoordinates.class));
    }
protected RouteGpsCoordinates findLastRouteCoordinates ( String client ) { Query lastRouteCoordinatesQuery = new Query ( ) . addCriteria ( where ( "client" ) . is ( client ) ) . with ( new Sort ( DESC , "_id" ) ) . limit ( 1 ) ; return mongoTemplate . findOne ( lastRouteCoordinatesQuery , RouteGpsCoordinates . class , collectionName ( RouteGpsCoordinates . class ) ) ; }
Callbacks