FBReflectionUtils.h 765 B

123456789101112131415161718192021222324
  1. /**
  2. * Copyright (c) 2015-present, Facebook, Inc.
  3. * All rights reserved.
  4. *
  5. * This source code is licensed under the BSD-style license found in the
  6. * LICENSE file in the root directory of this source tree. An additional grant
  7. * of patent rights can be found in the PATENTS file in the same directory.
  8. */
  9. #import <Foundation/Foundation.h>
  10. NS_ASSUME_NONNULL_BEGIN
  11. /**
  12. * Swizzles the implemntation of originalSelector with the swizzledSelector for the given class.
  13. * Both methods must belong to this class.
  14. *
  15. * @param cls The class where to swizzle
  16. * @param originalSelector original method selector
  17. * @paramswizzledSelector swizzled method selector
  18. */
  19. void FBReplaceMethod(Class cls, SEL originalSelector, SEL swizzledSelector);
  20. NS_ASSUME_NONNULL_END