func Open(path string, opt Options) (*BoltAPI, error) {
	db := new(BoltAPI)
	var err error
	if _, err := os.Stat(path); os.IsNotExist(err) {
		return nil, err
	}
	options := &bolt.Options{Timeout: time.Second}
	if opt.ReadOnly {
		options.ReadOnly = true
		db.ReadOnly = true
	}
	db.db, err = bolt.Open(path, 0600, options)
	if err != nil {
		if err == bolt.ErrTimeout {
			return nil, fmt.Errorf("The database is already opened")
		}
		return nil, err
	}
	db.pages.add()
	db.DBPath = path
	db.Name = filepath.Base(path)
	file, _ := os.Stat(path)
	db.Size = file.Size()
	return db, nil
}
Open returns info about the file of db, wrapper for *bolt.DB
package db
import (
	"fmt"
	"os"
	"path/filepath"
	"regexp"
	"runtime"
	"strings"
	"time"
	"github.com/ShoshinNikita/bolt"
	"github.com/mitchellh/go-homedir"
)
const (
	bucketTemplate = "bucket"
	recordTemplate = "record"
)
var maxOffset = 100
type BoltAPI struct {
	db            *bolt.DB
	currentBucket []string
	pages         pagesStack
	recordsAmount int     
	Name          string `json:"name"`
	DBPath        string `json:"dbPath"`
	Size          int64  `json:"size"`
	ReadOnly      bool
}
type Record struct {
	T     string `json:"type"`
	Key   string `json:"key"`
	Value string `json:"value"`
}
type Data struct {
	Records       []Record
	PrevBucket    bool
	PrevRecords   bool
	NextRecords   bool
	RecordsAmount int
	Path          string
}
type Options struct {
	ReadOnly bool
}
func SetOffset(offset int) {
	maxOffset = offset
}