Changeset 11 in libcf++ for trunk/include/cf/task.h


Ignore:
Timestamp:
06/08/15 21:27:49 (9 years ago)
Author:
cheese
Message:

#1 add new interfaces for bin and task

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/cf/task.h

    r7 r11  
    99#include "cf/exception.h"
    1010
    11 #define SYNCHRONIZED(_s)    for (cf::task::scopedLock _sl(&_s) ; _sl.synchronizer()->locked() ; _sl.synchronizer()->unlock())
     11#define SYNCHRONIZED(_s)    for (cf::task::scopedLock _sl(&_s) ; _sl.locked() ; _sl.unlock())
    1212
    1313namespace cf
     
    116116
    117117            /**
    118              * get synchronizer
    119              * @return an instance of synchronizer
    120              */
    121             ISynchronizer * synchronizer();
     118             * is locked ?
     119             * @return true; false
     120             */
     121            cf::bool_t locked() const;
     122
     123            /**
     124             * unlock
     125             */
     126            cf::void_t unlock()
     127                throw (cf::exception);
    122128        };
    123129
Note: See TracChangeset for help on using the changeset viewer.