| 1 |
|
|
| 2 |
package SuikaWiki::DB::Util; |
=head1 NAME |
| 3 |
|
|
| 4 |
|
SuikaWiki::DB::Util --- SuikaWiki WikiDatabase: WikiDatabase modules common utilities |
| 5 |
|
|
| 6 |
|
=head1 DESCRIPTION |
| 7 |
|
|
| 8 |
|
This module provides some functions expected to be useful for most WikiDatabase |
| 9 |
|
implememtation modules. |
| 10 |
|
|
| 11 |
|
This module is part of SuikaWiki. |
| 12 |
|
|
| 13 |
|
=cut |
| 14 |
|
|
| 15 |
|
package SuikaWiki::DB::Util; |
| 16 |
|
use strict; |
| 17 |
|
our $VERSION=do{my @r=(q$Revision$=~/\d+/g);sprintf "%d."."%02d" x $#r,@r}; |
| 18 |
our $Err; |
our $Err; |
| 19 |
|
|
| 20 |
=head1 PROCEDURES |
=head1 FUNCTIONS |
| 21 |
|
|
| 22 |
=over 4 |
=over 4 |
| 23 |
|
|
| 32 |
my (undef, %opt) = @_; |
my (undef, %opt) = @_; |
| 33 |
|
|
| 34 |
require Message::Util::Error; |
require Message::Util::Error; |
| 35 |
$Err = Message::Util::Error->new ( |
$Err = Message::Util::Error->new ({ |
| 36 |
## Error level: |
## Error level: |
| 37 |
## - stop: cannot continue the operation (but other operations |
## - stop: cannot continue the operation (but other operations |
| 38 |
## might be able to be performed) |
## might be able to be performed) |
| 80 |
description => 'Unknown error', |
description => 'Unknown error', |
| 81 |
}, |
}, |
| 82 |
-error_handler => $opt{-error_handler}, |
-error_handler => $opt{-error_handler}, |
| 83 |
); |
}); |
| 84 |
$err; |
$Err; |
| 85 |
} |
} |
| 86 |
|
|
| 87 |
=item SuikaWiki::DB::Util->new_lock ($options) |
=item $locker = SuikaWiki::DB::Util->new_lock ($options) |
| 88 |
|
|
| 89 |
Returns new locker object (SuikaWiki::DB::Util::Lock instance). |
Returns new locker object (SuikaWiki::DB::Util::Lock instance). |
| 90 |
|
|
| 99 |
|
|
| 100 |
=cut |
=cut |
| 101 |
|
|
| 102 |
|
=head1 SEE ALSO |
| 103 |
|
|
| 104 |
|
C<SuikaWiki::DB> |
| 105 |
|
|
| 106 |
|
=head1 AUTHOR |
| 107 |
|
|
| 108 |
|
Wakaba <[email protected]>. |
| 109 |
|
|
| 110 |
|
=head1 LICENSE |
| 111 |
|
|
| 112 |
|
Copyright AUTHOR 2003. |
| 113 |
|
|
| 114 |
|
This program is free software; you can redistribute it and/or |
| 115 |
|
modify it under the same terms as Perl itself. |
| 116 |
|
|
| 117 |
|
=cut |
| 118 |
|
|
| 119 |
1; # $Date$ |
1; # $Date$ |