Get message

Purpose: Get string produced by writing a message.

 get-message <message> to <string>

get-message will create a <string> from <message> which must have been created with new-message. <string> can then be used elsewhere, for instance sent with a remote call (see run-remote), written to a file etc.

Once get-message is called, <message> is initialized as if it was just created with new-message without the "from" clause.
Examples
 // Create a message
 new-message msg
 // Write data
 write-message msg key "key1" value "value1"
 // Get string from message
 get-message msg to str
 ...
 // Create a new message from string
 new-message new from str
 // Read data
 read-message new key k value v
 // Display  data
 pf-out "[%s] [%s]\n", k,v

The result is:
[key1] [value1]

See also
Messages
get-message  
new-message  
read-message  
SEMI  
write-message  
See all
documentation


Copyright (c) 2019-2024 Gliim LLC. All contents on this web site is "AS IS" without warranties or guarantees of any kind.