sqlite library
This library exposes the core functionality of the json_sqlite package.
Classes
- DatabaseUpgrader
- A mixin whose methods are invoked by the scheme migration as callbacks.
- FullId
- A subclass of SqlId that has both rowid and keyid unique identifiers.
- IndexColumn
- A description used within a PartialIndex to define column indexing.
- KeyId
- A subclass of SqlId that has only the keyid unique identifier.
- PagedResult
- An Iterable that can be iterated over pages of rows.
- PagedResultIterator
- An Iterator that can iterate over pages of rows.
- PartialIndex
- A description used within a Scheme to define a partial index.
- Query
- Implements the capability of database querying.
- RowId
- A subclass of SqlId that has only the rowid unique identifier.
- Scheme
- A description of a configurable part of a database schema.
- SchemeElement
- A base class for classes that describe aspects of a Scheme.
- SchemeMigrationPlan
- Determines a sequence of logical actions to create or migrate a scheme.
- SearchColumn
- A description used within a SearchIndex to define an FTS column.
- SearchIndex
- A description used within a Scheme to define an FTS index.
- SearchIndexUpdater
- SQL statements associated with a SearchIndex.
- SqlId
- A sealed class representing the unique ID of a mapping table row.
- SQLite
- A class for creating, opening, querying, and updating databases.
- SQLiteQuery
- A helper base class for a typical usage scenario of a query.
- Transaction
- Accumulates edits to the mapping table in a memory buffer.
- VirtualColumn
- A description used within a Scheme to define a generated virtual column.
Enums
- QueryDirection
- The direction in which to select rows relative to a starting position.
- QueryDistinction
- Whether to use rowid or keyid as the last mandatory sorting column.
- QuerySorting
- Sort the rows of a query in ascending or descending order.
Constants
- columnKeyId → const String
- The name of the keyid column.
- columnKind → const String
- The name of the kind virtual column.
- columnRank → const String
- The name of the rank FTS column.
- columnRowId → const String
- The name of the rowid column.
- columnValue → const String
- The name of the value column.
- ftsTermJoiner → const String
- A special character used by ftsTerm to replace non-token characters.
- keyDefinition → const String
- The keyid value of the row that contains a stored scheme.
- queryDefaultLimit → const int
- A limit for SQLite.prepare used internally during scheme migration.
- schemaDefaultVersion → const int
- The default version of a database schema.
- schemaVersion → const int
- The version of a database schema.
- schemeInitialRevision → const int
- The initial (default) revision of a Scheme.
- standardDataPath → const String
-
The JSON path to extract the
datafield from JSON composite values. - standardKindPath → const String
-
The JSON path to extract
Kinds from JSON composite values. - tableMapping → const String
- The name of the mapping table.
- tableScheme → const String
- The name of the scheme table.
- tokenCategories → const String
- Unicode categories allowed as part of an SQLite FTS token.
- unsetKindPath → const String
-
The unset JSON path that indicates avoiding the processing of
Kinds.
Properties
- reFtsTermToken → RegExp
-
A regexp matching an extended FTS token.
final
- reFtsTextToken → RegExp
-
A regexp matching a standard FTS token.
final
Functions
-
escapeSingleQuotes(
String string) → String - Escapes single quotes in a String.
-
ftsString(
String string) → String - Escapes and quotes a String for use as an FTS expression string.
-
ftsTerm(
String string, [Level? ll = Level.WARNING]) → String - Prepares a String for use as an extended FTS token.
-
ftsText(
String string) → String - Prepares ordinary text for assignment to an FTS field.
-
ftsWords(
String string) → Iterable< String> - Extracts all standard FTS tokens from a String.
-
queryOrdering(
Sql sql, [QuerySorting sorting = QuerySorting.ascending]) → QueryOrdering - Returns a QueryOrdering record initialized with the given arguments.
-
queryRow(
FullId id, QueryRowOrdered ordered, QueryRowColumns columns) → QueryRow - Returns a QueryRow record initialized with the given arguments.
-
queryRowGetPosition(
QueryRow row) → QueryRowPosition -
Returns the QueryRowPosition record for the given
row. -
quoteWithDoubleQuotes(
String string) → String - Escapes and quotes a String using double quotes.
-
quoteWithSingleQuotes(
String string) → String - Escapes and quotes a String using single quotes.
-
sqlIdentifier(
String name) → String - Escapes and quotes a non-empty String for use as an SQLite identifier.
-
sqlLiteral(
Object? value) → String - Converts a nullable Object to an SQLite literal value.
-
unquoteDoubleQuotes(
String string) → String - Unquotes and unescapes a String escaped and quoted with double quotes.
Typedefs
-
FullIdIterable
= Iterable<
FullId> - An Iterable of FullIds.
- FullIdWithValue = ({FullId id, Object value})
- The return type of the SQLite.select method.
-
IndexColumns
= List<
IndexColumn> - A List of IndexColumns.
-
KindList
= List<
Kind> -
A List of
Kinds. -
PartialIndexes
= List<
PartialIndex> - A List of PartialIndexes.
- QueryId = int
- An ID associated with a Query.
- QueryOrdering = ({QuerySorting sorting, Sql sql})
-
The type of the elements in the
orderargument of SQLite.prepare. -
QueryParameters
= Map<
String, Object> - A value binding map of named parameters for a query's SQL statement.
- QueryRow = ({QueryRowColumns columns, FullId id, QueryRowOrdered ordered})
- The type of the elements in a list returned by SQLite.query.
-
QueryRowColumns
= List<
Object?> -
The type of the
columnsfield of QueryRow. -
QueryRowOrdered
= List<
Kind> -
The type of the
orderedfield of QueryRow. - QueryRowPosition = ({FullId id, QueryRowOrdered ordered})
- An identifier of a QueryRow position within a result set.
-
QueryRows
= List<
QueryRow> - A List of QueryRows.
-
SearchColumns
= List<
SearchColumn> - A List of SearchColumns.
-
SearchIndexes
= List<
SearchIndex> - A List of SearchIndexes.
-
SearchRow
= Map<
String, Object> - The return type of SearchRowGetter callbacks.
- SearchRowGetter = SearchRow Function(Object value)
-
The signature of a callback that converts a JSON
valueinto a SearchRow. -
SearchRowGetters
= Map<
Kind, SearchRowGetter> -
The type of the
gettersargument to SearchIndex.new. -
SearchRowsUpdaters
= IList<
({SearchIndexUpdater indexUpdater, SearchRowGetter rowGetter})> -
An
IListof SearchIndexUpdater/SearchRowGetter pairs. -
VirtualColumns
= List<
VirtualColumn> - A List of VirtualColumns.