Enumerations
The following enumerations are available globally.
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWHeaderFooterViewType) { FWHeaderFooterViewTypeHeader = 0, FWHeaderFooterViewTypeFooter = 1, }
-
权限状态枚举
See moreDeclaration
Objective-C
enum FWAuthorizeStatus : NSInteger {}
-
权限类型枚举
See moreDeclaration
Objective-C
enum FWAuthorizeType : NSInteger {}
-
版本状态
See moreDeclaration
Objective-C
enum FWVersionStatus : NSInteger {}
-
日志类型定义
@const FWLogTypeError 错误类型,0…00001 @const FWLogTypeWarn 警告类型,0…00010 @const FWLogTypeInfo 信息类型,0…00100 @const FWLogTypeDebug 调试类型,0…01000 @const FWLogTypeTrace 跟踪类型,0…10000
See moreDeclaration
Objective-C
enum FWLogType : NSUInteger {}
-
日志级别定义
@const FWLogLevelOff 关闭日志,0…00000 @const FWLogLevelError 错误以上级别,0…00001 @const FWLogLevelWarn 警告以上级别,0…00011 @const FWLogLevelInfo 信息以上级别,0…00111 @const FWLogLevelDebug 调试以上级别,0…01111 @const FWLogLevelTrace 跟踪以上级别,0…11111 @const FWLogLevelAll 所有级别,1…11111
See moreDeclaration
Objective-C
enum FWLogLevel : NSUInteger {}
-
控制器导航选项定义
@const FWNavigationOptionEmbedInNavigation 嵌入导航控制器并使用present转场方式
@const FWNavigationOptionTransitionAutomatic 自动判断转场方式,默认 @const FWNavigationOptionTransitionPush 指定push转场方式,仅open生效 @const FWNavigationOptionTransitionPresent 指定present转场方式,仅open生效 @const FWNavigationOptionTransitionPop 指定pop转场方式,仅close生效 @const FWNavigationOptionTransitionDismiss 指定dismiss转场方式,仅close生效
@const FWNavigationOptionPopNone 不pop控制器,默认 @const FWNavigationOptionPopToRoot 同时pop到根控制器,仅push|pop生效 @const FWNavigationOptionPopTop 同时pop顶部控制器,仅push|pop生效 @const FWNavigationOptionPopTop2 同时pop顶部2个控制器,仅push|pop生效 @const FWNavigationOptionPopTop3 同时pop顶部3个控制器,仅push|pop生效 @const FWNavigationOptionPopTop4 同时pop顶部4个控制器,仅push|pop生效 @const FWNavigationOptionPopTop5 同时pop顶部5个控制器,仅push|pop生效 @const FWNavigationOptionPopTop6 同时pop顶部6个控制器,仅push|pop生效
@const FWNavigationOptionStyleAutomatic 自动使用系统present样式,默认 @const FWNavigationOptionStyleFullScreen 指定present样式为ullScreen,仅present生效 @const FWNavigationOptionStylePageSheet 指定present样式为pageSheet,仅present生效
See moreDeclaration
Objective-C
enum FWNavigationOptions : NSUInteger {}
-
视图控制器生命周期状态枚举
See moreDeclaration
Objective-C
enum FWViewControllerVisibleState : NSUInteger {}
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWAlertControllerStyle) { FWAlertControllerStyleActionSheet = 0, // 从单侧弹出(顶/左/底/右) FWAlertControllerStyleAlert, // 从中间弹出 }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWAlertAnimationType) { FWAlertAnimationTypeDefault = 0, // 默认动画,如果是FWAlertControllerStyleActionSheet样式,默认动画等效于FWAlertAnimationTypeFromBottom,如果是FWAlertControllerStyleAlert样式,默认动画等效于FWAlertAnimationTypeShrink FWAlertAnimationTypeFromBottom, // 从底部弹出 FWAlertAnimationTypeFromTop, // 从顶部弹出 FWAlertAnimationTypeFromRight, // 从右边弹出 FWAlertAnimationTypeFromLeft, // 从左边弹出 FWAlertAnimationTypeShrink, // 收缩动画 FWAlertAnimationTypeExpand, // 发散动画 FWAlertAnimationTypeFade, // 渐变动画 FWAlertAnimationTypeNone, // 无动画 }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWAlertActionStyle) { FWAlertActionStyleDefault = 0, // 默认样式 FWAlertActionStyleCancel, // 取消样式,字体加粗 FWAlertActionStyleDestructive // 红色字体样式 }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSUInteger, FWAssetType) { FWAssetTypeUnknow, FWAssetTypeImage, FWAssetTypeVideo, FWAssetTypeAudio }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSUInteger, FWAssetSubType) { FWAssetSubTypeUnknow, FWAssetSubTypeImage, FWAssetSubTypeLivePhoto, FWAssetSubTypeGIF }
-
Status when download asset from iCloud
See moreDeclaration
Objective-C
enum FWAssetDownloadStatus : NSUInteger {}
-
Asset 授权的状态
See moreDeclaration
Objective-C
enum FWAssetAuthorizationStatus : NSUInteger {}
-
Undocumented
See moreDeclaration
Objective-C
NS_ERROR_ENUM(FWAsyncSocketErrorDomain, FWAsyncSocketError) { FWAsyncSocketNoError = 0, // Never used FWAsyncSocketBadConfigError, // Invalid configuration FWAsyncSocketBadParamError, // Invalid parameter was passed FWAsyncSocketConnectTimeoutError, // A connect operation timed out FWAsyncSocketReadTimeoutError, // A read operation timed out FWAsyncSocketWriteTimeoutError, // A write operation timed out FWAsyncSocketReadMaxedOutError, // Reached set maxLength without completing FWAsyncSocketClosedError, // The remote peer closed the connection FWAsyncSocketOtherError, // Description provided in userInfo }
-
Undocumented
See moreDeclaration
Objective-C
NS_ERROR_ENUM(FWAsyncUdpSocketErrorDomain, FWAsyncUdpSocketError) { FWAsyncUdpSocketNoError = 0, // Never used FWAsyncUdpSocketBadConfigError, // Invalid configuration FWAsyncUdpSocketBadParamError, // Invalid parameter was passed FWAsyncUdpSocketSendTimeoutError, // A send operation timed out FWAsyncUdpSocketClosedError, // The socket was closed FWAsyncUdpSocketOtherError, // Description provided in userInfo }
-
Undocumented
See moreDeclaration
Objective-C
NS_OPTIONS(NSUInteger, FWAttributedAlignment) { FWAttributedAlignmentTop, FWAttributedAlignmentCenter, FWAttributedAlignmentBottom }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWAudioPlayerStatus) { FWAudioPlayerStatusPlaying = 0, FWAudioPlayerStatusForcePause, FWAudioPlayerStatusBuffering, FWAudioPlayerStatusUnknown, }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWAudioPlayerRepeatMode) { FWAudioPlayerRepeatModeOn = 0, FWAudioPlayerRepeatModeOnce, FWAudioPlayerRepeatModeOff, }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWAudioPlayerShuffleMode) { FWAudioPlayerShuffleModeOn = 0, FWAudioPlayerShuffleModeOff, }
-
自带提醒灯样式
See moreDeclaration
Objective-C
enum FWBadgeStyle : NSInteger {}
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWBannerViewPageControlAlignment) { FWBannerViewPageControlAlignmentRight, FWBannerViewPageControlAlignmentCenter, }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWBannerViewPageControlStyle) { // 系统样式 FWBannerViewPageControlStyleSystem, // 自定义样式,可设置图片等 FWBannerViewPageControlStyleCustom, // 不显示 FWBannerViewPageControlStyleNone, }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWBarragePositionPriority) { FWBarragePositionLow = 0, FWBarragePositionMiddle, FWBarragePositionHigh, FWBarragePositionVeryHigh }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWBarrageRenderPositionStyle) {//新加的cell的y坐标的类型 FWBarrageRenderPositionRandomTracks = 0, //将FWBarrageRenderView分成几条轨道, 随机选一条展示 FWBarrageRenderPositionRandom, // y坐标随机 FWBarrageRenderPositionIncrease, //y坐标递增, 循环 }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWBarrageRenderStatus) { FWBarrageRenderStoped = 0, FWBarrageRenderStarted, FWBarrageRenderPaused }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWRequestValidationErrorCode) { FWRequestValidationErrorInvalidStatusCode = -8, FWRequestValidationErrorInvalidJSONFormat = -9, }
-
HTTP Request method.
See moreDeclaration
Objective-C
enum FWRequestMethod : NSInteger {}
-
Request serializer type.
See moreDeclaration
Objective-C
enum FWRequestSerializerType : NSInteger {}
-
Response serializer type, which determines response serialization process and the type of
See moreresponseObject
.Declaration
Objective-C
enum FWResponseSerializerType : NSInteger {}
-
Request priority
See moreDeclaration
Objective-C
enum FWRequestPriority : NSInteger {}
-
Enumerated structure to define direction in which items can be rendered.
See moreDeclaration
Objective-C
enum FWCollectionViewWaterfallLayoutItemRenderDirection : NSUInteger {}
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWCollectionViewItemsHorizontalAlignment) { FWCollectionViewItemsHorizontalAlignmentFlow, /**< 水平流式(水平方向效果与 UICollectionViewDelegateFlowLayout 一致) */ FWCollectionViewItemsHorizontalAlignmentFlowFilled, /**< 水平流式并充满(行内各 item 均分行内剩余空间,使行内充满显示) */ FWCollectionViewItemsHorizontalAlignmentLeft, /**< 水平居左 */ FWCollectionViewItemsHorizontalAlignmentCenter, /**< 水平居中 */ FWCollectionViewItemsHorizontalAlignmentRight /**< 水平居右 */ }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWCollectionViewItemsVerticalAlignment) { FWCollectionViewItemsVerticalAlignmentCenter, /**< 竖直方向居中 */ FWCollectionViewItemsVerticalAlignmentTop, /**< 竖直方向顶部对齐 */ FWCollectionViewItemsVerticalAlignmentBottom /**< 竖直方向底部对齐 */ }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWCollectionViewItemsDirection) { FWCollectionViewItemsDirectionLTR, /**< 排布方向从左到右 */ FWCollectionViewItemsDirectionRTL /**< 排布方向从右到左 */ }
-
图片裁剪样式
See moreDeclaration
Objective-C
enum FWImageCropCroppingStyle : NSInteger {}
-
常用裁剪比率枚举
See moreDeclaration
Objective-C
enum FWImageCropAspectRatioPreset : NSInteger {}
-
工具栏位置枚举
See moreDeclaration
Objective-C
enum FWImageCropToolbarPosition : NSInteger {}
-
图片选择插件过滤类型
See moreDeclaration
Objective-C
enum FWImagePickerFilterType : NSUInteger {}
-
网络图片加载选项,默认兼容SDWebImage
See moreDeclaration
Objective-C
enum FWWebImageOptions : NSUInteger {}
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM (NSUInteger, FWImagePreviewMediaType) { FWImagePreviewMediaTypeImage, FWImagePreviewMediaTypeLivePhoto, FWImagePreviewMediaTypeVideo, FWImagePreviewMediaTypeOthers }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSUInteger, FWImagePreviewTransitioningStyle) { /// present 时整个界面渐现,dismiss 时整个界面渐隐,默认。 FWImagePreviewTransitioningStyleFade, /// present 时从某个指定的位置缩放到屏幕中央,dismiss 时缩放到指定位置,必须实现 sourceImageView 并返回一个非空的值 FWImagePreviewTransitioningStyleZoom }
-
分页横向滚动布局样式枚举
See moreDeclaration
Objective-C
enum FWCollectionViewPagingLayoutStyle : NSInteger {}
-
Type-Encoding枚举
See moreDeclaration
Objective-C
enum FWEncodingType : NSUInteger {}
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWNetworkReachabilityStatus) { FWNetworkReachabilityStatusUnknown = -1, FWNetworkReachabilityStatusNotReachable = 0, FWNetworkReachabilityStatusReachableViaWWAN = 1, FWNetworkReachabilityStatusReachableViaWiFi = 2, }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWPasscodeSecurityType) { FWPasscodeSecurityTypeSymbol, FWPasscodeSecurityTypeView, }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWPasscodeEditStatus) { FWPasscodeEditStatusIdle, FWPasscodeEditStatusBeginEdit, FWPasscodeEditStatusEndEdit, }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWPasscodeInputType) { /// 数字 FWPasscodeInputTypeNumber, /// 普通(不作任何处理) FWPasscodeInputTypeNormal, /// 自定义正则(此时需要设置customInputRegex) FWPasscodeInputTypeRegex, }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSUInteger, FWPlayerCacheAtionType) { FWPlayerCacheAtionTypeLocal = 0, FWPlayerCacheAtionTypeRemote }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWPopupMenuArrowDirection) { FWPopupMenuArrowDirectionTop = 0, //箭头朝上 FWPopupMenuArrowDirectionBottom, //箭头朝下 FWPopupMenuArrowDirectionLeft, //箭头朝左 FWPopupMenuArrowDirectionRight, //箭头朝右 FWPopupMenuArrowDirectionNone //没有箭头 }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger,FWPopupMenuAnimationStyle) { FWPopupMenuAnimationStyleScale = 0, //scale动画 Default FWPopupMenuAnimationStyleFade, //alpha 0~1 FWPopupMenuAnimationStyleNone, //没有动画 FWPopupMenuAnimationStyleCustom //自定义 }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger , FWPopupMenuType) { FWPopupMenuTypeDefault = 0, FWPopupMenuTypeDark }
-
Declaration
Objective-C
enum FWPopupMenuPriorityDirection : NSInteger {}
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSUInteger, FWQrcodeCornerLocation) { /// 默认与边框线同中心点 FWQrcodeCornerLocationDefault, /// 在边框线内部 FWQrcodeCornerLocationInside, /// 在边框线外部 FWQrcodeCornerLocationOutside }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSUInteger, FWQrcodeScanAnimationStyle) { /// 单线扫描样式 FWQrcodeScanAnimationStyleDefault, /// 网格扫描样式 FWQrcodeScanAnimationStyleGrid }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSUInteger, FWPullRefreshState) { FWPullRefreshStateIdle = 0, FWPullRefreshStateTriggered, FWPullRefreshStateLoading, FWPullRefreshStateAll = 10 }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSUInteger, FWInfiniteScrollState) { FWInfiniteScrollStateIdle = 0, FWInfiniteScrollStateTriggered, FWInfiniteScrollStateLoading, FWInfiniteScrollStateAll = 10 }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWRequestCacheErrorCode) { FWRequestCacheErrorExpired = -1, FWRequestCacheErrorVersionMismatch = -2, FWRequestCacheErrorSensitiveDataMismatch = -3, FWRequestCacheErrorAppVersionMismatch = -4, FWRequestCacheErrorInvalidCacheTime = -5, FWRequestCacheErrorInvalidMetadata = -6, FWRequestCacheErrorInvalidCacheData = -7, }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSUInteger, FWSSLPinningMode) { FWSSLPinningModeNone, FWSSLPinningModePublicKey, FWSSLPinningModeCertificate, }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWSegmentedControlSelectionStyle) { FWSegmentedControlSelectionStyleTextWidthStripe, // Indicator width will only be as big as the text width FWSegmentedControlSelectionStyleFullWidthStripe, // Indicator width will fill the whole segment FWSegmentedControlSelectionStyleBox, // A rectangle that covers the whole segment FWSegmentedControlSelectionStyleArrow, // An arrow in the middle of the segment pointing up or down depending on `FWSegmentedControlSelectionIndicatorLocation` FWSegmentedControlSelectionStyleCircle // An circle in the middle of the segment pointing up or down depending on `FWSegmentedControlSelectionIndicatorLocation` }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWSegmentedControlSelectionIndicatorLocation) { FWSegmentedControlSelectionIndicatorLocationTop, FWSegmentedControlSelectionIndicatorLocationBottom, FWSegmentedControlSelectionIndicatorLocationNone // No selection indicator }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWSegmentedControlSegmentWidthStyle) { FWSegmentedControlSegmentWidthStyleFixed, // Segment width is fixed FWSegmentedControlSegmentWidthStyleDynamic, // Segment width will only be as big as the text width (including inset) }
-
Undocumented
See moreDeclaration
Objective-C
NS_OPTIONS(NSInteger, FWSegmentedControlBorderType) { FWSegmentedControlBorderTypeNone = 0, FWSegmentedControlBorderTypeTop = (1 << 0), FWSegmentedControlBorderTypeLeft = (1 << 1), FWSegmentedControlBorderTypeBottom = (1 << 2), FWSegmentedControlBorderTypeRight = (1 << 3) }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWSegmentedControlType) { FWSegmentedControlTypeText, FWSegmentedControlTypeImages, FWSegmentedControlTypeTextImages }
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWSegmentedControlImagePosition) { FWSegmentedControlImagePositionBehindText, FWSegmentedControlImagePositionLeftOfText, FWSegmentedControlImagePositionRightOfText, FWSegmentedControlImagePositionAboveText, FWSegmentedControlImagePositionBelowText }
-
Tags scroll direction
See moreDeclaration
Objective-C
enum FWTagCollectionScrollDirection : NSInteger {}
-
Tags alignment
See moreDeclaration
Objective-C
enum FWTagCollectionAlignment : NSInteger {}
-
吐司视图类型
See moreDeclaration
Objective-C
enum FWToastViewType : NSInteger {}
-
自定义工具栏视图类型枚举
See moreDeclaration
Objective-C
enum FWToolbarViewType : NSInteger {}
-
自定义titleView布局方式,默认水平布局
See moreDeclaration
Objective-C
enum FWToolbarTitleViewStyle : NSInteger {}
-
Declaration
Objective-C
enum FWHTTPRequestQueryStringSerializationStyle : NSUInteger {}
-
转场动画类型
@const FWAnimatedTransitionTypeNone 转场未开始 @const FWAnimatedTransitionTypePush push转场 @const FWAnimatedTransitionTypePop pop转场 @const FWAnimatedTransitionTypePresent present转场 @const FWAnimatedTransitionTypeDismiss dismiss转场
See moreDeclaration
Objective-C
enum FWAnimatedTransitionType : NSInteger {}
-
Undocumented
See moreDeclaration
Objective-C
NS_ENUM(NSInteger, FWImageDownloadPrioritization) { FWImageDownloadPrioritizationFIFO, FWImageDownloadPrioritizationLIFO }
-
对原生的UITabBarItemPositioning进行扩展,通过UITabBarItemPositioning设置时,系统会自动添加insets,这使得添加背景样式的需求变得不可能实现。TabBarItemPositioning完全支持原有的item Position 类型,除此之外还支持完全fill模式。
- automatic: UITabBarItemPositioning.automatic
- fill: UITabBarItemPositioning.fill
- centered: UITabBarItemPositioning.centered
- fillExcludeSeparator: 完全fill模式,布局不覆盖tabBar顶部分割线
- fillIncludeSeparator: 完全fill模式,布局覆盖tabBar顶部分割线
Declaration
Swift
@objc(FWTabBarItemPositioning) public enum TabBarItemPositioning : Int
-
Undocumented
See moreDeclaration
Swift
@objc(FWTabBarItemContentMode) public enum TabBarItemContentMode : Int
-
Asset playback states
See moreDeclaration
Swift
@objc(FWVideoPlayerPlaybackState) public enum VideoPlayerPlaybackState : Int
-
Asset buffering states
See moreDeclaration
Swift
@objc(FWVideoPlayerBufferingState) public enum VideoPlayerBufferingState : Int
-
列表容器视图的类型
- ScrollView: UIScrollView。优势:没有其他副作用。劣势:实时的视图内存占用相对大一点,因为所有加载之后的列表视图都在视图层级里面。
- CollectionView: 使用UICollectionView。优势:因为列表被添加到cell上,实时的视图内存占用更少,适合内存要求特别高的场景。劣势:因为cell重用机制的问题,导致列表被移除屏幕外之后,会被放入缓存区,而不存在于视图层级中。如果刚好你的列表使用了下拉刷新视图,在快速切换过程中,就会导致下拉刷新回调不成功的问题。一句话概括:使用CollectionView的时候,就不要让列表使用下拉刷新加载。
Declaration
Swift
@objc(FWPagingListContainerType) public enum PagingListContainerType : Int
- ScrollView: UIScrollView。优势:没有其他副作用。劣势:实时的视图内存占用相对大一点,因为所有加载之后的列表视图都在视图层级里面。
-
SwiftUI视图状态枚举
See moreDeclaration
Swift
@available(iOS 13.0, *) public enum ViewState
-
Declaration
Swift
public enum Introspect
-
Undocumented
See moreDeclaration
Swift
public enum TargetViewSelector