Mojo::SQLite::Transaction(3pm)

Mojo::SQLite::Transaction3pm

Transaction

Usage

  use Mojo::SQLite::Transaction;
  my $tx = Mojo::SQLite::Transaction->new(db => $db);
  $tx->commit;

Overview

Mojo::SQLite::Transaction is a scope guard for DBD::SQLite transactions used by Mojo::SQLite::Database.

Attributes

Mojo::SQLite::Transaction implements the following attributes.

db

  my $db = $tx->db;
  $tx    = $tx->db(Mojo::SQLite::Database->new);

Mojo::SQLite::Database object this transaction belongs to. Note that this attribute is weakened.

Methods

Mojo::SQLite::Transaction inherits all methods from Mojo::Base and implements the following new ones.

new

  my $tx = Mojo::SQLite::Transaction->new;
  my $tx = Mojo::SQLite::Transaction->new(db => Mojo::SQLite::Database->new);
  my $tx = Mojo::SQLite::Transaction->new({db => Mojo::SQLite::Database->new});

Construct a new Mojo::SQLite::Transaction object.

commit

  $tx->commit;

Commit transaction.

Releases

4 releases since Debian 10 (Buster); the text changed 2 times.

  1. 10
  2. 11
  3. 12–13

Bugs

Report any issues on the public bugtracker.

Author

Dan Book, "[email protected]"

From libmojo-sqlite-perl 3.009-2 in Debian 13 (Trixie). Parsed by carta from the page's man source.