forked from TextureGroup/Texture
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ASExperimentalFeatures.h
43 lines (37 loc) · 2.03 KB
/
ASExperimentalFeatures.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
//
// ASExperimentalFeatures.h
// Texture
//
// Copyright (c) Pinterest, Inc. All rights reserved.
// Licensed under Apache 2.0: http://www.apache.org/licenses/LICENSE-2.0
//
#import <Foundation/Foundation.h>
#import <AsyncDisplayKit/ASAvailability.h>
#import <AsyncDisplayKit/ASBaseDefines.h>
NS_ASSUME_NONNULL_BEGIN
/**
* A bit mask of features. Make sure to update configuration.json when you add entries.
*/
typedef NS_OPTIONS(NSUInteger, ASExperimentalFeatures) {
// If AS_ENABLE_TEXTNODE=0 or TextNode2 subspec is used this setting is a no op and ASTextNode2
// will be used in all cases
ASExperimentalTextNode = 1 << 0, // exp_text_node
ASExperimentalInterfaceStateCoalescing = 1 << 1, // exp_interface_state_coalesce
ASExperimentalUnfairLock = 1 << 2, // exp_unfair_lock
ASExperimentalLayerDefaults = 1 << 3, // exp_infer_layer_defaults
ASExperimentalCollectionTeardown = 1 << 4, // exp_collection_teardown
ASExperimentalFramesetterCache = 1 << 5, // exp_framesetter_cache
ASExperimentalSkipClearData = 1 << 6, // exp_skip_clear_data
ASExperimentalDidEnterPreloadSkipASMLayout = 1 << 7, // exp_did_enter_preload_skip_asm_layout
ASExperimentalDispatchApply = 1 << 8, // exp_dispatch_apply
ASExperimentalOOMBackgroundDeallocDisable = 1 << 9, // exp_oom_bg_dealloc_disable
ASExperimentalTransactionOperationRetainCycle = 1 << 10, // exp_transaction_operation_retain_cycle
ASExperimentalRemoveTextKitInitialisingLock = 1 << 11, // exp_remove_textkit_initialising_lock
ASExperimentalDrawingGlobal = 1 << 12, // exp_drawing_global
ASExperimentalFeatureAll = 0xFFFFFFFF
};
/// Convert flags -> name array.
AS_EXTERN NSArray<NSString *> *ASExperimentalFeaturesGetNames(ASExperimentalFeatures flags);
/// Convert name array -> flags.
AS_EXTERN ASExperimentalFeatures ASExperimentalFeaturesFromArray(NSArray<NSString *> *array);
NS_ASSUME_NONNULL_END