Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1250)

Unified Diff: remoting/ios/domain/client_session_details.h

Issue 2971903002: Adding error handling to the connection flow. (Closed)
Patch Set: Trying out activateConstraints. Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/ios/app/session_reconnect_view.mm ('k') | remoting/ios/domain/client_session_details.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/ios/domain/client_session_details.h
diff --git a/remoting/ios/domain/client_session_details.h b/remoting/ios/domain/client_session_details.h
index 7309892b608922cfc282e15974085d9dd3316835..ee839b85aa8b1a4cf1936f7debb4853fa4736245 100644
--- a/remoting/ios/domain/client_session_details.h
+++ b/remoting/ios/domain/client_session_details.h
@@ -22,6 +22,23 @@ typedef NS_ENUM(NSInteger, SessionState) {
SessionClosed,
};
+// Session states that map to |remoting::protocol::ConnectionToHost::Error|.
+typedef NS_ENUM(NSInteger, SessionErrorCode) {
+ SessionErrorOk = 0,
+ SessionErrorPeerIsOffline,
+ SessionErrorSessionRejected,
+ SessionErrorIncompatibleProtocol,
+ SessionErrorAuthenticationFailed,
+ SessionErrorInvalidAccount,
+ SessionErrorChannelConnectionError,
+ SessionErrorSignalingError,
+ SessionErrorSignalingTimeout,
+ SessionErrorHostOverload,
+ SessionErrorMaxSessionLength,
+ SessionErrorHostConfigurationError,
+ SessionErrorUnknownError,
+};
+
// The current state of a session and data needed for session context.
@interface ClientSessionDetails : NSObject
@@ -29,6 +46,8 @@ typedef NS_ENUM(NSInteger, SessionState) {
@property(nonatomic) HostInfo* hostInfo;
// The current state of the session.
@property(nonatomic, assign) SessionState state;
+// The error assoiciated to the current state.
+@property(nonatomic, assign) SessionErrorCode error;
@end
« no previous file with comments | « remoting/ios/app/session_reconnect_view.mm ('k') | remoting/ios/domain/client_session_details.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698