AptPkg::hash - Online Linux Manual PageSection : 3pm
Updated : 2021-02-15
Source : perl v5.32.1
Note : User Contributed Perl Documentation

NAMEAptPkg::hash − a helper class for implementing tied hashes

SYNOPSISuse AptPkg::hash;

DESCRIPTIONThe AptPkg::hash class provides hash-like access for objects which have an underlying XS implementation. Such objects need to add AptPkg::hash to @ISA, provide get, set and exists methods, and an iterator class.

AptPkg::hashnew([XS_OBJECT]) Create a object as a tied hash. The object is implemented as a hash reference blessed into the class, which in turn is tied to AptPkg::hash. This means that both $obj>method() and $obj>{key} valid, the latter invoking get/set (through FETCH/STORE). The tie associates an array reference with the hash, which initially contains a reference to the hash, the XS object and an anon hash which may be used by subclasses to store state information. If no XS object is passed, one is created via new in the XS class. The name of that class is constructed from the class name, by lower-casing the last component and prefixing it with an underscore (eg. AptPkg::Config becomes AptPkg::_config). If the module contains a @KEYS array, then the private hash will be populated with those entries as keys (see the description below of the AptPkg::hash::method class). _self, _xs, _priv Accessors which may be used in subclass methods to fetch the three array elements associated with the hash reference. keys(ARGS) In a scalar context, creates and returns a new iterator object (the class name with the suffix ::Iter appended). The XS object, the private hash and any arguments are passed to the constructor. In an array context, the iterator is used to generate a list of keys which are then returned. The iterator class must implement a next method, which returns the current key and advances to the next.

AptPkg::hash::methodThe AptPkg::hash::method class extends AptPkg::hash, providing a simple way to map a fixed set of keys (defined by the @KEYS array) into method calls on either the object, or the internal XS object. Classes inheriting from AptPkg::hash::method should provide an iterator class which inherits from AptPkg::hash::method::iter.

AUTHORBrendan O'Dea <bod@debian.org>
0
Johanes Gumabo
Data Size   :   6,904 byte
man-AptPkg::hash.3pmBuild   :   2024-12-29, 07:25   :  
Visitor Screen   :   x
Visitor Counter ( page / site )   :   4 / 257,544
Visitor ID   :     :  
Visitor IP   :   18.222.179.96   :  
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|AptPkg::hash.3pm|36/37|el══─{─══.|.el══─{─══. ds -- \|\(em\| )         (htmlprn|149|AptPkg::hash.3pm|36/37|.el══─{─══. ds --  —  |.el══─{─══. ds -- \|\(em\| )         (parse_manual_page_|252|AptPkg::hash.3pm|43|br══─}─══|'br══─}─══ )         (htmlprn|149|AptPkg::hash.3pm|43|'br══─}─══ |'br══─}─══ )