Red::Driver
Base role for a Red::Driver::*
has Supply $.events
Supply of events of that driver
method begin
method begin() returns Mu
Begin transaction
method commit
method commit() returns Mu
Commit transaction
method rollback
method rollback() returns Mu
Rollback transaction
method auto-register
method auto-register(
|
) returns Mu
Self-register its events on Red.events
method emit
method emit(
$data?
) returns Mu
Emit events
method should-drop-cascade
method should-drop-cascade() returns Mu
Does this driver accept drop table cascade?
method emit
method emit(
Red::Event $event
) returns Mu
Emit events
method prepare
method prepare(
Red::AST $query
) returns Mu
Prepares a DB statement
method is-valid-table-name
method is-valid-table-name(
Str $
) returns Bool
Checks if a name is a valid table name
method type-by-name
method type-by-name(
"varchar"
) returns "varchar(255)"
Maps types
method type-by-name
method type-by-name(
"string"
) returns "text"
Maps types
method type-by-name
method type-by-name(
"int"
) returns "integer"
Maps types
method map-exception
method map-exception(
$orig-exception
) returns Mu
Maps exception
method inflate
method inflate(
$value,
:$to
) returns Mu
Default inflator
method execute
method execute(
$query,
*@bind
) returns Mu
Execute query
method optimize
method optimize(
Red::AST $in
) returns Red::AST
Optimize AST