OC中定義枚舉
typedef NS_ENUM(NSInteger, RefreshType)
{
? ? EndRefresh,
? ? RefreshWithNoMoreData,
? ? EndRefreshWithError,
};
Swift中調(diào)用枚舉值進(jìn)行比較
?if type == RefreshType.endRefresh.rawValue{ ? ? ?
}
OC中定義枚舉
typedef NS_ENUM(NSInteger, RefreshType)
{
? ? EndRefresh,
? ? RefreshWithNoMoreData,
? ? EndRefreshWithError,
};
Swift中調(diào)用枚舉值進(jìn)行比較
?if type == RefreshType.endRefresh.rawValue{ ? ? ?
}