mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-09-09 14:10:05 +00:00
* I didn't really understand NSProxy But I think I do now :) Previously I inherited from NSObject because I didn't think I needed anything fancy, but it turns out NSProxy is *less* fancy than NSObject and allows for overriding more methods. This change is probably purely academic in that we don't use this class to forward NSObject specific messages, but I believe this is the 'right thing'. * Update comment, thanks @maicki!
22 lines
564 B
Objective-C
22 lines
564 B
Objective-C
//
|
|
// ASWeakProxy.h
|
|
// AsyncDisplayKit
|
|
//
|
|
// Created by Garrett Moon on 4/12/16.
|
|
//
|
|
// Copyright (c) 2014-present, Facebook, Inc. All rights reserved.
|
|
// This source code is licensed under the BSD-style license found in the
|
|
// LICENSE file in the root directory of this source tree. An additional grant
|
|
// of patent rights can be found in the PATENTS file in the same directory.
|
|
//
|
|
|
|
#import <Foundation/Foundation.h>
|
|
|
|
@interface ASWeakProxy : NSProxy
|
|
|
|
@property (nonatomic, weak, readonly) id target;
|
|
|
|
+ (instancetype)weakProxyWithTarget:(id)target;
|
|
|
|
@end
|