GDBDebugger.st
changeset 79 303c4edc75ad
parent 78 c24e7d8bc881
child 80 b063ee120d71
equal deleted inserted replaced
78:c24e7d8bc881 79:303c4edc75ad
    29 
    29 
    30 announcer
    30 announcer
    31     ^ connection eventAnnouncer.
    31     ^ connection eventAnnouncer.
    32 
    32 
    33     "Created: / 02-06-2014 / 23:06:20 / Jan Vrany <jan.vrany@fit.cvut.cz>"
    33     "Created: / 02-06-2014 / 23:06:20 / Jan Vrany <jan.vrany@fit.cvut.cz>"
       
    34 !
       
    35 
       
    36 consoleInput
       
    37     ^ connection consoleInput
       
    38 
       
    39     "Created: / 31-05-2017 / 23:20:29 / Jan Vrany <jan.vrany@fit.cvut.cz>"
       
    40     "Modified: / 02-06-2017 / 23:13:23 / Jan Vrany <jan.vrany@fit.cvut.cz>"
       
    41 !
       
    42 
       
    43 consoleOutput
       
    44     ^ connection consoleOutput
       
    45 
       
    46     "Created: / 31-05-2017 / 23:20:35 / Jan Vrany <jan.vrany@fit.cvut.cz>"
       
    47     "Modified: / 02-06-2017 / 23:13:31 / Jan Vrany <jan.vrany@fit.cvut.cz>"
    34 !
    48 !
    35 
    49 
    36 executable: aStringOrFilename
    50 executable: aStringOrFilename
    37     "Sets the executable to debug. 
    51     "Sets the executable to debug. 
    38      API equivalent to CLI command:
    52      API equivalent to CLI command:
   347 
   361 
   348     "Created: / 02-06-2014 / 23:38:59 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   362     "Created: / 02-06-2014 / 23:38:59 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   349     "Modified: / 20-06-2014 / 22:09:57 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   363     "Modified: / 20-06-2014 / 22:09:57 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   350 !
   364 !
   351 
   365 
   352 onCommandResultEvent:aGDBCommandResultEvent 
       
   353     aGDBCommandResultEvent result status == CommandStatusExit ifTrue:[
       
   354         connection pushEvent:GDBExitEvent new.
       
   355     ].
       
   356 
       
   357     "Created: / 07-09-2014 / 23:37:07 / Jan Vrany <jan.vrany@fit.cvut.cz>"
       
   358 !
       
   359 
       
   360 onExitEvent:aGDBExitEvent 
   366 onExitEvent:aGDBExitEvent 
   361     self release.
   367     self release.
   362 
   368 
   363     "Created: / 03-06-2014 / 00:36:00 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   369     "Created: / 03-06-2014 / 00:36:00 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   364     "Modified: / 04-06-2014 / 09:28:59 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   370     "Modified: / 04-06-2014 / 09:28:59 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   508 !
   514 !
   509 
   515 
   510 subscribe
   516 subscribe
   511     connection eventAnnouncerInternal
   517     connection eventAnnouncerInternal
   512         when: GDBCommandEvent               send: #onCommandEvent:           to: self;
   518         when: GDBCommandEvent               send: #onCommandEvent:           to: self;
   513         when: GDBCommandResultEvent         send: #onCommandResultEvent:     to: self;
       
   514         when: GDBExitEvent                  send: #onExitEvent:              to: self;
   519         when: GDBExitEvent                  send: #onExitEvent:              to: self;
   515 
   520 
   516         when: GDBThreadGroupAddedEvent      send: #onThreadGroupAddedEvent:  to: self;
   521         when: GDBThreadGroupAddedEvent      send: #onThreadGroupAddedEvent:  to: self;
   517         when: GDBThreadGroupStartedEvent    send: #onThreadGroupStartedEvent: to: self;
   522         when: GDBThreadGroupStartedEvent    send: #onThreadGroupStartedEvent: to: self;
   518         when: GDBThreadGroupExitedEvent     send: #onThreadGroupExitedEvent: to: self;
   523         when: GDBThreadGroupExitedEvent     send: #onThreadGroupExitedEvent: to: self;
   522 
   527 
   523         when: GDBRunningEvent               send: #onRunningEvent:            to: self;
   528         when: GDBRunningEvent               send: #onRunningEvent:            to: self;
   524         when: GDBStoppedEvent               send: #onStoppedEvent:            to: self.
   529         when: GDBStoppedEvent               send: #onStoppedEvent:            to: self.
   525 
   530 
   526     "Created: / 20-06-2014 / 22:07:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   531     "Created: / 20-06-2014 / 22:07:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   527     "Modified: / 07-09-2014 / 23:32:28 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   532     "Modified: / 01-06-2017 / 21:18:07 / Jan Vrany <jan.vrany@fit.cvut.cz>"
   528 !
   533 !
   529 
   534 
   530 unsubscribe
   535 unsubscribe
   531     connection eventAnnouncerInternal unsubscribe: self
   536     connection eventAnnouncerInternal unsubscribe: self
   532 
   537