InsertMode enum

Enumeration of different insert behaviors. See the documentation on the individual fields for details.

Implemented types




insert → const InsertMode

A regular INSERT INTO statement. When a row with the same primary or unique key already exists, the insert statement will fail and an exception will be thrown. If the exception is caught, previous statements made in the same transaction will NOT be reverted.

replace → const InsertMode

Identical to InsertMode.insertOrReplace, included for the sake of completeness.

insertOrReplace → const InsertMode

Like insert, but if a row with the same primary or unique key already exists, it will be deleted and re-created with the row being inserted.

insertOrRollback → const InsertMode

Similar to InsertMode.insertOrAbort, but it will revert the surrounding transaction if a constraint is violated, even if the thrown exception is caught.

insertOrAbort → const InsertMode

Identical to insert, included for the sake of completeness.

insertOrFail → const InsertMode

Like insert, but if multiple values are inserted with the same insert statement and one of them fails, the others will still be completed.

insertOrIgnore → const InsertMode

Like insert, but failures will be ignored.


hashCode int
The hash code for this object.
index int
A numeric identifier for the enumerated value.
runtimeType Type
A representation of the runtime type of the object.


noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
toString() String
A string representation of this object.
writeInto(GenerationContext ctx) → void
Writes this component into the context by writing to its GenerationContext.buffer or by introducing bound variables. When writing into the buffer, no whitespace around the this component should be introduced. When a component consists of multiple composed component, it's responsible for introducing whitespace between its child components.


operator ==(Object other) bool
The equality operator.


values → const List<InsertMode>
A constant List of the values in this enum, in order of their declaration.
[insert, replace, insertOrReplace, insertOrRollback, insertOrAbort, insertOrFail, insertOrIgnore]