12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758 |
- //
- // NSNumber+TimeStamp.h
- // jinxin
- //
- // Created by Gavin on 15/1/30.
- // Copyright (c) 2015年 jinxin. All rights reserved.
- //
- #import <Foundation/Foundation.h>
- @interface NSNumber (TimeStamp)
- /**
- * 最新要求的时间显示规则
- *
- * @param num 时间
- *
- * @return 返回要求字符串
- */
- +(NSString *)newTimeforNumber:(NSNumber *)num;
- /**
- * @brief 传入时间戳,得到处理后的时间字符串
- *
- * @param num 时间戳
- *
- * @return 想要的格式的时间
- */
- + (NSString *)timeFromNumer:(NSNumber *)num;
- + (NSString *)shortTimeFromNumer:(NSNumber *)num;
- + (NSNumber *)currentTimeStamp;
- + (NSString *)hourAndMinuteWith:(NSNumber *)num;
- //08-9 10:23
- + (NSString *)stdTimeFromNumer:(NSNumber *)num;
- //返回时间 2016年08月01日
- +(NSString *)strYMDTimeFromNumber:(NSNumber *)num;
- //2016年8月8日 1632
- +(NSString *)strTimeFromNumber:(NSNumber *)num;
- +(NSString *)strTimeFromNumber:(NSNumber *)num andDateFormat:(NSString *)dateFormat;
- /**
- 日程title的小标题
- */
- + (NSString *)scheduleManagementDetailWith:(NSNumber *)num;
- /**
- 将date类型转为时间戳NSNumber类型
- */
- + (NSNumber *)changeNumberWithDate:(NSDate *)date;
- + (NSString *)YMDFromNumer:(NSNumber *)num;
- +(NSDate *)changeDateStringWith:(NSString *)dateString;
- +(NSDate *)changeDateStringWith:(NSString *)timeString andFormatter:(NSString *)formatterString;
- +(NSDate *)changeDateHmsStringWith:(NSString *)timeString;
- + (NSNumber *)timeStampFromString:(NSString *)dateString;
- @end
|