NAME
Locale::TextDomain::OO::FunctionalInterface - Call object methods as functions
$Id: FunctionalInterface.pm 252 2009-12-29 13:55:33Z steffenw $
$HeadURL: https://perl-gettext-oo.svn.sourceforge.net/svnroot/perl-gettext-oo/module/trunk/lib/Locale/TextDomain/OO/FunctionalInterface.pm $
VERSION
0.03
DESCRIPTION
This module wraps the object and allows to call a method as a function. Then the interface of the translating subroutines is compatible to module Locale::TextDomain.
SYNOPSIS
use Locale::TextDomain::OO::FunctionalInterface;
or
use Locale::TextDomain::OO::FunctionalInterface qw(bind_object);
SUBROUTINES/METHODS
subroutine bind_object
$loc = Locale::TextDomain::OO->new(...);
or
$loc = Locale::TextDomain::OO::Maketext->new(...);
and
bind_object($loc); # import all possible methods
or
bind_object($loc, qw(__ __x ...)); # import only the given methods
EXAMPLE
Inside of this distribution is a directory named example. Run this *.pl files.
DIAGNOSTICS
Subroutine bind_object can not bind an undef as method name.
An undefined value is not a method name
Subroutine bind_object only can bind translating subroutines.
Method "..." is not a translation method
Subroutine bind_object can not bind a non existing object method.
Object has no method named "..."
CONFIGURATION AND ENVIRONMENT
none
DEPENDENCIES
version
Carp
INCOMPATIBILITIES
not known
BUGS AND LIMITATIONS
none
SEE ALSO
Locale::TextDomain::OO::Maketext
AUTHOR
Steffen Winkler
LICENSE AND COPYRIGHT
Copyright (c) 2009, Steffen Winkler <steffenw at cpan.org>
. All rights reserved.
This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.