++ed by:
ADAMJS ALEXBIO ARPI AWNCORP DICHI

13 PAUSE user(s)
4 non-PAUSE user(s).

Alessandro Ghedini

NAME

FFI::Raw::Callback - FFI::Raw function pointer type

VERSION

version 0.32

DESCRIPTION

A FFI::Raw::Callback represents a function pointer to a Perl routine. It can be passed to functions taking a FFI::Raw::ptr type.

METHODS

new( $coderef, $ret_type [, $arg_type ...] )

Create a FFI::Raw::Callback using the code reference $coderef as body. The signature (return and arguments types) must also be passed.

CAVEATS

For callbacks with a FFI::Raw::str return type, the string value will be copied to a private field on the callback object. The memory for this value will be freed the next time the callback is called, or when the callback itself is freed. For more exact control over when the return value is freed, you can instead use FFI::Raw::ptr type and return a FFI::Raw::MemPtr object.

AUTHOR

Alessandro Ghedini <alexbio@cpan.org>

LICENSE AND COPYRIGHT

Copyright 2013 Alessandro Ghedini.

This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.

See http://dev.perl.org/licenses/ for more information.




Hosting generously
sponsored by Bytemark