java.lang.Object | |
↳ | android.database.DatabaseUtils.InsertHelper |
This class was deprecated
in API level 17.
Use
SQLiteStatement
instead.
This class allows users to do multiple inserts into a table using the same statement.
This class is not thread-safe.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
|
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
|
Bind the value to an index.
|
||||||||||
|
Bind the value to an index.
|
||||||||||
|
Bind the value to an index.
|
||||||||||
|
Bind the value to an index.
|
||||||||||
|
Bind the value to an index.
|
||||||||||
|
Bind the value to an index.
|
||||||||||
|
Bind the value to an index.
|
||||||||||
|
Bind null to an index.
|
||||||||||
|
Close this object and release any resources associated with
it.
|
||||||||||
|
Execute the previously prepared insert or replace using the bound values
since the last call to prepareForInsert or prepareForReplace.
|
||||||||||
|
Returns the index of the specified column.
|
||||||||||
|
Performs an insert, adding a new row with the given values.
|
||||||||||
|
Prepare the InsertHelper for an insert.
|
||||||||||
|
Prepare the InsertHelper for a replace.
|
||||||||||
|
Performs an insert, adding a new row with the given values.
|
[Expand]
Inherited Methods
|
|||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
db | the SQLiteDatabase to insert into |
---|---|
tableName | the name of the table to insert into |
Bind the value to an index. A prepareForInsert() or prepareForReplace() without a matching execute() must have already have been called.
index | the index of the slot to which to bind |
---|---|
value | the value to bind |
Bind the value to an index. A prepareForInsert() or prepareForReplace() without a matching execute() must have already have been called.
index | the index of the slot to which to bind |
---|---|
value | the value to bind |
Bind the value to an index. A prepareForInsert() or prepareForReplace() without a matching execute() must have already have been called.
index | the index of the slot to which to bind |
---|---|
value | the value to bind |
Bind the value to an index. A prepareForInsert() or prepareForReplace() without a matching execute() must have already have been called.
index | the index of the slot to which to bind |
---|---|
value | the value to bind |
Bind the value to an index. A prepareForInsert() or prepareForReplace() without a matching execute() must have already have been called.
index | the index of the slot to which to bind |
---|---|
value | the value to bind |
Bind the value to an index. A prepareForInsert() or prepareForReplace() without a matching execute() must have already have been called.
index | the index of the slot to which to bind |
---|---|
value | the value to bind |
Bind the value to an index. A prepareForInsert() or prepareForReplace() without a matching execute() must have already have been called.
index | the index of the slot to which to bind |
---|---|
value | the value to bind |
Bind null to an index. A prepareForInsert() or prepareForReplace() without a matching execute() must have already have been called.
index | the index of the slot to which to bind |
---|
Close this object and release any resources associated with
it. The behavior of calling
insert()
after
calling this method is undefined.
Execute the previously prepared insert or replace using the bound values since the last call to prepareForInsert or prepareForReplace.
Note that calling bind() and then execute() is not thread-safe. The only thread-safe way to use this class is to call insert() or replace().
Returns the index of the specified column. This is index is suitagble for use in calls to bind().
key | the column name |
---|
Performs an insert, adding a new row with the given values. If the table contains conflicting rows, an error is returned.
values | the set of values with which to populate the new row |
---|
Prepare the InsertHelper for an insert. The pattern for this is:
Prepare the InsertHelper for a replace. The pattern for this is:
Performs an insert, adding a new row with the given values. If the table contains conflicting rows, they are deleted and replaced with the new row.
values | the set of values with which to populate the new row |
---|