new#

Create a Digest::SHA1 object, or reset an existing one.

Called on a class it returns a new object of that class, ready for the empty message. Called on an object it forgets what was added and returns the same object.

Synopsis#

my $ctx = Digest::SHA1->new;
$ctx->add($data);
$ctx->new;                 # back to the empty message