summaryrefslogtreecommitdiff
path: root/lib/App/Hashl.pm
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2012-08-19 12:12:30 +0200
committerDaniel Friesel <derf@finalrewind.org>2012-08-19 12:14:51 +0200
commitef33ea24e3e472d8098bd490043e5c0f53d9374c (patch)
tree338af381bca50437c37de2c020a8cf59b49d3f9d /lib/App/Hashl.pm
parent0e96a7165de21a1e14d106224ab41d58a1b65db1 (diff)
move db_info into Hashl.pm
Diffstat (limited to 'lib/App/Hashl.pm')
-rw-r--r--lib/App/Hashl.pm9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/App/Hashl.pm b/lib/App/Hashl.pm
index dc5fca5..f17f771 100644
--- a/lib/App/Hashl.pm
+++ b/lib/App/Hashl.pm
@@ -107,6 +107,15 @@ sub read_size {
return $self->{config}->{read_size};
}
+sub db_info {
+ my ($self) = @_;
+
+ return sprintf(
+ "Database created by hashl v%s\n" . "Read size: %d bytes (%s)\n",
+ $self->db_version, $self->read_size, $self->si_size( $self->read_size ),
+ );
+}
+
sub db_version {
my ($self) = @_;