RCTImageLoader.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435
  1. /*
  2. * Copyright (c) Facebook, Inc. and its affiliates.
  3. *
  4. * This source code is licensed under the MIT license found in the
  5. * LICENSE file in the root directory of this source tree.
  6. */
  7. #import <UIKit/UIKit.h>
  8. #import <React/RCTBridge.h>
  9. #import <React/RCTDefines.h>
  10. #import <React/RCTResizeMode.h>
  11. #import <React/RCTURLRequestHandler.h>
  12. #import <React/RCTImageDataDecoder.h>
  13. #import <React/RCTImageURLLoader.h>
  14. #import <React/RCTImageCache.h>
  15. #import <React/RCTImageLoaderProtocol.h>
  16. @interface RCTImageLoader : NSObject <RCTBridgeModule, RCTImageLoaderProtocol>
  17. - (instancetype)init;
  18. - (instancetype)initWithRedirectDelegate:(id<RCTImageRedirectProtocol>)redirectDelegate NS_DESIGNATED_INITIALIZER;
  19. - (instancetype)initWithRedirectDelegate:(id<RCTImageRedirectProtocol>)redirectDelegate
  20. loadersProvider:(NSArray<id<RCTImageURLLoader>> * (^)(void))getLoaders
  21. decodersProvider:(NSArray<id<RCTImageDataDecoder>> * (^)(void))getDecoders;
  22. @end
  23. /**
  24. * DEPRECATED!! DO NOT USE
  25. * Instead use `[_bridge moduleForClass:[RCTImageLoader class]]`
  26. */
  27. @interface RCTBridge (RCTImageLoader)
  28. @property (nonatomic, readonly) RCTImageLoader *imageLoader;
  29. @end