@@ -34,66 +34,67 @@ - init { self = [super init]; - if (!of_mutex_new(&mutex)) { + if (!of_mutex_new(&_mutex)) { Class c = [self class]; [self release]; @throw [OFInitializationFailedException exceptionWithClass: c]; } - initialized = YES; + _initialized = YES; return self; } - (void)lock { - if (!of_mutex_lock(&mutex)) + if (!of_mutex_lock(&_mutex)) @throw [OFLockFailedException exceptionWithClass: [self class] lock: self]; } - (BOOL)tryLock { - return of_mutex_trylock(&mutex); + return of_mutex_trylock(&_mutex); } - (void)unlock { - if (!of_mutex_unlock(&mutex)) + if (!of_mutex_unlock(&_mutex)) @throw [OFUnlockFailedException exceptionWithClass: [self class] lock: self]; } -- (void)setName: (OFString*)name_ +- (void)setName: (OFString*)name { - OF_SETTER(name, name_, YES, 1) + OF_SETTER(_name, name, YES, 1) } - (OFString*)name { - OF_GETTER(name, YES) + OF_GETTER(_name, YES) } - (OFString*)description { - if (name == nil) + if (_name == nil) return [super description]; - return [OFString stringWithFormat: @"<%@: %@>", [self className], name]; + return [OFString stringWithFormat: @"<%@: %@>", + [self className], _name]; } - (void)dealloc { - if (initialized) - if (!of_mutex_free(&mutex)) + if (_initialized) + if (!of_mutex_free(&_mutex)) @throw [OFStillLockedException exceptionWithClass: [self class] lock: self]; - [name release]; + [_name release]; [super dealloc]; } @end