NSProxy
NSProxy 是 Objective‑C 世界里的代理基类。在插件环境中,你一般不会直接创建它,但可能会在调试/反射/桥接场景里遇到它的基础方法。
类成员 (Class members)
Section titled “类成员 (Class members)”分配实例。
static alloc(): NSProxyReturn Value:
NSProxy: 新实例。
allocWithZone
Section titled “allocWithZone”在指定 zone 分配。
static allocWithZone(zone: any): NSProxyParameters:
| Name | Type | Description |
|---|---|---|
zone | any | 内存 zone。 |
Return Value:
NSProxy: 新实例。
类对象。
static class(): anyReturn Value:
any: 类对象。
实例成员 (Instance members)
Section titled “实例成员 (Instance members)”respondsToSelector
Section titled “respondsToSelector”是否响应某 selector。
respondsToSelector(aSelector: any): booleanParameters:
| Name | Type | Description |
|---|---|---|
aSelector | any | selector。 |
Return Value:
boolean: 是否响应。
methodSignatureForSelector
Section titled “methodSignatureForSelector”某 selector 的方法签名。
methodSignatureForSelector(sel: any): anyParameters:
| Name | Type | Description |
|---|---|---|
sel | any | selector。 |
Return Value:
any: 方法签名。
forwardInvocation
Section titled “forwardInvocation”转发调用。
forwardInvocation(invocation: any): voidParameters:
| Name | Type | Description |
|---|---|---|
invocation | any | 调用对象。 |
Return Value:
- 无。
dealloc
Section titled “dealloc”析构(通常不直接调用)。
dealloc(): voidReturn Value:
- 无。
finalize
Section titled “finalize”终结(通常不直接调用)。
finalize(): voidReturn Value:
- 无。
description
Section titled “description”对象描述。
description(): stringReturn Value:
string: 描述字符串。
debugDescription
Section titled “debugDescription”调试描述。
debugDescription(): stringReturn Value:
string: 调试描述字符串。
allowsWeakReference
Section titled “allowsWeakReference”是否允许弱引用。
allowsWeakReference(): booleanReturn Value:
boolean: 是否允许。
retainWeakReference
Section titled “retainWeakReference”保留弱引用。
retainWeakReference(): booleanReturn Value:
boolean: 是否成功保留。