From c7f8132db3aa4f9d69d7fa9ad59daade912387f3 Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Mon, 7 Dec 2015 01:25:41 -0500 Subject: [PATCH] Some final header nits. --- Source/DebuggerBackEnd.h | 14 +++++--------- Source/DebuggerBackEnd.m | 5 ++--- Source/DebuggerController.m | 1 + Source/DebuggerModel.h | 3 +++ 4 files changed, 11 insertions(+), 12 deletions(-) diff --git a/Source/DebuggerBackEnd.h b/Source/DebuggerBackEnd.h index cf6bfc4..eb1dc5c 100644 --- a/Source/DebuggerBackEnd.h +++ b/Source/DebuggerBackEnd.h @@ -16,25 +16,21 @@ #import -#import "Breakpoint.h" #import "ProtocolClient.h" -#import "StackFrame.h" -@protocol DebuggerBackEndDelegate; +@class Breakpoint; @class DebuggerModel; +@class StackFrame; @class VariableNode; // The DebuggerBackEnd is the communication layer between the application // and the back-end debugger. Clients issue debugger commands via this class, // which are sent in an asynchronous manner. Reads are also asynchronous and -// the primary client of this class should set itself as the delegate. The -// primary unit that this class deals with is the StackFrame; clients should -// maintain a stack structure and the BackEnd will inform the delegate when -// a new frame is created or the stack should be destroyed. +// the primary client of this class should set a model object, which will be +// updated as data arrive. @interface DebuggerBackEnd : NSObject -// Whether the debugger should detach immediately after being contacted by the -// backend. YES means all debugger connections will be dropped. +// Whether the debugger should listen for and attach to connections. @property(assign, nonatomic) BOOL autoAttach; // The model object to update in response to changes in the debugger. diff --git a/Source/DebuggerBackEnd.m b/Source/DebuggerBackEnd.m index b01fb89..eedfc83 100644 --- a/Source/DebuggerBackEnd.m +++ b/Source/DebuggerBackEnd.m @@ -17,9 +17,11 @@ #import "DebuggerBackEnd.h" #import "AppDelegate.h" +#import "Breakpoint.h" #import "DebuggerModel.h" #import "modp_b64.h" #import "NSXMLElementAdditions.h" +#import "StackFrame.h" @implementation DebuggerBackEnd { // The connection to the debugger engine. @@ -27,9 +29,6 @@ ProtocolClient* _client; } -@synthesize autoAttach = _autoAttach; -@synthesize model = _model; - - (instancetype)initWithPort:(NSUInteger)aPort autoAttach:(BOOL)doAttach { if (self = [super init]) { diff --git a/Source/DebuggerController.m b/Source/DebuggerController.m index 153ecbf..f05fd38 100644 --- a/Source/DebuggerController.m +++ b/Source/DebuggerController.m @@ -23,6 +23,7 @@ #import "DebuggerModel.h" #import "EvalController.h" #import "NSXMLElementAdditions.h" +#import "StackFrame.h" @interface DebuggerController (Private) - (void)updateSourceViewer; diff --git a/Source/DebuggerModel.h b/Source/DebuggerModel.h index 82ccb4d..f18a0de 100644 --- a/Source/DebuggerModel.h +++ b/Source/DebuggerModel.h @@ -18,6 +18,9 @@ @class StackFrame; +// This class represents the state of an active debugging session. It is +// typically updated by the DebuggerBackEnd in response to various commands. +// All of the properties are KVO-compliant. @interface DebuggerModel : NSObject // Whether or not the debugger is currently connected. -- 2.43.5