cwIo.h/cpp : Added is_started_flag().

This commit is contained in:
kevin 2025-03-25 18:12:52 -04:00
parent a2b70726c0
commit 17e84c0190
2 changed files with 11 additions and 0 deletions

View File

@ -2536,6 +2536,15 @@ cw::rc_t cw::io::stop( handle_t h )
return rc;
}
bool cw::io::is_started_flag( handle_t h )
{
if( h.isValid() )
{
io_t* p = _handleToPtr(h);
return p->startedFl.load();
}
return false;
}
cw::rc_t cw::io::exec( handle_t h, unsigned timeOutMs, void* execCbArg )
{

2
cwIo.h
View File

@ -163,10 +163,12 @@ namespace cw
rc_t destroy( handle_t& h );
rc_t start( handle_t h );
rc_t pause( handle_t h );
rc_t stop( handle_t h );
bool is_started_flag( handle_t h );
// Note that this call blocks on the the UI websocket handle for up to 'timeOutMs'.
// See ui:ws:exec().