logo头像

Renbo’s Blog

NSCalendar

iOS中关于日历和日期的计算

1.获取当前时间NSCalendar *calendar = [NSCalendar currentCalendar]; NSDateComponents *components = [calendar components:NSCalendarUnitMinute | NSCalend...