Test2::Util::ExternalMeta - Online Linux Manual PageSection : 3
Updated : 2022-03-05
Source : perl v5.34.0
Note : User Contributed Perl Documentation

NAMETest2::Util::ExternalMeta − Allow third party tools to safely attach meta−data to your instances.

DESCRIPTIONThis package lets you define a clear, and consistent way to allow third party tools to attach meta-data to your instances. If your object consumes this package, and imports its methods, then third party meta-data has a safe place to live.

SYNOPSIS​ package My::Object; ​ use strict; ​ use warnings; ​ ​ use Test2::Util::ExternalMeta qw/meta get_meta set_meta delete_meta/; ​ ​ ... Now to use it: ​ my $inst = My::Object−>new; ​ ​ $inst−>set_meta(foo => 'bar'); ​ my $val = $inst−>get_meta('foo');

WHERE IS THE DATA STORED?This package assumes your instances are blessed hashrefs, it will not work if that is not true. It will store all meta-data in the _meta key on your objects hash. If your object makes use of the _meta key in its underlying hash, then there is a conflict and you cannot use this package.

EXPORTS$val = $obj>meta($key) $val = $obj>meta($key, $default) This will get the value for a specified meta $key. Normally this will return ​undef when there is no value for the $key, however you can specify a ​$default value to set when no value is already set. $val = $obj>get_meta($key) This will get the value for a specified meta $key. This does not have the ​$default overhead that meta() does. $val = $obj>delete_meta($key) This will remove the value of a specified meta $key. The old $val will be returned. $obj>set_meta($key, $val) Set the value of a specified meta $key.

META-KEY RESTRICTIONSMeta keys must be defined, and must be true when used as a boolean. Keys may not be references. You are free to stringify a reference "$ref" for use as a key, but this package will not stringify it for you.

SOURCEThe source code repository for Test2 can be found at ​http://github.com/Test−More/test−more/.

MAINTAINERSChad Granum <exodist@cpan.org> 

AUTHORSChad Granum <exodist@cpan.org> 

COPYRIGHTCopyright 2020 Chad Granum <exodist@cpan.org>. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See http://dev.perl.org/licenses/
0
Johanes Gumabo
Data Size   :   10,700 byte
man-Test2::Util::ExternalMeta.3pmBuild   :   2024-12-29, 07:25   :  
Visitor Screen   :   x
Visitor Counter ( page / site )   :   4 / 255,627
Visitor ID   :     :  
Visitor IP   :   3.145.172.11   :  
Visitor Provider   :   AMAZON-02   :  
Provider Position ( lat x lon )   :   39.962500 x -83.006100   :   x
Provider Accuracy Radius ( km )   :   1000   :  
Provider City   :   Columbus   :  
Provider Province   :   Ohio ,   :   ,
Provider Country   :   United States   :  
Provider Continent   :   North America   :  
Visitor Recorder   :   Version   :  
Visitor Recorder   :   Library   :  
Online Linux Manual Page   :   Version   :   Online Linux Manual Page - Fedora.40 - march=x86-64 - mtune=generic - 24.12.29
Online Linux Manual Page   :   Library   :   lib_c - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Online Linux Manual Page   :   Library   :   lib_m - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Data Base   :   Version   :   Online Linux Manual Page Database - 24.04.13 - march=x86-64 - mtune=generic - fedora-38
Data Base   :   Library   :   lib_c - 23.02.07 - march=x86-64 - mtune=generic - fedora.36

Very long time ago, I have the best tutor, Wenzel Svojanovsky . If someone knows the email address of Wenzel Svojanovsky , please send an email to johanes_gumabo@yahoo.co.id .
If error, please print screen and send to johanes_gumabo@yahoo.co.id
Under development. Support me via PayPal.

ERROR : Need New Coding :         (parse_manual_page_|252|Test2::Util::ExternalMeta.3pm|36/37|el══─{─══.|.el══─{─══. ds -- \|\(em\| )         (htmlprn|149|Test2::Util::ExternalMeta.3pm|36/37|.el══─{─══. ds --  —  |.el══─{─══. ds -- \|\(em\| )         (parse_manual_page_|252|Test2::Util::ExternalMeta.3pm|43|br══─}─══|'br══─}─══ )         (htmlprn|149|Test2::Util::ExternalMeta.3pm|43|'br══─}─══ |'br══─}─══ )