INSERT(3PVM)
π INSERT(3PVM) π
okay bestie, pull up a chair because we're talking about pvm_insert β the little function that stores data in the pvmd database π«Ά this one lives in PVM Version 3.4, and heads up: [In Version 3.4: Relaced by pvm_putinfo] π
β¨ SYNOPSIS β¨
C int cc = pvm_insert( char *name, int index, int data )
Fortran Not available
sad news for the Fortran girlies: this one is not available. no crumbs for you, sorry π
π PARAMETERS π
nameβ the class name, a null-terminated string. literally just a string, but make it a good one πindexβ the class index,>= 0or-1for first available πdataβ the data you're storing in the<name, index>entry πΈ
π¦ DESCRIPTION π¦
so the master pvmd keeps a lil database, right? it's simple, it's cute, and you can use it to store values like tids and make them accessible anywhere within a virtual machine. this is giving main character energy for building stuff like the group server, which has to advertise its task id so clients can register and send messages to register. no cap, it's that useful β¨
the database stores integer data, indexed by <name, index> pairs. the name can be any null-terminated string and the index can be any non-negative integer. database entries get grouped by name into classes, and here's the slay: index can be specified as -1 to store or retrieve the first available instance in a class π
ngl these functions are not part of the group library β they're the underlying mechanism used to implement it. so like, they're the backstage crew, the real ones holding it all together π
pvm_insert stores data at the given index. if index is -1, the data gets stored at the first available index in the named class, starting at 0. obsessed. periodt π
π ERRORS π
if it works, pvm_insert returns the index at which the data was stored β iconic, we love a success story π otherwise it returns a negative result. and these are the error conditions it can hand you:
PvmBadParamβ giving an invalid argument value. bestie, check your args πPvmDupEntryβ the requested<name, index>pair is already in use. that spot is taken, no double-booking π
π SEE ALSO π
pvm_delete(3PVM)pvm_lookup(3PVM)
mwah, that's the whole page π«Ά go forth and store your integers responsibly. this absolute banger of a manpage is from PVM Version 3.4, dated 27 June, 1994 β yes she's vintage, yes she still ate π π
π¦ where this page comes from
- debian bookworm: pvm-dev 3.4.6-5
- ubuntu jammy: pvm-dev 3.4.6-3.2
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms