Job-resend mechanism for JobServer added.

git-svn-id: https://www4.informatik.uni-erlangen.de/i4svn/danceos/trunk/devel/fail@1060 8c4709b5-6ec9-48aa-a5cd-a96041d1645a
This commit is contained in:
adrian
2012-04-12 13:12:41 +00:00
parent 9a31ce2b04
commit 4a47e9f970
3 changed files with 113 additions and 56 deletions

View File

@ -27,6 +27,20 @@ private:
#endif
return m_map.size();
}
/**
* Retrieves the first element in the map.
* @return a pointer to the first element, or \c NULL if empty
*/
Tvalue first()
{
#ifndef __puma
boost::unique_lock<boost::mutex> lock(m_mutex);
#endif
if(m_map.size() > 0)
return m_map.begin()->second;
else
return NULL;
} // Lock is automatically released here
/**
* Add data to the map, return false if already present
* @param key Map key