Граф коммитов

5 Коммитов

Автор SHA1 Сообщение Дата
Boris Zbarsky 4073a4a809 Bug 1551929. Mark some storage interfaces builtinclass, since we assume there are no JS implementations already. r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D31342

--HG--
extra : moz-landing-system : lando
2019-05-16 11:23:44 +00:00
Lina Cambridge 9dee2518ef Bug 1543295 - Pass the text length when creating an `nsString` from a SQLite text result. r=mak
This commit updates mozStorage to always:

* Pass the length, using sqlite3_{column, value}_bytes16, when
  creating an nsDependentString from a pointer.
* Call sqlite3_{column, value}_bytes{16} after
  sqlite3_{column, value}_{text, blob, text16}, per the
  recommendation in https://www.sqlite.org/c3ref/column_blob.html.
  Some callers did this before, or in unclear order, since C++ doesn't
  specify one for evaluating function arguments.
* Pass the byte length to sqlite3_result_text16.

Differential Revision: https://phabricator.services.mozilla.com/D26848

--HG--
extra : moz-landing-system : lando
2019-04-11 03:19:39 +00:00
Lina Cambridge 3e894ac30e Bug 1482608 - Add basic Rust bindings for mozStorage. r=nika,asuth,mak
This commit wraps just enough of the mozStorage API to support the
bookmarks mirror. It's not complete: for example, there's no way
to open, clone, or close a connection, because the mirror handles
that from JS. The wrapper also omits shutdown blocking and retrying on
`SQLITE_BUSY`.

This commit also changes the behavior of sync and async mozStorage
connections. Async (`mozIStorageAsyncConnection`) methods may be called
from any thread on any connection. Sync (`mozIStorageConnection`)
methods may be called from any thread on a sync connection, and from
background threads on an async connection. All connections now QI
to `mozIStorageConnection`, but attempting to call a sync method on
an async connection from the main thread throws.

Finally, this commit exposes an `OpenedConnection::unsafeRawConnection`
getter in Sqlite.jsm, for JS code to access the underlying connection.

Differential Revision: https://phabricator.services.mozilla.com/D20073

--HG--
extra : moz-landing-system : lando
2019-03-25 04:49:18 +00:00
Marco Bonardo 100acd6188 Bug 1313309 - Remove getColumnDecltype and compile with SQLITE_OMIT_DECLTYPE. r=asuth
MozReview-Commit-ID: 2QR8P7ylg9m

--HG--
extra : rebase_source : 37ed75d0cf724a6c373df6d12df1f36fddc0a646
2016-11-03 21:04:00 +01:00
Birunthan Mohanathas 11f2166660 Bug 1164717 - Flatten storage/public/ directory. r=mak
--HG--
rename : storage/public/StatementCache.h => storage/StatementCache.h
rename : storage/public/mozIStorageAggregateFunction.idl => storage/mozIStorageAggregateFunction.idl
rename : storage/public/mozIStorageAsyncConnection.idl => storage/mozIStorageAsyncConnection.idl
rename : storage/public/mozIStorageAsyncStatement.idl => storage/mozIStorageAsyncStatement.idl
rename : storage/public/mozIStorageBaseStatement.idl => storage/mozIStorageBaseStatement.idl
rename : storage/public/mozIStorageBindingParams.idl => storage/mozIStorageBindingParams.idl
rename : storage/public/mozIStorageBindingParamsArray.idl => storage/mozIStorageBindingParamsArray.idl
rename : storage/public/mozIStorageCompletionCallback.idl => storage/mozIStorageCompletionCallback.idl
rename : storage/public/mozIStorageConnection.idl => storage/mozIStorageConnection.idl
rename : storage/public/mozIStorageError.idl => storage/mozIStorageError.idl
rename : storage/public/mozIStorageFunction.idl => storage/mozIStorageFunction.idl
rename : storage/public/mozIStoragePendingStatement.idl => storage/mozIStoragePendingStatement.idl
rename : storage/public/mozIStorageProgressHandler.idl => storage/mozIStorageProgressHandler.idl
rename : storage/public/mozIStorageResultSet.idl => storage/mozIStorageResultSet.idl
rename : storage/public/mozIStorageRow.idl => storage/mozIStorageRow.idl
rename : storage/public/mozIStorageService.idl => storage/mozIStorageService.idl
rename : storage/public/mozIStorageStatement.idl => storage/mozIStorageStatement.idl
rename : storage/public/mozIStorageStatementCallback.idl => storage/mozIStorageStatementCallback.idl
rename : storage/public/mozIStorageStatementParams.idl => storage/mozIStorageStatementParams.idl
rename : storage/public/mozIStorageStatementRow.idl => storage/mozIStorageStatementRow.idl
rename : storage/public/mozIStorageVacuumParticipant.idl => storage/mozIStorageVacuumParticipant.idl
rename : storage/public/mozIStorageValueArray.idl => storage/mozIStorageValueArray.idl
rename : storage/public/mozStorageHelper.h => storage/mozStorageHelper.h
rename : storage/public/storage.h => storage/storage.h
2015-05-19 10:47:29 -07:00