++ed by:
ABRAXXA ADAMJS ALEXBIO ANDREFS ARJONES

117 PAUSE user(s)
93 non-PAUSE user(s).

Andrew Main (Zefram)

COP Hint Hashes */

typedef struct refcounted_he COPHH;

#define COPHH_KEY_UTF8 REFCOUNTED_HE_KEY_UTF8

/* =for apidoc Amx|SV *|cophh_fetch_pvn|const COPHH *cophh|const char *keypv|STRLEN keylen|U32 hash|U32 flags

Look up the entry in the cop hints hash cophh with the key specified by keypv and keylen. If flags has the COPHH_KEY_UTF8 bit set, the key octets are interpreted as UTF-8, otherwise they are interpreted as Latin-1. hash is a precomputed hash of the key string, or zero if it has not been precomputed. Returns a mortal scalar copy of the value associated with the key, or &PL_sv_placeholder if there is no value associated with the key.

Like "cophh_fetch_pvn", but takes a literal string instead of a string/length pair, and no precomputed hash.

Like "cophh_fetch_pvn", but takes a nul-terminated string instead of a string/length pair.

Like "cophh_fetch_pvn", but takes a Perl scalar instead of a string/length pair.

Generates and returns a standard Perl hash representing the full set of key/value pairs in the cop hints hash cophh. flags is currently unused and must be zero.

Make and return a complete copy of the cop hints hash cophh.

Discard the cop hints hash cophh, freeing all resources associated with it.

Generate and return a fresh cop hints hash containing no entries.

Stores a value, associated with a key, in the cop hints hash cophh, and returns the modified hash. The returned hash pointer is in general not the same as the hash pointer that was passed in. The input hash is consumed by the function, and the pointer to it must not be subsequently used. Use "cophh_copy" if you need both hashes.

The key is specified by keypv and keylen. If flags has the COPHH_KEY_UTF8 bit set, the key octets are interpreted as UTF-8, otherwise they are interpreted as Latin-1. hash is a precomputed hash of the key string, or zero if it has not been precomputed.

value is the scalar value to store for this key. value is copied by this function, which thus does not take ownership of any reference to it, and later changes to the scalar will not be reflected in the value visible in the cop hints hash. Complex types of scalar will not be stored with referential integrity, but will be coerced to strings.

Like "cophh_store_pvn", but takes a literal string instead of a string/length pair, and no precomputed hash.

Like "cophh_store_pvn", but takes a nul-terminated string instead of a string/length pair.

Like "cophh_store_pvn", but takes a Perl scalar instead of a string/length pair.

Delete a key and its associated value from the cop hints hash cophh, and returns the modified hash. The returned hash pointer is in general not the same as the hash pointer that was passed in. The input hash is consumed by the function, and the pointer to it must not be subsequently used. Use "cophh_copy" if you need both hashes.

The key is specified by keypv and keylen. If flags has the COPHH_KEY_UTF8 bit set, the key octets are interpreted as UTF-8, otherwise they are interpreted as Latin-1. hash is a precomputed hash of the key string, or zero if it has not been precomputed.

Like "cophh_delete_pvn", but takes a literal string instead of a string/length pair, and no precomputed hash.

Like "cophh_delete_pvn", but takes a nul-terminated string instead of a string/length pair.

Like "cophh_delete_pvn", but takes a Perl scalar instead of a string/length pair.

COP Hint Reading */

/* =for apidoc Am|SV *|cop_hints_fetch_pvn|const COP *cop|const char *keypv|STRLEN keylen|U32 hash|U32 flags

Look up the hint entry in the cop cop with the key specified by keypv and keylen. If flags has the COPHH_KEY_UTF8 bit set, the key octets are interpreted as UTF-8, otherwise they are interpreted as Latin-1. hash is a precomputed hash of the key string, or zero if it has not been precomputed. Returns a mortal scalar copy of the value associated with the key, or &PL_sv_placeholder if there is no value associated with the key.

Like "cop_hints_fetch_pvn", but takes a literal string instead of a string/length pair, and no precomputed hash.

Like "cop_hints_fetch_pvn", but takes a nul-terminated string instead of a string/length pair.

Like "cop_hints_fetch_pvn", but takes a Perl scalar instead of a string/length pair.

Generates and returns a standard Perl hash representing the full set of hint entries in the cop cop. flags is currently unused and must be zero.

"Gimme" Values */

/* =for apidoc AmU||G_SCALAR Used to indicate scalar context. See GIMME_V, GIMME, and perlcall.

Used to force a Perl eval wrapper around a callback. See perlcall.

Indicates that no arguments are being sent to a callback. See perlcall.

Multicall Functions




Hosting generously
sponsored by Bytemark