Documentation ¶
Index ¶
- type DriverDataMock
- func (d *DriverDataMock) DriversRedis(city, idDistrict string) []driver.DriverData
- func (d *DriverDataMock) Find(name string) *driver.DriverData
- func (d *DriverDataMock) GetAvailableDriver(city, IdDistrict string) []driver.DriverData
- func (d *DriverDataMock) GetConn(mongoSession *mgo.Session, redisConnection *redis.Client)
- func (d *DriverDataMock) GetLastDistrict(driverId string) string
- func (d *DriverDataMock) GetNearLocation(distance int64, lat, lon float64) []driver.DriverData
- func (d *DriverDataMock) Insert(collecctionName, name string, lat, lon float64, status bool)
- func (d *DriverDataMock) Remove(idDriver, collectionKey string)
- func (d *DriverDataMock) SaveDriversRedis(drivers []driver.DriverData, city, idDistrict string)
- func (d *DriverDataMock) SaveLastDistrict(idDriver, city, idDistrict string)
- func (d *DriverDataMock) Update(city, idDistrict string, driver driver.DriverData) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DriverDataMock ¶
type DriverDataMock struct { Drivers []driver.DriverData Driver driver.DriverData Err error LastDistrict string }
func (*DriverDataMock) DriversRedis ¶
func (d *DriverDataMock) DriversRedis(city, idDistrict string) []driver.DriverData
func (*DriverDataMock) Find ¶
func (d *DriverDataMock) Find(name string) *driver.DriverData
func (*DriverDataMock) GetAvailableDriver ¶
func (d *DriverDataMock) GetAvailableDriver(city, IdDistrict string) []driver.DriverData
returning available driver
func (*DriverDataMock) GetConn ¶
func (d *DriverDataMock) GetConn(mongoSession *mgo.Session, redisConnection *redis.Client)
===================MongoDB====================//
func (*DriverDataMock) GetLastDistrict ¶
func (d *DriverDataMock) GetLastDistrict(driverId string) string
func (*DriverDataMock) GetNearLocation ¶
func (d *DriverDataMock) GetNearLocation(distance int64, lat, lon float64) []driver.DriverData
func (*DriverDataMock) Insert ¶
func (d *DriverDataMock) Insert(collecctionName, name string, lat, lon float64, status bool)
func (*DriverDataMock) Remove ¶
func (d *DriverDataMock) Remove(idDriver, collectionKey string)
func (*DriverDataMock) SaveDriversRedis ¶
func (d *DriverDataMock) SaveDriversRedis(drivers []driver.DriverData, city, idDistrict string)
func (*DriverDataMock) SaveLastDistrict ¶
func (d *DriverDataMock) SaveLastDistrict(idDriver, city, idDistrict string)
func (*DriverDataMock) Update ¶
func (d *DriverDataMock) Update(city, idDistrict string, driver driver.DriverData) error
Click to show internal directories.
Click to hide internal directories.