#import <ThingLanguageLoader.h>
多语言代理的 before、after hooks 基于洋葱模型实现
Definition at line 23 of file ThingLanguageLoader.h.
◆ afterLocalizedWithKey:isFound:isCurrent:localizedString: [1/4]
- (nullable NSString *) afterLocalizedWithKey: |
|
(NSString *) |
languageKey |
isFound: |
|
(BOOL) |
isFound |
isCurrent: |
|
(BOOL) |
isCurrent |
localizedString: |
|
(NSString *) |
localizedString |
|
|
| |
|
optional |
在获取多语言后的回调方法,如果该回调返回了非nil值,则localizedString方法会返回这个值。 可以用这个方法运行时修改工程多语言,如果对翻译的内容不满意可以做替换等等
- Parameters
-
languageKey | 多语言key |
isFound | 是否找到了多语言翻译 |
isCurrent | 当isFound为True时,这个字段才有效。是否在main bundle(不是默认的语言bundle)中取到的多语言翻译。 |
localizedString | 多语言翻译的内容,如果isFound为NO,则localizedString==languageKey |
◆ afterLocalizedWithKey:isFound:isCurrent:localizedString: [2/4]
- (nullable NSString *) afterLocalizedWithKey: |
|
(NSString *) |
languageKey |
isFound: |
|
(BOOL) |
isFound |
isCurrent: |
|
(BOOL) |
isCurrent |
localizedString: |
|
(NSString *) |
localizedString |
|
|
| |
|
optional |
在获取多语言后的回调方法,如果该回调返回了非nil值,则localizedString方法会返回这个值。 可以用这个方法运行时修改工程多语言,如果对翻译的内容不满意可以做替换等等
- Parameters
-
languageKey | 多语言key |
isFound | 是否找到了多语言翻译 |
isCurrent | 当isFound为True时,这个字段才有效。是否在main bundle(不是默认的语言bundle)中取到的多语言翻译。 |
localizedString | 多语言翻译的内容,如果isFound为NO,则localizedString==languageKey |
◆ afterLocalizedWithKey:isFound:isCurrent:localizedString: [3/4]
- (nullable NSString *) afterLocalizedWithKey: |
|
(NSString *) |
languageKey |
isFound: |
|
(BOOL) |
isFound |
isCurrent: |
|
(BOOL) |
isCurrent |
localizedString: |
|
(NSString *) |
localizedString |
|
|
| |
|
optional |
在获取多语言后的回调方法,如果该回调返回了非nil值,则localizedString方法会返回这个值。 可以用这个方法运行时修改工程多语言,如果对翻译的内容不满意可以做替换等等
- Parameters
-
languageKey | 多语言key |
isFound | 是否找到了多语言翻译 |
isCurrent | 当isFound为True时,这个字段才有效。是否在main bundle(不是默认的语言bundle)中取到的多语言翻译。 |
localizedString | 多语言翻译的内容,如果isFound为NO,则localizedString==languageKey |
◆ afterLocalizedWithKey:isFound:isCurrent:localizedString: [4/4]
- (nullable NSString *) afterLocalizedWithKey: |
|
(NSString *) |
languageKey |
isFound: |
|
(BOOL) |
isFound |
isCurrent: |
|
(BOOL) |
isCurrent |
localizedString: |
|
(NSString *) |
localizedString |
|
|
| |
|
optional |
在获取多语言后的回调方法,如果该回调返回了非nil值,则localizedString方法会返回这个值。 可以用这个方法运行时修改工程多语言,如果对翻译的内容不满意可以做替换等等
- Parameters
-
languageKey | 多语言key |
isFound | 是否找到了多语言翻译 |
isCurrent | 当isFound为True时,这个字段才有效。是否在main bundle(不是默认的语言bundle)中取到的多语言翻译。 |
localizedString | 多语言翻译的内容,如果isFound为NO,则localizedString==languageKey |
◆ beforeLocalizedWithKey: [1/4]
- (nullable NSString *) beforeLocalizedWithKey: |
|
(NSString *) |
languageKey |
|
|
optional |
在获取多语言前的回调方法,如果该回调返回了非nil值,则localizedString方法会返回这个值。 可以用这个方法运行时修改工程多语言,如果走了before就不会再走下面的after方法了
- Parameters
-
◆ beforeLocalizedWithKey: [2/4]
- (nullable NSString *) beforeLocalizedWithKey: |
|
(NSString *) |
languageKey |
|
|
optional |
在获取多语言前的回调方法,如果该回调返回了非nil值,则localizedString方法会返回这个值。 可以用这个方法运行时修改工程多语言,如果走了before就不会再走下面的after方法了
- Parameters
-
◆ beforeLocalizedWithKey: [3/4]
- (nullable NSString *) beforeLocalizedWithKey: |
|
(NSString *) |
languageKey |
|
|
optional |
在获取多语言前的回调方法,如果该回调返回了非nil值,则localizedString方法会返回这个值。 可以用这个方法运行时修改工程多语言,如果走了before就不会再走下面的after方法了
- Parameters
-
◆ beforeLocalizedWithKey: [4/4]
- (nullable NSString *) beforeLocalizedWithKey: |
|
(NSString *) |
languageKey |
|
|
optional |
在获取多语言前的回调方法,如果该回调返回了非nil值,则localizedString方法会返回这个值。 可以用这个方法运行时修改工程多语言,如果走了before就不会再走下面的after方法了
- Parameters
-
The documentation for this protocol was generated from the following files:
- /Users/humtong/Downloads/Pods_副本/ThingFoundationKit/ThingFoundationKit.xcframework/ios-arm64_x86_64-simulator/ThingFoundationKit.framework/Headers/ThingLanguageLoader.h
- /Users/humtong/Downloads/Pods_副本/ThingFoundationKit/ThingFoundationKit.xcframework/watchos-arm64_i386_x86_64-simulator/ThingFoundationKit.framework/Headers/ThingLanguageLoader.h
- /Users/humtong/Downloads/Pods_副本/ThingFoundationKit/ThingFoundationKit.xcframework/ios-arm64/ThingFoundationKit.framework/Headers/ThingLanguageLoader.h
- /Users/humtong/Downloads/Pods_副本/ThingFoundationKit/ThingFoundationKit.xcframework/watchos-arm64_arm64_32_armv7k/ThingFoundationKit.framework/Headers/ThingLanguageLoader.h