#include <ReleaseLockProxy.h>
Definition at line 15 of file ReleaseLockProxy.h.
◆ autorelease
Definition at line 1 of file ReleaseLockProxy.m.
127{
129 return [super autorelease];
130}
NSString * rlpObjectDescription()
◆ dealloc
Definition at line 1 of file ReleaseLockProxy.m.
71{
73 {
74 NSLog(
@"** ReleaseLockProxy (%@): deallocated while locked. This shouldn't happen, unless -dealloc is being called directly.", [
self rlpObjectDescription]);
75 }
76 else
77 {
79 }
80
81 [_object release];
82 [_name release];
83
84 [super dealloc];
85}
#define NSLog(format,...)
◆ forwardInvocation:
- (void) forwardInvocation: |
|
(NSInvocation *) | invocation |
|
|
implementation |
Definition at line 1 of file ReleaseLockProxy.m.
135 :(NSInvocation *)invocation
136{
137 [invocation invokeWithTarget:_object];
138}
◆ initWithObject:name:
- (id) initWithObject: |
|
(id<NSObject>) | object |
name: |
|
(NSString *) | name |
Definition at line 1 of file ReleaseLockProxy.m.
45 :(id<NSObject>)object name:(NSString *)name
46{
47 return [self initWithRetainedObject:[object retain] name:name];
48}
◆ initWithRetainedObject:name:
- (id) initWithRetainedObject: |
|
(id<NSObject>) | object |
name: |
|
(NSString *) | name |
Definition at line 1 of file ReleaseLockProxy.m.
51 :(id<NSObject>)object name:(NSString *)name
52{
54 {
55 NSLog(
@"** ReleaseLockProxy: passed nil object, returning nil proxy.");
56 [self release];
58 }
59
60
61
65
66 return self;
67}
◆ instancesRespondToSelector:
+ (BOOL) instancesRespondToSelector: |
|
(SEL) | selector |
|
|
implementation |
Definition at line 1 of file ReleaseLockProxy.m.
161 :(SEL)selector
162{
163 if (selector == @selector(initWithObject:name:) ||
164 selector == @selector(initWithRetainedObject:name:) ||
167 {
168 return YES;
169 }
170 else
171 {
172 return NO;
173 }
174}
◆ methodSignatureForSelector:
- (NSMethodSignature *) methodSignatureForSelector: |
|
(SEL) | selector |
|
|
implementation |
Definition at line 1 of file ReleaseLockProxy.m.
141 :(SEL)selector
142{
143 NSMethodSignature *result =
nil;
144
145 if (selector == @selector(initWithObject:name:) ||
146 selector == @selector(initWithRetainedObject:name:) ||
149 {
151 }
152 else
153 {
154 result = [(id)_object methodSignatureForSelector:selector];
155 }
156
157 return result;
158}
◆ proxyWithObject:name:
+ (id) proxyWithObject: |
|
(id<NSObject>) | object |
name: |
|
(NSString *) | name |
Definition at line 1 of file ReleaseLockProxy.m.
33 :(id<NSObject>)object name:(NSString *)name
34{
35 return [[[self alloc] initWithObject:object name:name] autorelease];
36}
◆ proxyWithRetainedObject:name:
+ (id) proxyWithRetainedObject: |
|
(id<NSObject>) | object |
name: |
|
(NSString *) | name |
Definition at line 1 of file ReleaseLockProxy.m.
39 :(id<NSObject>)object name:(NSString *)name
40{
41 return [[[self alloc] initWithRetainedObject:object name:name] autorelease];
42}
◆ release
Definition at line 1 of file ReleaseLockProxy.m.
103{
104 unsigned retainCount = [self retainCount];
105
106 if (
_locked && retainCount == 1)
107 {
108
109 NSLog(
@"** ReleaseLockProxy (%@): released while locked and retain count is one - intercepting retain. Something is broken.", [
self rlpObjectDescription]);
110 return;
111 }
112
114 {
115 VerboseLog(
@"-- ReleaseLockProxy (%@): released while locked, but retain count > 1; retain count going from %u to %u.", [
self rlpObjectDescription], retainCount, retainCount - 1);
116 }
117 else
118 {
119 VerboseLog(
@"-- ReleaseLockProxy (%@): released while not locked; retain count going from %u to %u.", [
self rlpObjectDescription], retainCount, retainCount - 1);
120 }
121
122 [super release];
123}
◆ respondsToSelector:
- (BOOL) respondsToSelector: |
|
(SEL) | selector |
|
|
implementation |
Definition at line 1 of file ReleaseLockProxy.m.
177 :(SEL)selector
178{
180}
BOOL instancesRespondToSelector:(SEL selector)
◆ rlpAllowRelease
◆ rlpObjectDescription
- (NSString *) rlpObjectDescription |
|
|
|
◆ _locked
◆ _name
◆ _object
The documentation for this class was generated from the following files: