| 426 | //----------------------------------------------------------------------------- |
| 427 | |
| 428 | SimObject* SimSet::findObject( SimObject* object ) |
| 429 | { |
| 430 | bool found = false; |
| 431 | lock(); |
| 432 | for( SimSet::iterator iter = begin(); iter != end(); ++ iter ) |
| 433 | if( *iter == object ) |
| 434 | { |
| 435 | found = true; |
| 436 | break; |
| 437 | } |
| 438 | unlock(); |
| 439 | |
| 440 | if( found ) |
| 441 | return object; |
| 442 | |
| 443 | return NULL; |
| 444 | } |
| 445 | |
| 446 | //----------------------------------------------------------------------------- |
| 447 |