void SocketImpl::setOption(int level, int option, const Poco::Timespan& value) { struct timeval tv; tv.tv_sec = (long) value.totalSeconds(); tv.tv_usec = (long) value.useconds(); setRawOption(level, option, &tv, sizeof(tv)); }
//-------------------------------------------------------------- int Timeline::M_getElapsedSeconds() { Poco::DateTime now = nowLocal(); if (now > m_dateStart){ Poco::Timespan delta = now-m_dateStart; return delta.totalSeconds(); } return 0; }