1
0
forked from MTSR/mapserver
This commit is contained in:
NatureFreshMilk 2019-02-14 09:05:39 +01:00
parent 52b29dbd47
commit a0a8569168
10 changed files with 16 additions and 27 deletions

View File

@ -2,8 +2,8 @@ package db
import (
"mapserver/coords"
"mapserver/settings"
"mapserver/layer"
"mapserver/settings"
)
type Block struct {

View File

@ -1,12 +1,14 @@
package postgres
import (
"mapserver/settings"
"mapserver/layer"
"mapserver/db"
"mapserver/layer"
"mapserver/settings"
)
const (
SETTING_LAST_LAYER = "last_layer"
)
func (this *PostgresAccessor) FindNextInitialBlocks(s settings.Settings, layers []*layer.Layer, limit int) (*db.InitialBlocksResult, error) {
return nil, nil

View File

@ -1,6 +1,5 @@
package postgres
const getBlocksByMtimeQuery = `
select posx,posy,posz,data,mtime
from blocks b
@ -9,17 +8,6 @@ order by b.mtime asc
limit ?
`
const getLastBlockQuery = `
select posx,posy,posz,data,mtime
from blocks b
where b.mtime = 0
and b.posx >= ?
and b.posy >= ?
and b.posz >= ?
order by b.posx asc, b.posy asc, b.posz asc, b.mtime asc
limit ?
`
const countBlocksQuery = `
select count(*) from blocks b where b.mtime >= ? and b.mtime <= ?
`

View File

@ -4,8 +4,8 @@ import (
_ "github.com/mattn/go-sqlite3"
"mapserver/coords"
"mapserver/db"
"mapserver/settings"
"mapserver/layer"
"mapserver/settings"
)
const (

View File

@ -3,8 +3,8 @@ package mapblockaccessor
import (
"mapserver/eventbus"
"mapserver/layer"
"mapserver/settings"
"mapserver/mapblockparser"
"mapserver/settings"
cache "github.com/patrickmn/go-cache"
"github.com/sirupsen/logrus"

View File

@ -1,6 +1,5 @@
package sqlite
const getMapDataPosQuery = `
select o.id, o.type, o.mtime,
o.x, o.y, o.z,