Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DSNOption ¶
type DSNOption func(*SQLite3DSN)
DSNOption defines a function that configures a SQLite3DSN.
func WithAuthCrypt ¶
WithAuthCrypt sets the auth crypt for the DSN.
func WithAuthPass ¶
WithAuthPass sets the auth password for the DSN.
func WithAuthUser ¶
WithAuthUser sets the auth user for the DSN.
type SQLite3DSN ¶
type SQLite3DSN struct {
Path string `json:"path"`
AuthUser string `json:"_auth_user"`
AuthPass string `json:"_auth_pass"`
AuthCrypt string `json:"_auth_crypt"`
Mode Mode `json:"mode"`
Cache Cache `json:"cache"`
}
func NewDSN ¶
func NewDSN(path string, opts ...DSNOption) *SQLite3DSN
NewDSN creates a new SQLite3DSN with the given options.
func (SQLite3DSN) DSN ¶
func (s SQLite3DSN) DSN() string
func (*SQLite3DSN) Info ¶
func (s *SQLite3DSN) Info() string
Info implements database.DataSourceNamer.
func (SQLite3DSN) Type ¶
func (s SQLite3DSN) Type() database.Type
Type implements database.DataSourceNamer.
Click to show internal directories.
Click to hide internal directories.