reader_trylock


Description:

public bool reader_trylock ()

Tries to lock this for reading.

Note:

Use reader_trylock instead

If this is already locked for writing by another thread or if another thread is already waiting to lock this for writing, immediately returns false. Otherwise locks this for reading and returns true. This lock has to be unlocked by reader_unlock.

Parameters:

this

a StaticRWLock to lock for reading

Returns:

true, if this could be locked for reading