Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gosqlite
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gosqlite
Commits
948bf3ce
Commit
948bf3ce
authored
Feb 21, 2016
by
gwenn
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Document API entries that can't be used with cgocheck enabled.
parent
746114df
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
0 deletions
+12
-0
function.go
function.go
+2
-0
hook.go
hook.go
+3
-0
trace.go
trace.go
+6
-0
vtab.go
vtab.go
+1
-0
No files found.
function.go
View file @
948bf3ce
...
@@ -470,6 +470,7 @@ func goXDestroy(pApp unsafe.Pointer) {
...
@@ -470,6 +470,7 @@ func goXDestroy(pApp unsafe.Pointer) {
const
sqliteDeterministic
=
0x800
// C.SQLITE_DETERMINISTIC
const
sqliteDeterministic
=
0x800
// C.SQLITE_DETERMINISTIC
// CreateScalarFunction creates or redefines SQL scalar functions.
// CreateScalarFunction creates or redefines SQL scalar functions.
// Cannot be used with Go >= 1.6 and cgocheck enabled.
// TODO Make possible to specify the preferred encoding
// TODO Make possible to specify the preferred encoding
// (See http://sqlite.org/c3ref/create_function.html)
// (See http://sqlite.org/c3ref/create_function.html)
func
(
c
*
Conn
)
CreateScalarFunction
(
functionName
string
,
nArg
int32
,
deterministic
bool
,
pApp
interface
{},
func
(
c
*
Conn
)
CreateScalarFunction
(
functionName
string
,
nArg
int32
,
deterministic
bool
,
pApp
interface
{},
...
@@ -498,6 +499,7 @@ func (c *Conn) CreateScalarFunction(functionName string, nArg int32, determinist
...
@@ -498,6 +499,7 @@ func (c *Conn) CreateScalarFunction(functionName string, nArg int32, determinist
}
}
// CreateAggregateFunction creates or redefines SQL aggregate functions.
// CreateAggregateFunction creates or redefines SQL aggregate functions.
// Cannot be used with Go >= 1.6 and cgocheck enabled.
// TODO Make possible to specify the preferred encoding
// TODO Make possible to specify the preferred encoding
// (See http://sqlite.org/c3ref/create_function.html)
// (See http://sqlite.org/c3ref/create_function.html)
func
(
c
*
Conn
)
CreateAggregateFunction
(
functionName
string
,
nArg
int32
,
pApp
interface
{},
func
(
c
*
Conn
)
CreateAggregateFunction
(
functionName
string
,
nArg
int32
,
pApp
interface
{},
...
...
hook.go
View file @
948bf3ce
...
@@ -34,6 +34,7 @@ func goXCommitHook(udp unsafe.Pointer) C.int {
...
@@ -34,6 +34,7 @@ func goXCommitHook(udp unsafe.Pointer) C.int {
}
}
// CommitHook registers a callback function to be invoked whenever a transaction is committed.
// CommitHook registers a callback function to be invoked whenever a transaction is committed.
// Cannot be used with Go >= 1.6 and cgocheck enabled.
// (See http://sqlite.org/c3ref/commit_hook.html)
// (See http://sqlite.org/c3ref/commit_hook.html)
func
(
c
*
Conn
)
CommitHook
(
f
CommitHook
,
udp
interface
{})
{
func
(
c
*
Conn
)
CommitHook
(
f
CommitHook
,
udp
interface
{})
{
if
f
==
nil
{
if
f
==
nil
{
...
@@ -61,6 +62,7 @@ func goXRollbackHook(udp unsafe.Pointer) {
...
@@ -61,6 +62,7 @@ func goXRollbackHook(udp unsafe.Pointer) {
}
}
// RollbackHook registers a callback to be invoked each time a transaction is rolled back.
// RollbackHook registers a callback to be invoked each time a transaction is rolled back.
// Cannot be used with Go >= 1.6 and cgocheck enabled.
// (See http://sqlite.org/c3ref/commit_hook.html)
// (See http://sqlite.org/c3ref/commit_hook.html)
func
(
c
*
Conn
)
RollbackHook
(
f
RollbackHook
,
udp
interface
{})
{
func
(
c
*
Conn
)
RollbackHook
(
f
RollbackHook
,
udp
interface
{})
{
if
f
==
nil
{
if
f
==
nil
{
...
@@ -89,6 +91,7 @@ func goXUpdateHook(udp unsafe.Pointer, action int, dbName, tableName *C.char, ro
...
@@ -89,6 +91,7 @@ func goXUpdateHook(udp unsafe.Pointer, action int, dbName, tableName *C.char, ro
// UpdateHook registers a callback to be invoked each time a row is updated,
// UpdateHook registers a callback to be invoked each time a row is updated,
// inserted or deleted using this database connection.
// inserted or deleted using this database connection.
// Cannot be used with Go >= 1.6 and cgocheck enabled.
// (See http://sqlite.org/c3ref/update_hook.html)
// (See http://sqlite.org/c3ref/update_hook.html)
func
(
c
*
Conn
)
UpdateHook
(
f
UpdateHook
,
udp
interface
{})
{
func
(
c
*
Conn
)
UpdateHook
(
f
UpdateHook
,
udp
interface
{})
{
if
f
==
nil
{
if
f
==
nil
{
...
...
trace.go
View file @
948bf3ce
...
@@ -50,6 +50,7 @@ func goXTrace(udp unsafe.Pointer, sql *C.char) {
...
@@ -50,6 +50,7 @@ func goXTrace(udp unsafe.Pointer, sql *C.char) {
// There can only be a single tracer defined for each database connection.
// There can only be a single tracer defined for each database connection.
// Setting a new tracer clears the old one.
// Setting a new tracer clears the old one.
// If f is nil, the current tracer is removed.
// If f is nil, the current tracer is removed.
// Cannot be used with Go >= 1.6 and cgocheck enabled.
// (See sqlite3_trace, http://sqlite.org/c3ref/profile.html)
// (See sqlite3_trace, http://sqlite.org/c3ref/profile.html)
func
(
c
*
Conn
)
Trace
(
f
Tracer
,
udp
interface
{})
{
func
(
c
*
Conn
)
Trace
(
f
Tracer
,
udp
interface
{})
{
if
f
==
nil
{
if
f
==
nil
{
...
@@ -82,6 +83,7 @@ func goXProfile(udp unsafe.Pointer, sql *C.char, nanoseconds C.sqlite3_uint64) {
...
@@ -82,6 +83,7 @@ func goXProfile(udp unsafe.Pointer, sql *C.char, nanoseconds C.sqlite3_uint64) {
// There can only be a single profiler defined for each database connection.
// There can only be a single profiler defined for each database connection.
// Setting a new profiler clears the old one.
// Setting a new profiler clears the old one.
// If f is nil, the current profiler is removed.
// If f is nil, the current profiler is removed.
// Cannot be used with Go >= 1.6 and cgocheck enabled.
// (See sqlite3_profile, http://sqlite.org/c3ref/profile.html)
// (See sqlite3_profile, http://sqlite.org/c3ref/profile.html)
func
(
c
*
Conn
)
Profile
(
f
Profiler
,
udp
interface
{})
{
func
(
c
*
Conn
)
Profile
(
f
Profiler
,
udp
interface
{})
{
if
f
==
nil
{
if
f
==
nil
{
...
@@ -233,6 +235,7 @@ func goXAuth(udp unsafe.Pointer, action int, arg1, arg2, dbName, triggerName *C.
...
@@ -233,6 +235,7 @@ func goXAuth(udp unsafe.Pointer, action int, arg1, arg2, dbName, triggerName *C.
}
}
// SetAuthorizer sets or clears the access authorization function.
// SetAuthorizer sets or clears the access authorization function.
// Cannot be used with Go >= 1.6 and cgocheck enabled.
// (See http://sqlite.org/c3ref/set_authorizer.html)
// (See http://sqlite.org/c3ref/set_authorizer.html)
func
(
c
*
Conn
)
SetAuthorizer
(
f
Authorizer
,
udp
interface
{})
error
{
func
(
c
*
Conn
)
SetAuthorizer
(
f
Authorizer
,
udp
interface
{})
error
{
if
f
==
nil
{
if
f
==
nil
{
...
@@ -265,6 +268,7 @@ func goXBusy(udp unsafe.Pointer, count int) C.int {
...
@@ -265,6 +268,7 @@ func goXBusy(udp unsafe.Pointer, count int) C.int {
// There can only be a single busy handler defined for each database connection.
// There can only be a single busy handler defined for each database connection.
// Setting a new busy handler clears any previously set handler.
// Setting a new busy handler clears any previously set handler.
// If f is nil, the current handler is removed.
// If f is nil, the current handler is removed.
// Cannot be used with Go >= 1.6 and cgocheck enabled.
// (See http://sqlite.org/c3ref/busy_handler.html)
// (See http://sqlite.org/c3ref/busy_handler.html)
func
(
c
*
Conn
)
BusyHandler
(
f
BusyHandler
,
udp
interface
{})
error
{
func
(
c
*
Conn
)
BusyHandler
(
f
BusyHandler
,
udp
interface
{})
error
{
if
f
==
nil
{
if
f
==
nil
{
...
@@ -299,6 +303,7 @@ func goXProgress(udp unsafe.Pointer) C.int {
...
@@ -299,6 +303,7 @@ func goXProgress(udp unsafe.Pointer) C.int {
// Only a single progress handler may be defined at one time per database connection.
// Only a single progress handler may be defined at one time per database connection.
// Setting a new progress handler cancels the old one.
// Setting a new progress handler cancels the old one.
// If f is nil, the current handler is removed.
// If f is nil, the current handler is removed.
// Cannot be used with Go >= 1.6 and cgocheck enabled.
// (See http://sqlite.org/c3ref/progress_handler.html)
// (See http://sqlite.org/c3ref/progress_handler.html)
func
(
c
*
Conn
)
ProgressHandler
(
f
ProgressHandler
,
numOps
int32
,
udp
interface
{})
{
func
(
c
*
Conn
)
ProgressHandler
(
f
ProgressHandler
,
numOps
int32
,
udp
interface
{})
{
if
f
==
nil
{
if
f
==
nil
{
...
@@ -396,6 +401,7 @@ var logger *sqliteLogger
...
@@ -396,6 +401,7 @@ var logger *sqliteLogger
// ConfigLog configures the logger of the SQLite library.
// ConfigLog configures the logger of the SQLite library.
// Only one logger can be registered at a time for the whole program.
// Only one logger can be registered at a time for the whole program.
// The logger must be threadsafe.
// The logger must be threadsafe.
// Cannot be used with Go >= 1.6 and cgocheck enabled when udp is not nil.
// (See sqlite3_config(SQLITE_CONFIG_LOG,...): http://sqlite.org/c3ref/config.html and http://www.sqlite.org/errlog.html)
// (See sqlite3_config(SQLITE_CONFIG_LOG,...): http://sqlite.org/c3ref/config.html and http://www.sqlite.org/errlog.html)
func
ConfigLog
(
f
Logger
,
udp
interface
{})
error
{
func
ConfigLog
(
f
Logger
,
udp
interface
{})
error
{
var
rv
C
.
int
var
rv
C
.
int
...
...
vtab.go
View file @
948bf3ce
...
@@ -233,6 +233,7 @@ func (c *Conn) DeclareVTab(sql string) error {
...
@@ -233,6 +233,7 @@ func (c *Conn) DeclareVTab(sql string) error {
}
}
// CreateModule registers a virtual table implementation.
// CreateModule registers a virtual table implementation.
// Cannot be used with Go >= 1.6 and cgocheck enabled.
// (See http://sqlite.org/c3ref/create_module.html)
// (See http://sqlite.org/c3ref/create_module.html)
func
(
c
*
Conn
)
CreateModule
(
moduleName
string
,
module
Module
)
error
{
func
(
c
*
Conn
)
CreateModule
(
moduleName
string
,
module
Module
)
error
{
mname
:=
C
.
CString
(
moduleName
)
mname
:=
C
.
CString
(
moduleName
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment