Why not adopt me?
NAME
Finance::Bank::Cahoot::CredentialsProvider::Callback - credentials provider that uses a callback to gather the required information
SYNOPSIS
my $credentials = Finance::Bank::Cahoot::CredentialsProvider::Callback->new(
credentials => [qw(account password)],
options => { account => sub { return '12345678' },
username => sub { return 'username' },
password => sub { return substr('verysecret', $_[0]-1, 1) } });
DESCRIPTION
This module provides an implementation of a CredentialsProviderProvider where each of the credentials is provided by a user-supplied callback. All callbacks return a text string. Any callback may be optionally supplied a character offset in the credentials value (first character is 0).
METHODS
- new
-
Create a new instance of the credentials provider. All parameters are mandatory.
- *
-
credentials is an array ref of all the credentials types available via the credentials provider.
- *
-
options is a hash ref of callback routines for each credential.
- get
-
Returns a credential value whose name is passed as the first parameter. An optional character offset (0 is the first character) may also be provided.
my $password_char = $provider->password(5);
AUTHOR
Jon Connell <jon@figsandfudge.com>
LICENSE AND COPYRIGHT
This module borrows heavily from Finance::Bank::Natwest by Jody Belka.
Copyright 2007 by Jon Connell Copyright 2003 by Jody Belka
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
2 POD Errors
The following errors were encountered while parsing the POD:
- Around line 67:
Expected text after =item, not a bullet
- Around line 72:
Expected text after =item, not a bullet