Difference between revisions of "Truxton message get priority"
Jump to navigation
Jump to search
(Created page with "Tells you the priority of this message. The greater the value, the higher the priority. Priority 100 messages will be received by ETL processes before priority 1. =Syntax= <s...") |
|||
| Line 4: | Line 4: | ||
=Syntax= | =Syntax= | ||
| − | < | + | <source lang="C"> |
uint32_t truxton_message_get_priority( uint64_t message_handle ); | uint32_t truxton_message_get_priority( uint64_t message_handle ); | ||
| − | </ | + | </source> |
=Parameters= | =Parameters= | ||
| Line 16: | Line 16: | ||
=Sample= | =Sample= | ||
| − | < | + | <source lang="C" highlight="3"> |
| − | void dump_priority(uint64_t message) | + | void dump_priority( uint64_t message ) |
{ | { | ||
uint32_t priority = truxton_message_get_priority( message ); | uint32_t priority = truxton_message_get_priority( message ); | ||
| Line 30: | Line 30: | ||
} | } | ||
} | } | ||
| − | </ | + | </source> |
Revision as of 12:29, 9 February 2021
Tells you the priority of this message. The greater the value, the higher the priority. Priority 100 messages will be received by ETL processes before priority 1.
Syntax
uint32_t truxton_message_get_priority( uint64_t message_handle );
Parameters
message_handle
The handle to a message created by the truxton_message_create call.
Return value
The priority of the message.
Sample
void dump_priority( uint64_t message )
{
uint32_t priority = truxton_message_get_priority( message );
if ( priority < 100000 )
{
printf( "Low priority.\n" );
}
else
{
printf( "Normal priority\n" );
}
}