Merge pull request #142 from 0xced/typos-deprecation

Introduce deprecation for renamed public interfaces
This commit is contained in:
Andreas Linde 2015-03-19 14:53:32 +01:00
commit 0b264bd4ce
3 changed files with 23 additions and 4 deletions

View File

@ -140,7 +140,7 @@ typedef NS_ENUM(NSUInteger, BITCrashManagerUserInput) {
very slow.
It is possible to check upon startup if the app crashed before using `didCrashInLastSession` and also how much
time passed between the app launch and the crash using `timeintervalCrashInLastSessionOccurred`. This allows you
time passed between the app launch and the crash using `timeIntervalCrashInLastSessionOccurred`. This allows you
to add additional code to your app delaying the app start until the crash has been successfully send if the crash
occurred within a critical startup timeframe, e.g. after 10 seconds. The `BITCrashManagerDelegate` protocol provides
various delegates to inform the app about it's current status so you can continue the remaining app startup setup
@ -400,7 +400,7 @@ typedef NS_ENUM(NSUInteger, BITCrashManagerUserInput) {
@see didCrashInLastSession
@see BITCrashManagerDelegate
*/
@property (nonatomic, readonly) NSTimeInterval timeintervalCrashInLastSessionOccurred;
@property (nonatomic, readonly) NSTimeInterval timeIntervalCrashInLastSessionOccurred;
///-----------------------------------------------------------------------------
@ -433,4 +433,10 @@ typedef NS_ENUM(NSUInteger, BITCrashManagerUserInput) {
*/
- (void)generateTestCrash;
///-----------------------------------------------------------------------------
/// @name Deprecated
///-----------------------------------------------------------------------------
@property (nonatomic, readonly) NSTimeInterval timeintervalCrashInLastSessionOccured DEPRECATED_MSG_ATTRIBUTE("Use the properly spelled property `timeIntervalCrashInLastSessionOccurred` instead.");
@end

View File

@ -137,7 +137,7 @@ static PLCrashReporterCallbacks plCrashCallbacks = {
_crashIdenticalCurrentVersion = YES;
_didCrashInLastSession = NO;
_timeintervalCrashInLastSessionOccurred = -1;
_timeIntervalCrashInLastSessionOccurred = -1;
_didLogLowMemoryWarning = NO;
_approvedCrashReports = [[NSMutableDictionary alloc] init];
@ -797,7 +797,7 @@ static PLCrashReporterCallbacks plCrashCallbacks = {
if (report.systemInfo.timestamp && report.processInfo.processStartTime) {
appStartTime = report.processInfo.processStartTime;
appCrashTime =report.systemInfo.timestamp;
_timeintervalCrashInLastSessionOccurred = [report.systemInfo.timestamp timeIntervalSinceDate:report.processInfo.processStartTime];
_timeIntervalCrashInLastSessionOccurred = [report.systemInfo.timestamp timeIntervalSinceDate:report.processInfo.processStartTime];
}
}
@ -1521,6 +1521,10 @@ static PLCrashReporterCallbacks plCrashCallbacks = {
[self.hockeyAppClient enqeueHTTPOperation:operation];
}
- (NSTimeInterval)timeintervalCrashInLastSessionOccured {
return self.timeIntervalCrashInLastSessionOccurred;
}
@end
#endif /* HOCKEYSDK_FEATURE_CRASH_REPORTER */

View File

@ -85,4 +85,13 @@ typedef NS_ENUM(NSUInteger, BITFeedbackListViewCellBackgroundStyle) {
- (void)setAttachments:(NSArray *)attachments;
///-----------------------------------------------------------------------------
/// @name Deprecated
///-----------------------------------------------------------------------------
typedef DEPRECATED_MSG_ATTRIBUTE("Use the properly spelled enum `BITFeedbackListViewCellPresentationStyle` instead.") NS_ENUM(NSUInteger, BITFeedbackListViewCellPresentatationStyle) {
BITFeedbackListViewCellPresentatationStyleDefault DEPRECATED_MSG_ATTRIBUTE("Use the properly spelled constant `BITFeedbackListViewCellPresentationStyleDefault` instead.") = 0,
BITFeedbackListViewCellPresentatationStyleOS7 DEPRECATED_MSG_ATTRIBUTE("Use the properly spelled constant `BITFeedbackListViewCellPresentationStyleOS7` instead.") = 1
};
@end