SystemOrganization addCategory: #'OB-Tools-Debugger'! SystemOrganization addCategory: #'OB-Tools-Processes'! SystemOrganization addCategory: #'OB-Tools-Inspector'! SystemOrganization addCategory: #'OB-Tools-Transcript'! SystemOrganization addCategory: #'OB-Tools-Workspace'! SystemOrganization addCategory: #'OB-Tools-Utilities'! SystemOrganization addCategory: #'OB-Tools-Filesystem'! !ArrayedCollection methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:28'! elementInspectorNodes ^ (1 to: self size) collect: [ :each | OTArrayInspectorNode on: self index: each ]! ! OBBrowser subclass: #OTDebugger instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTDebugger class methodsFor: 'configuration' stamp: 'dkh 08/09/2007 09:24'! defaultMetaNode | process context | process := OBMetaNode named: 'process'. context := OBMetaNode named: 'context'. context addFilter: OTBreakpointFilter new. process childAt: #longStack put: context. ^ process! ! !OTDebugger class methodsFor: 'configuration' stamp: 'lr 5/7/2007 15:35'! inspectorPanel ^ OTInspectorPanel new! ! !OTDebugger class methodsFor: 'opening' stamp: 'lr 4/26/2007 09:07'! openProcess: aProcess ^ (self process: aProcess) open! ! !OTDebugger class methodsFor: 'opening' stamp: 'lr 4/26/2007 09:07'! openProcess: aProcess context: aContext ^ (self process: aProcess context: aContext) open! ! !OTDebugger class methodsFor: 'configuration' stamp: 'lr 10/7/2007 12:36'! optionalButtonPanel ^ OBFixedButtonPanel new! ! !OTDebugger class methodsFor: 'configuration' stamp: 'lr 4/25/2007 14:16'! paneCount ^ 1! ! !OTDebugger class methodsFor: 'configuration' stamp: 'lr 10/7/2007 12:58'! panels ^ super panels ", (Array with: self inspectorPanel)"! ! !OTDebugger class methodsFor: 'instance-creation' stamp: 'lr 4/26/2007 09:09'! process: aProcess ^ self process: aProcess context: nil! ! !OTDebugger class methodsFor: 'instance-creation' stamp: 'lr 10/7/2007 12:36'! process: aProcess context: aContext | processNode contextNode | aProcess isSuspended ifFalse: [ self error: 'Unable to debug a running process.' ]. processNode := OTProcessNode process: aProcess. contextNode := OTContextNode process: aProcess context: (aContext ifNil: [ aProcess suspendedContext ]). ^ self root: processNode selection: contextNode! ! !OTDebugger class methodsFor: 'configuration' stamp: 'lr 4/25/2007 14:16'! title ^ 'Debugger'! ! !OTDebugger methodsFor: 'commands' stamp: 'lr 5/19/2007 10:06'! cmdsCommands ^ OTCmdDebugger allSubclasses! ! !OTDebugger methodsFor: 'building' stamp: 'lr 4/25/2007 14:14'! defaultBackgroundColor ^ Color lightRed! ! !OTDebugger methodsFor: 'building' stamp: 'lr 4/25/2007 18:44'! initialExtent ^ 600 @ 500! ! OBBrowser subclass: #OTFileSystem instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Filesystem'! !OTFileSystem class methodsFor: 'configuration' stamp: 'lr 12/11/2007 11:08'! defaultMetaNode | directory file | directory := OBMetaNode named: 'directory'. file := OBMetaNode named: 'file'. directory childAt: #directories put: directory. directory childAt: #files put: file. ^ directory! ! !OTFileSystem class methodsFor: 'configuration' stamp: 'lr 12/11/2007 11:09'! defaultRootNode ^ OTDirectoryNode on: FileDirectory root ! ! !OTFileSystem class methodsFor: 'configuration' stamp: 'lr 12/11/2007 11:27'! title ^ 'File System'! ! !OTFileSystem methodsFor: 'as yet unclassified' stamp: 'lr 12/11/2007 11:24'! defaultBackgroundColor ^ Color lightMagenta! ! OBBrowser subclass: #OTInspector instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! OTInspector subclass: #OTDebuggerInspector instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTDebuggerInspector methodsFor: 'building' stamp: 'lr 10/7/2007 12:45'! buildOn: aBuilder | group | group := OrderedCollection with: panels first. panels allButFirst do: [ :panel | group last vResizing = #spaceFill ifTrue: [ self buildGroup: group on: aBuilder. group := OrderedCollection new ]. group add: panel ]. ^ self buildGroup: group on: aBuilder! ! !OTInspector class methodsFor: 'configuration' stamp: 'dkh 08/15/2007 16:55'! defaultMetaNode | element | element := OBMetaNode named: 'element'. element childAt: #basicNodes labeled: 'basic' put: element; childAt: #elementNodes labeled: 'elements' put: element; childAt: #protocolNodes labeled: 'prototcol' put: element. element addFilter: OTInspectorFilter new. ^ element! ! !OTInspector class methodsFor: 'configuration' stamp: 'lr 5/7/2007 15:54'! defaultRootNode ^ OTRootInspectorNode on: nil! ! !OTInspector class methodsFor: 'instance-creation' stamp: 'lr 7/15/2007 11:43'! on: anObject | browser | browser := self root: (OTRootInspectorNode on: anObject). browser jumpTo: browser root childNodes first. ^ browser! ! !OTInspector class methodsFor: 'opening' stamp: 'lr 3/3/2006 23:34'! openOn: anObject ^ (self on: anObject) open! ! !OTInspector class methodsFor: 'configuration' stamp: 'lr 5/19/2007 10:44'! optionalButtonPanel ^ nil! ! !OTInspector class methodsFor: 'configuration' stamp: 'lr 3/4/2006 17:33'! paneCount ^ 2! ! !OTInspector class methodsFor: 'configuration' stamp: 'lr 3/3/2006 23:32'! title ^ 'Inspector'! ! !OTInspector methodsFor: 'commands' stamp: 'lr 5/19/2007 10:07'! cmdBrowse ^ OTCmdBrowse! ! !OTInspector methodsFor: 'commands' stamp: 'lr 5/19/2007 10:07'! cmdHierarchy ^ OTCmdHierarchy! ! !OTInspector methodsFor: 'commands' stamp: 'lr 5/19/2007 10:09'! cmdInspect ^ OTCmdInspectObject! ! !OTInspector methodsFor: 'commands' stamp: 'lr 5/19/2007 10:09'! cmdInspectReferences ^ OTCmdInspectReferences! ! !OTInspector methodsFor: 'morphic' stamp: 'lr 3/4/2006 17:33'! initialExtent ^ 350 @ 350! ! OBBrowser subclass: #OTProcessBrowser instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Processes'! !OTProcessBrowser class methodsFor: 'configuration' stamp: 'lr 8/3/2007 20:09'! defaultMetaNode | scheduler process context | scheduler := OBMetaNode named: 'scheduler'. process := OBMetaNode named: 'process'. context := OBMetaNode named: 'context'. context addFilter: OTBreakpointFilter new. scheduler childAt: #processes put: process. process childAt: #shortStack put: context. ^ scheduler! ! !OTProcessBrowser class methodsFor: 'configuration' stamp: 'lr 8/3/2007 19:24'! defaultRootNode ^ OTSchedulerNode new! ! !OTProcessBrowser class methodsFor: 'configuration' stamp: 'lr 8/3/2007 15:56'! optionalButtonPanel ^ nil! ! !OTProcessBrowser class methodsFor: 'configuration' stamp: 'lr 8/3/2007 15:00'! paneCount ^ 2! ! !OTProcessBrowser class methodsFor: 'configuration' stamp: 'lr 8/3/2007 15:01'! title ^ 'Process Browser'! ! !OTProcessBrowser methodsFor: 'commands' stamp: 'lr 8/3/2007 15:04'! cmdsCommands ^ OTCmdProcessBrowser allSubclasses! ! !OTProcessBrowser methodsFor: 'commands' stamp: 'lr 8/3/2007 19:49'! cmdsContextBrowsers ^ OTCmdBrowse withAllSubclasses! ! !OTProcessBrowser methodsFor: 'commands' stamp: 'lr 8/3/2007 19:45'! cmdsContextInspectors ^ OTCmdInspect withAllSubclasses! ! !OTProcessBrowser methodsFor: 'morphic' stamp: 'lr 10/7/2007 12:20'! step self announce: (OBChildrenChanged node: self root)! ! !OTProcessBrowser methodsFor: 'morphic' stamp: 'lr 10/7/2007 12:18'! wantsSteps ^ true! ! OBBrowser subclass: #OTTranscript instanceVariableNames: 'navigationPanel' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Transcript'! !OTTranscript class methodsFor: 'configuration' stamp: 'lr 11/21/2007 13:33'! defaultMetaNode ^ OBMetaNode named: 'transcript'! ! !OTTranscript class methodsFor: 'configuration' stamp: 'lr 11/21/2007 13:44'! defaultRootNode ^ OTTranscriptNode on: Transcript! ! !OTTranscript class methodsFor: 'instance creation' stamp: 'lr 11/21/2007 13:43'! metaNode: metaNode node: rootNode ^ self metaNode: metaNode root: rootNode selection: rootNode panels: self panels! ! !OTTranscript class methodsFor: 'configuration' stamp: 'lr 11/21/2007 13:32'! panels ^ Array with: self definitionPanel! ! !OTTranscript class methodsFor: 'configuration' stamp: 'lr 11/21/2007 13:42'! titleForRoot: aNode ^ aNode title! ! !OTTranscript methodsFor: 'building' stamp: 'lr 11/21/2007 13:31'! defaultBackgroundColor ^ Color lightOrange! ! !OTTranscript methodsFor: 'accessing' stamp: 'lr 11/21/2007 13:40'! navigationPanel "We don't want a navigation panel, unfrotunately many parts of OB still require one accessible." ^ navigationPanel ifNil: [ navigationPanel := self class navigationPanel browser: self ]! ! OBBrowser subclass: #OTWorkspace instanceVariableNames: 'navigationPanel' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Workspace'! !OTWorkspace class methodsFor: 'configuration' stamp: 'lr 12/11/2007 10:24'! defaultMetaNode | root workspace | root := OBMetaNode named: 'root'. workspace := OBMetaNode named: 'workspace'. root childAt: #children put: workspace. ^ root! ! !OTWorkspace class methodsFor: 'configuration' stamp: 'lr 12/11/2007 10:43'! defaultRootNode ^ OBCollectionNode on: (Array with: OTWorkspaceNode new)! ! !OTWorkspace class methodsFor: 'instance-creation' stamp: 'lr 12/11/2007 11:04'! new | root | ^ self metaNode: self defaultMetaNode root: (root := self defaultRootNode) selection: root children first panels: self panels! ! !OTWorkspace class methodsFor: 'configuration' stamp: 'lr 11/27/2007 18:12'! optionalButtonPanel ^ nil! ! !OTWorkspace class methodsFor: 'configuration' stamp: 'lr 12/11/2007 10:14'! title ^ 'Workspace'! ! !OTWorkspace class methodsFor: 'configuration' stamp: 'lr 12/11/2007 10:51'! titleForRoot: aNode ^ 'Workspace'! ! !OTWorkspace methodsFor: 'accessing' stamp: 'lr 12/11/2007 10:31'! addPanel: aPanel "aPanel isNavigation ifFalse: [ ^ super addPanel: aPanel ]. navigationPanel := aPanel. navigationPanel browser: self" aPanel isNavigation ifTrue: [ navigationPanel := aPanel ]. ^ super addPanel: aPanel! ! !OTWorkspace methodsFor: 'accessing' stamp: 'lr 11/30/2007 09:44'! navigationPanel ^ navigationPanel! ! !CompiledMethod methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:34'! derivedInspectorNodes ^ super derivedInspectorNodes allButLast add: (OTDerivedInspectorNode on: self label: 'header' block: [ :obj | obj headerDescription ]); add: (OTDerivedInspectorNode on: self label: 'bytecode' block: [ :obj | obj symbolic ]); add: (OTDerivedInspectorNode on: self label: 'decompiled' block: [ :obj | obj decompileString ]); add: (OTDerivedInspectorNode on: self label: 'source' block: [ :obj | obj getSource ]); yourself! ! !CompiledMethod methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:45'! elementInspectorNodes ^ #()! ! StandardToolSet subclass: #OTToolset instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Utilities'! !OTToolset class methodsFor: 'inspecting' stamp: 'lr 4/26/2007 16:32'! basicInspect: anObject self inspect: anObject! ! !OTToolset class methodsFor: 'debugging' stamp: 'lr 5/23/2007 23:25'! debug: aProcess context: aContext label: aString contents: aContentString fullView: aBool Project spawnNewProcessIfThisIsUI: aProcess. WorldState addDeferredUIMessage: [ aProcess suspend; suspendedContext: aContext. OTDebugger openProcess: aProcess context: aContext ]. aProcess suspend! ! !OTToolset class methodsFor: 'initialization' stamp: 'lr 4/26/2007 15:57'! initialize ToolSet register: self! ! !OTToolset class methodsFor: 'inspecting' stamp: 'lr 4/26/2007 16:32'! inspect: anObject OTInspector openOn: anObject! ! !OTToolset class methodsFor: 'inspecting' stamp: 'lr 4/26/2007 16:32'! inspect: anObject label: aString self inspect: anObject! ! OBPanel subclass: #OTInspectorPanel instanceVariableNames: 'receiverInspector contextInspector' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTInspectorPanel methodsFor: 'building' stamp: 'lr 10/7/2007 12:50'! buildOn: aBuilder ^ aBuilder verticalGroup: #() with: [ contextInspector buildOn: aBuilder. receiverInspector buildOn: aBuilder ]! ! !OTInspectorPanel methodsFor: 'accessing' stamp: 'lr 10/7/2007 12:32'! contextInspector ^ contextInspector ! ! !OTInspectorPanel methodsFor: 'accessing' stamp: 'lr 10/7/2007 12:32'! receiverInspector ^ receiverInspector ! ! !OTInspectorPanel methodsFor: 'events' stamp: 'dkh 08/15/2007 16:49'! selectionChanged: ann | cont rec ciRoot recRoot | (ann node isKindOf: OTContextNode) ifFalse: [ ^ self ]. contextInspector navigationPanel columns first basicParent: ((ciRoot := OTRootInspectorNode on: (cont := ann node doItContext)) metaNode: contextInspector class defaultMetaNode); clear; signalSelectionChanged. receiverInspector navigationPanel columns first basicParent: ((recRoot := OTRootInspectorNode on: (rec := ann node doItReceiver)) metaNode: receiverInspector class defaultMetaNode); clear; signalSelectionChanged. contextInspector announce: OBRefreshRequired. receiverInspector announce: OBRefreshRequired.! ! !OTInspectorPanel methodsFor: 'updating' stamp: 'lr 10/7/2007 12:48'! subscribe contextInspector := OTDebuggerInspector new. receiverInspector := OTDebuggerInspector new. self announcer observe: OBSelectionChanged send: #selectionChanged: to: self! ! !Object methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:34'! basicInspectorNodes ^ Array streamContents: [ :stream | stream nextPutAll: self derivedInspectorNodes. self class allInstVarNames withIndexDo: [ :name :index | stream nextPut: (OTNamedVariableNode on: self index: index name: name) ]. 1 to: self basicSize do: [ :index | stream nextPut: (OTIndexedVariableNode on: self index: index) ] ]! ! !Object methodsFor: '*ob-tools-inspector' stamp: 'dkh 08/13/2007 16:36'! derivedInspectorNodes ^ OrderedCollection with: (OTDerivedInspectorNode on: self label: 'self' block: [ :obj | obj ]) with: (OTDerivedInspectorNode on: self label: 'oop' block: [ :obj | obj asOop ])! ! !Object methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:30'! elementInspectorNodes ^ #()! ! !Object methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:23'! protocolInspectorNodes ^ self class allSelectors asArray sort collect: [ :each | OTProtocolInspectorNode on: self selector: each ]! ! OBModalFilter subclass: #OTInspectorFilter instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! !OTInspectorFilter methodsFor: 'callbacks' stamp: 'lr 11/16/2007 17:49'! listForNode: aNode aNode ifNil: [ ^ #() ]. aNode parent ifNil: [ ^ #() ]. ^ metaNode edges "select: [ :each | (each nodesForParent: aNode parent) notEmpty ] thenCollect:" collect: [ :each | each label ]! ! !Dictionary methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:32'! elementInspectorNodes ^ Array streamContents: [ :stream | self keysDo: [ :each | stream nextPut: (OTDictionaryInspectorNode on: self key: each) ] ]! ! !Fraction methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:34'! derivedInspectorNodes ^ super derivedInspectorNodes add: (OTDerivedInspectorNode on: self label: 'float' block: [ :obj | obj asFloat ]); yourself! ! !Bag methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:28'! elementInspectorNodes ^ contents elementInspectorNodes! ! OBFilter subclass: #OTBreakpointFilter instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTBreakpointFilter methodsFor: 'filtering' stamp: 'lr 10/7/2007 11:44'! icon: aSymbol forNode: aNode | class method | class := aNode theClass ifNil: [ ^ nil ]. method := class compiledMethodAt: aNode selector ifAbsent: [ ^ nil ]. method literals do: [ :literal | (literal == #halt or: [ literal == #haltIfNil or: [ literal == #haltIf: or: [ literal == #haltOnce ] ] ]) ifTrue: [ ^ #breakpoint ] ]. ^ nil! ! !Set methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:33'! elementInspectorNodes ^ Array streamContents: [ :stream | self do: [ :each | stream nextPut: (OTSetInspectorNode on: self value: each) ] ]! ! !Integer methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:34'! derivedInspectorNodes ^ super derivedInspectorNodes add: (OTDerivedInspectorNode on: self label: 'hex' block: [ :obj | obj printStringRadix: 16 ]); add: (OTDerivedInspectorNode on: self label: 'oct' block: [ :obj | obj printStringRadix: 8 ]); add: (OTDerivedInspectorNode on: self label: 'bin' block: [ :obj | obj printStringRadix: 2 ]); yourself! ! OBNode subclass: #OTDirectoryNode instanceVariableNames: 'directory' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Filesystem'! !OTDirectoryNode class methodsFor: 'as yet unclassified' stamp: 'lr 12/11/2007 11:09'! on: aDirectory ^ self new initializeOn: aDirectory! ! !OTDirectoryNode methodsFor: 'navigation' stamp: 'lr 12/11/2007 11:12'! directories ^ self directory directoryNames collect: [ :each | OTDirectoryNode on: (self directory directoryNamed: each) ]! ! !OTDirectoryNode methodsFor: 'accessing' stamp: 'lr 12/11/2007 11:09'! directory ^ directory! ! !OTDirectoryNode methodsFor: 'navigation' stamp: 'lr 12/11/2007 11:12'! files ^ self directory fileNames collect: [ :each | OTFileNode on: self directory named: each ]! ! !OTDirectoryNode methodsFor: 'initialization' stamp: 'lr 12/11/2007 11:09'! initializeOn: aDirectory directory := aDirectory! ! !OTDirectoryNode methodsFor: 'accessing' stamp: 'lr 12/11/2007 11:15'! name ^ self directory localName! ! OBNode subclass: #OTFileNode instanceVariableNames: 'directory name' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Filesystem'! !OTFileNode class methodsFor: 'as yet unclassified' stamp: 'lr 12/11/2007 11:15'! on: aDirectory named: aString ^ self new initializeOn: aDirectory named: aString! ! !OTFileNode methodsFor: 'accessing' stamp: 'lr 12/11/2007 11:13'! directory ^ directory! ! !OTFileNode methodsFor: 'initialization' stamp: 'lr 12/11/2007 11:12'! initializeOn: aDirectory named: aString directory := aDirectory. name := aString! ! !OTFileNode methodsFor: 'accessing' stamp: 'lr 12/11/2007 11:13'! name ^ name! ! !OTFileNode methodsFor: 'accessing' stamp: 'lr 12/11/2007 11:49'! text | stream contents | stream := self directory readOnlyFileNamed: self name. [ contents := stream next: 10000 ] ensure: [ stream close ]. contents size = 10000 ifTrue: [ contents := contents , '...' ]. ^ contents! ! OBNode subclass: #OTInspectorNode instanceVariableNames: 'object parent' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! OTInspectorNode subclass: #OTDerivedInspectorNode instanceVariableNames: 'label block' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! !OTDerivedInspectorNode class methodsFor: 'instance-creation' stamp: 'lr 5/19/2007 10:15'! on: anObject label: aString block: aBlock ^ (self on: anObject) setLabel: aString block: aBlock! ! !OTDerivedInspectorNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:45'! = aNode ^ super = aNode and: [ self label = aNode label ]! ! !OTDerivedInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:35'! block ^ block! ! !OTDerivedInspectorNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:48'! hash ^ super hash bitXor: self label hash! ! !OTDerivedInspectorNode methodsFor: 'testing' stamp: 'lr 5/23/2007 23:03'! isLastNode ^ true! ! !OTDerivedInspectorNode methodsFor: 'testing' stamp: 'lr 5/19/2007 10:15'! isReadOnly ^ true! ! !OTDerivedInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:36'! label ^ label! ! !OTDerivedInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:36'! name ^ '(' , self label , ')'! ! !OTDerivedInspectorNode methodsFor: 'initialization' stamp: 'lr 5/19/2007 10:15'! setLabel: aString block: aBlock label := aString. block := aBlock! ! !OTDerivedInspectorNode methodsFor: 'accessing' stamp: 'lr 5/7/2007 16:05'! value ^ self block value: self object! ! OTInspectorNode subclass: #OTDictionaryInspectorNode instanceVariableNames: 'key' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! !OTDictionaryInspectorNode class methodsFor: 'instance-creation' stamp: 'lr 5/19/2007 11:02'! on: anObject key: aKey ^ (self on: anObject) setKey: aKey! ! !OTDictionaryInspectorNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:45'! = aNode ^ super = aNode and: [ self key = aNode key ]! ! !OTDictionaryInspectorNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:48'! hash ^ super hash bitXor: self key hash! ! !OTDictionaryInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:01'! key ^ key! ! !OTDictionaryInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:36'! name ^ self key! ! !OTDictionaryInspectorNode methodsFor: 'initialization' stamp: 'lr 5/19/2007 11:02'! setKey: anObject key := anObject! ! !OTDictionaryInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:02'! value ^ self object at: self key! ! !OTDictionaryInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:02'! value: anObject self object at: self key put: anObject! ! OTInspectorNode subclass: #OTIndexedVariableNode instanceVariableNames: 'index' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! !OTIndexedVariableNode class methodsFor: 'instance-creation' stamp: 'lr 8/3/2007 20:44'! on: anObject index: anInteger ^ (self on: anObject) setIndex: anInteger! ! !OTIndexedVariableNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:46'! = aNode ^ super = aNode and: [ self index = aNode index ]! ! !OTIndexedVariableNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:48'! hash ^ super hash bitXor: self index hash! ! !OTIndexedVariableNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 10:20'! index ^ index! ! !OTIndexedVariableNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:36'! name ^ self index printString! ! !OTIndexedVariableNode methodsFor: 'initialization' stamp: 'lr 5/19/2007 10:18'! setIndex: anInteger index := anInteger! ! !OTIndexedVariableNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 10:19'! value ^ self object basicAt: self index! ! !OTIndexedVariableNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 10:20'! value: anObject self object basicAt: self index put: anObject! ! !OTInspectorNode class methodsFor: 'instance-creation' stamp: 'lr 7/15/2007 11:34'! on: anObject ^ self basicNew initializeOn: anObject! ! !OTInspectorNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:44'! = aNode ^ self species = aNode species and: [ self object == aNode object ]! ! !OTInspectorNode methodsFor: 'drag and drop' stamp: 'lr 5/19/2007 11:41'! asDraggableMorph ^ super asDraggableMorph contents: self label; yourself! ! !OTInspectorNode methodsFor: 'navigation' stamp: 'lr 5/23/2007 23:04'! basicNodes ^ self childrenAt: #basicInspectorNodes! ! !OTInspectorNode methodsFor: 'private' stamp: 'lr 7/15/2007 11:35'! childrenAt: aSelector self isLastNode ifTrue: [ ^ #() ]. ^ (self value perform: aSelector) do: [ :each | each setParent: self ]! ! !OTInspectorNode methodsFor: 'drag and drop' stamp: 'lr 5/7/2007 15:47'! dropOnInspectorNode: aNode aNode value: self value! ! !OTInspectorNode methodsFor: 'drag and drop' stamp: 'lr 3/4/2006 17:36'! dropSelector ^ #dropOnInspectorNode:! ! !OTInspectorNode methodsFor: 'navigation' stamp: 'lr 7/14/2007 20:31'! elementNodes ^ self childrenAt: #elementInspectorNodes! ! !OTInspectorNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:45'! hash ^ self species bitXor: self object hash! ! !OTInspectorNode methodsFor: 'initialization' stamp: 'lr 7/15/2007 11:34'! initializeOn: anObject object := anObject! ! !OTInspectorNode methodsFor: 'testing' stamp: 'lr 5/23/2007 23:03'! isLastNode ^ false! ! !OTInspectorNode methodsFor: 'testing' stamp: 'lr 5/7/2007 15:48'! isReadOnly ^ false! ! !OTInspectorNode methodsFor: 'displaying' stamp: 'lr 5/7/2007 16:00'! label ^ self value defaultLabelForInspector! ! !OTInspectorNode methodsFor: 'displaying' stamp: 'lr 5/7/2007 15:49'! name ^ self value name! ! !OTInspectorNode methodsFor: 'accessing' stamp: 'lr 5/7/2007 15:45'! object ^ object! ! !OTInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 08:54'! object: anObject object := anObject! ! !OTInspectorNode methodsFor: 'displaying' stamp: 'lr 7/14/2007 20:44'! parent ^ parent! ! !OTInspectorNode methodsFor: 'printing' stamp: 'lr 7/15/2007 11:29'! printOn: aStream super printOn: aStream. aStream nextPutAll: ' value: '; print: self value! ! !OTInspectorNode methodsFor: 'navigation' stamp: 'lr 5/23/2007 23:04'! protocolNodes ^ self childrenAt: #protocolInspectorNodes! ! !OTInspectorNode methodsFor: 'compatibility' stamp: 'lr 4/26/2007 16:41'! selector ^ nil! ! !OTInspectorNode methodsFor: 'initialization' stamp: 'lr 7/15/2007 11:35'! setParent: aNode parent := aNode! ! !OTInspectorNode methodsFor: 'public' stamp: 'lr 3/21/2006 00:36'! text ^ self value asString! ! !OTInspectorNode methodsFor: 'public' stamp: 'lr 7/14/2007 20:33'! text: aString self isReadOnly ifTrue: [ ^ false ]. self value: (self object class evaluatorClass evaluate: aString for: self object logged: false). ^ true! ! !OTInspectorNode methodsFor: 'compatibility' stamp: 'lr 4/26/2007 16:41'! theClass ^ self value class! ! !OTInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 10:14'! value ^ nil! ! !OTInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 10:14'! value: anObject! ! !OTInspectorNode methodsFor: 'drag and drop' stamp: 'lr 5/7/2007 15:47'! wantsDroppedNode: aNode ^ (super wantsDroppedNode: aNode) and: [ self isReadOnly not ]! ! OTInspectorNode subclass: #OTNamedVariableNode instanceVariableNames: 'index name' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! !OTNamedVariableNode class methodsFor: 'instance-creation' stamp: 'lr 8/3/2007 20:44'! on: anObject index: anInteger name: aString ^ (self on: anObject) setIndex: anInteger name: aString! ! !OTNamedVariableNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:46'! = aNode ^ super = aNode and: [ self index = aNode index ]! ! !OTNamedVariableNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:48'! hash ^ super hash bitXor: self index hash! ! !OTNamedVariableNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 10:21'! index ^ index! ! !OTNamedVariableNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 10:21'! name ^ name! ! !OTNamedVariableNode methodsFor: 'initialization' stamp: 'lr 5/19/2007 10:19'! setIndex: anInteger name: aString index := anInteger. name := aString! ! !OTNamedVariableNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 10:20'! value ^ self object instVarAt: self index! ! !OTNamedVariableNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 10:20'! value: anObject self object instVarAt: self index put: anObject! ! OTInspectorNode subclass: #OTProtocolInspectorNode instanceVariableNames: 'selector' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! !OTProtocolInspectorNode class methodsFor: 'instance-creation' stamp: 'lr 5/19/2007 10:37'! on: anObject selector: aSelector ^ (self on: anObject) setSelector: aSelector! ! !OTProtocolInspectorNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:46'! = aNode ^ super = aNode and: [ self selector = aNode selector ]! ! !OTProtocolInspectorNode methodsFor: 'drag and drop' stamp: 'lr 5/19/2007 11:50'! acceptDroppedNode: aNode (self value perform: self selector withArguments: (Array with: aNode value)) inspect! ! !OTProtocolInspectorNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:48'! hash ^ super hash bitXor: self selector hash! ! !OTProtocolInspectorNode methodsFor: 'testing' stamp: 'lr 5/23/2007 23:03'! isLastNode ^ true! ! !OTProtocolInspectorNode methodsFor: 'testing' stamp: 'lr 5/19/2007 10:38'! isReadOnly ^ true! ! !OTProtocolInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:36'! name ^ '#' , self selector! ! !OTProtocolInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 10:38'! selector ^ selector! ! !OTProtocolInspectorNode methodsFor: 'initialization' stamp: 'lr 5/19/2007 10:38'! setSelector: aSelector selector := aSelector! ! !OTProtocolInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:49'! text | class | class := self theClass whichClassIncludesSelector: self selector. ^ class sourceCodeAt: self selector! ! !OTProtocolInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:49'! value ^ self object! ! !OTProtocolInspectorNode methodsFor: 'drag and drop' stamp: 'lr 5/19/2007 11:18'! wantsDroppedNode: aNode ^ self selector numArgs = 1! ! OTInspectorNode subclass: #OTRootInspectorNode instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! !OTRootInspectorNode methodsFor: 'testing' stamp: 'lr 5/7/2007 15:52'! isReadOnly ^ true! ! !OTRootInspectorNode methodsFor: 'accessing' stamp: 'lr 5/7/2007 15:53'! value ^ self object! ! OTInspectorNode subclass: #OTSequenceInspectorNode instanceVariableNames: 'index' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! OTSequenceInspectorNode subclass: #OTArrayInspectorNode instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! !OTSequenceInspectorNode class methodsFor: 'instance-creation' stamp: 'lr 8/3/2007 20:44'! on: anObject index: anInteger ^ (self on: anObject) setIndex: anInteger! ! !OTSequenceInspectorNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:47'! = aNode ^ super = aNode and: [ self index = aNode index ]! ! !OTSequenceInspectorNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:47'! hash ^ super hash bitXor: self index hash! ! !OTSequenceInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:03'! index ^ index! ! !OTSequenceInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:36'! name ^ self index printString! ! !OTSequenceInspectorNode methodsFor: 'initialization' stamp: 'lr 5/19/2007 11:03'! setIndex: anInteger index := anInteger! ! !OTSequenceInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:03'! value ^ self object at: self index! ! !OTSequenceInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:03'! value: anObject self object at: self index put: anObject! ! OTInspectorNode subclass: #OTSetInspectorNode instanceVariableNames: 'value' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! !OTSetInspectorNode class methodsFor: 'instance-creation' stamp: 'lr 5/19/2007 11:06'! on: anObject value: aValue ^ (self on: anObject) setValue: aValue! ! !OTSetInspectorNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:47'! = aNode ^ super = aNode and: [ self value == aNode value ]! ! !OTSetInspectorNode methodsFor: 'comparing' stamp: 'lr 7/15/2007 11:47'! hash ^ super hash bitXor: self value hash! ! !OTSetInspectorNode methodsFor: 'initialization' stamp: 'lr 5/19/2007 11:06'! setValue: anObject value := anObject! ! !OTSetInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:04'! value ^ value! ! !OTSetInspectorNode methodsFor: 'accessing' stamp: 'lr 5/19/2007 11:05'! value: anObject self object remove: anObject ifAbsent: []; add: anObject! ! OBNode subclass: #OTProcessNode instanceVariableNames: 'process' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! OTProcessNode subclass: #OTContextNode instanceVariableNames: 'context parseTree sourceMap selectionInterval' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTContextNode class methodsFor: 'instance-creation' stamp: 'lr 8/3/2007 19:21'! process: aProcess context: aContext ^ (self process: aProcess) setContext: aContext! ! !OTContextNode methodsFor: 'comparing' stamp: 'lr 10/7/2007 11:49'! = anObject ^ super = anObject and: [ self context = anObject context ]! ! !OTContextNode methodsFor: 'accessing' stamp: 'lr 4/25/2007 19:48'! context ^ context! ! !OTContextNode methodsFor: 'callbacks' stamp: 'lr 4/26/2007 15:07'! doItContext ^ self context! ! !OTContextNode methodsFor: 'callbacks' stamp: 'lr 4/26/2007 15:07'! doItReceiver ^ self context receiver! ! !OTContextNode methodsFor: 'accessing-dynamic' stamp: 'lr 4/26/2007 15:04'! homeContext ^ self context finalBlockHome! ! !OTContextNode methodsFor: 'accessing' stamp: 'lr 4/26/2007 09:22'! name ^ self context asString! ! !OTContextNode methodsFor: 'accessing-dynamic' stamp: 'lr 4/26/2007 14:50'! parseTree "Answer the parse tree representing the source code of the current context." ^ parseTree ifNil: [ parseTree := self context methodNode ]! ! !OTContextNode methodsFor: 'accessing-dynamic' stamp: 'lr 10/7/2007 12:24'! selectionInterval "Answer the interval of the current source code." | index stop | selectionInterval ifNotNil: [ ^ selectionInterval ]. index := self sourceMap indexForInserting: (Association key: (self context previousPc ifNil: [ 0 ]) value: nil). index < 1 ifTrue: [ ^ selectionInterval := 1 to: 0 ]. index > self sourceMap size ifTrue: [ stop := self sourceMap inject: 0 into: [ :prev :this | prev max: this value last ]. ^ selectionInterval := stop + 1 to: stop ]. ^ selectionInterval := (self sourceMap at: index) value! ! !OTContextNode methodsFor: 'initialization' stamp: 'lr 8/3/2007 19:29'! setContext: aContext context := aContext! ! !OTContextNode methodsFor: 'accessing-dynamic' stamp: 'lr 4/26/2007 14:52'! sourceMap "Answer a mapping from byte codes to source code ranges." ^ sourceMap ifNil: [ sourceMap := self parseTree sourceMap ]! ! !OTContextNode methodsFor: 'definition' stamp: 'lr 4/26/2007 15:14'! text | contents | contents := self parseTree sourceText asText. self parseTree isDoIt ifFalse: [ contents := contents makeSelectorBold ]. ^ contents! ! !OTContextNode methodsFor: 'definition' stamp: 'lr 8/3/2007 20:44'! text: aString | class | self process isSuspended ifFalse: [ ^ false ]. class := self homeContext receiver class whichClassIncludesSelector: self homeContext selector. (class compile: aString) ifNil: [ ^ false ]. self process popTo: self homeContext; restartTopWith: (class compiledMethodAt: self homeContext selector); stepToSendOrReturn. OBAnnouncer current announce: OBRefreshRequired. ^ true! ! !OTContextNode methodsFor: 'definition' stamp: 'lr 4/26/2007 15:07'! textSelection ^ self selectionInterval! ! !OTProcessNode class methodsFor: 'instance-creation' stamp: 'lr 8/3/2007 19:20'! process: aProcess ^ self new setProcess: aProcess! ! !OTProcessNode methodsFor: 'comparing' stamp: 'lr 10/7/2007 11:48'! = anObject ^ self class = anObject class and: [ self process = anObject process ]! ! !OTProcessNode methodsFor: 'testing' stamp: 'lr 8/3/2007 19:25'! allowDebug ^ self rules third! ! !OTProcessNode methodsFor: 'testing' stamp: 'lr 8/3/2007 19:25'! allowStop ^ self rules second! ! !OTProcessNode methodsFor: 'accessing' stamp: 'lr 4/26/2007 09:11'! context ^ process suspendedContext! ! !OTProcessNode methodsFor: 'navigation' stamp: 'lr 8/3/2007 19:57'! contextNode ^ OTContextNode process: self process context: self context! ! !OTProcessNode methodsFor: 'testing' stamp: 'lr 8/3/2007 19:18'! hasSelector ^ true! ! !OTProcessNode methodsFor: 'testing' stamp: 'lr 8/3/2007 19:18'! hasVersions ^ true! ! !OTProcessNode methodsFor: 'testing' stamp: 'lr 8/3/2007 19:26'! isActiveProcess ^ self process isActiveProcess! ! !OTProcessNode methodsFor: 'navigation' stamp: 'lr 4/25/2007 20:24'! longStack ^ self stackOfSize: 1024! ! !OTProcessNode methodsFor: 'accessing-dynamic' stamp: 'lr 8/3/2007 19:19'! methodReference ^ MethodReference class: self theClass selector: self selector! ! !OTProcessNode methodsFor: 'accessing' stamp: 'lr 8/3/2007 19:33'! name ^ self process browserPrintStringWith: self rules first! ! !OTProcessNode methodsFor: 'accessing' stamp: 'lr 4/26/2007 09:11'! process ^ process! ! !OTProcessNode methodsFor: 'private' stamp: 'lr 8/3/2007 19:57'! rules ^ ProcessBrowser nameAndRulesFor: self process! ! !OTProcessNode methodsFor: 'accessing-dynamic' stamp: 'lr 8/3/2007 19:19'! selector ^ self context selector! ! !OTProcessNode methodsFor: 'initialization' stamp: 'lr 8/3/2007 19:20'! setProcess: aProcess process := aProcess! ! !OTProcessNode methodsFor: 'navigation' stamp: 'lr 4/25/2007 20:25'! shortStack ^ self stackOfSize: 64! ! !OTProcessNode methodsFor: 'navigation' stamp: 'lr 8/3/2007 19:20'! stackOfSize: anInteger | current stack | current := self context. stack := OrderedCollection new: anInteger. [ current notNil and: [ stack size < anInteger ] ] whileTrue: [ stack addLast: (OTContextNode process: self process context: current). current := current sender ]. ^ stack! ! !OTProcessNode methodsFor: 'accessing-dynamic' stamp: 'lr 8/3/2007 19:18'! theClass ^ self context receiver class whichClassIncludesSelector: self selector! ! OBNode subclass: #OTSchedulerNode instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Processes'! !OTSchedulerNode methodsFor: 'comparing' stamp: 'lr 10/7/2007 12:21'! = anObject ^ self class = anObject class! ! !OTSchedulerNode methodsFor: 'navigation' stamp: 'lr 8/3/2007 19:23'! processes | processes | processes := Process allSubInstances reject: [ :each | each isTerminated ]. processes := processes sortBy: [ :a :b | a priority = b priority ifFalse: [ a priority >= b priority ] ifTrue: [ a hash >= b hash ] ]. ^ processes collect: [ :each | OTProcessNode process: each ]! ! OBNode subclass: #OTTranscriptNode instanceVariableNames: 'stream' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Transcript'! !OTTranscriptNode class methodsFor: 'as yet unclassified' stamp: 'lr 11/21/2007 13:45'! on: aTranscriptStream ^ self new initializeOn: aTranscriptStream! ! !OTTranscriptNode methodsFor: 'initialization' stamp: 'lr 11/21/2007 13:45'! initializeOn: aTranscriptStream stream := aTranscriptStream! ! !OTTranscriptNode methodsFor: 'accessing' stamp: 'lr 11/21/2007 13:52'! stream ^ stream! ! !OTTranscriptNode methodsFor: 'accessing' stamp: 'lr 11/21/2007 13:48'! text ^ self stream contents! ! !OTTranscriptNode methodsFor: 'accessing' stamp: 'lr 11/21/2007 13:46'! title ^ 'Transcript'! ! OBNode subclass: #OTWorkspaceNode instanceVariableNames: 'text bindings' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Workspace'! !OTWorkspaceNode methodsFor: 'callbacks' stamp: 'lr 12/11/2007 10:18'! bindingOf: aString! ! !OTWorkspaceNode methodsFor: 'callbacks' stamp: 'lr 12/11/2007 10:18'! doItContext self halt! ! !OTWorkspaceNode methodsFor: 'callbacks' stamp: 'lr 12/11/2007 10:18'! doItReceiver self halt! ! !OTWorkspaceNode methodsFor: 'public' stamp: 'lr 12/11/2007 10:25'! name ^ 'Workspace'! ! !OTWorkspaceNode methodsFor: 'callbacks' stamp: 'lr 12/11/2007 10:17'! text ^ text! ! !OTWorkspaceNode methodsFor: 'callbacks' stamp: 'lr 12/11/2007 10:17'! text: aString text := aString. ^ true! ! !OTWorkspaceNode methodsFor: 'displaying' stamp: 'lr 11/30/2007 10:22'! title ^ 'Workspace'! ! !Collection methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:34'! derivedInspectorNodes ^ super derivedInspectorNodes add: (OTDerivedInspectorNode on: self label: 'size' block: [ :obj | obj size ]); yourself! ! !SequenceableCollection methodsFor: '*ob-tools-inspector' stamp: 'lr 5/19/2007 11:28'! elementInspectorNodes ^ (1 to: self size) collect: [ :each | OTSequenceInspectorNode on: self index: each ]! ! OBCommand subclass: #OTCmdDebugger instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! OTCmdDebugger subclass: #OTCmdBrowse instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTCmdBrowse methodsFor: 'execution' stamp: 'lr 8/3/2007 19:49'! execute OBSystemBrowser openOnClass: target theClass selector: target selector! ! !OTCmdBrowse methodsFor: 'accessing' stamp: 'lr 4/26/2007 15:41'! group ^ #browse! ! !OTCmdBrowse methodsFor: 'accessing' stamp: 'lr 4/26/2007 15:37'! keystroke ^ $b! ! !OTCmdBrowse methodsFor: 'accessing' stamp: 'lr 4/26/2007 15:35'! label ^ 'browse'! ! OTCmdBrowse subclass: #OTCmdHierarchy instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTCmdHierarchy methodsFor: 'execution' stamp: 'lr 4/26/2007 15:38'! execute OBHierarchyBrowser openOnClass: target theClass! ! !OTCmdHierarchy methodsFor: 'accessing' stamp: 'lr 4/26/2007 15:43'! keystroke ^ nil! ! !OTCmdHierarchy methodsFor: 'accessing' stamp: 'lr 4/26/2007 15:42'! label ^ 'browse hierarchy'! ! OTCmdBrowse subclass: #OTCmdImplementors instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTCmdImplementors methodsFor: 'execution' stamp: 'lr 4/26/2007 15:46'! execute OBImplementorsBrowser browseRoot: target methodReference asNode! ! !OTCmdImplementors methodsFor: 'accessing' stamp: 'lr 4/26/2007 15:40'! keystroke ^ $m! ! !OTCmdImplementors methodsFor: 'accessing' stamp: 'lr 4/26/2007 15:40'! label ^ 'browse implementors'! ! OTCmdBrowse subclass: #OTCmdSenders instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTCmdSenders methodsFor: 'execution' stamp: 'lr 4/26/2007 15:46'! execute OBSendersBrowser browseRoot: target methodReference asNode! ! !OTCmdSenders methodsFor: 'accessing' stamp: 'lr 4/26/2007 15:43'! keystroke ^ $n! ! !OTCmdSenders methodsFor: 'accessing' stamp: 'lr 4/26/2007 15:39'! label ^ 'browse senders'! ! !OTCmdDebugger methodsFor: 'actions' stamp: 'lr 4/26/2007 09:17'! announce: anAnnouncement requestor announce: anAnnouncement! ! !OTCmdDebugger methodsFor: 'accessing' stamp: 'lr 4/25/2007 20:41'! context ^ target context! ! !OTCmdDebugger methodsFor: 'testing' stamp: 'lr 10/7/2007 11:45'! isActive ^ (target isKindOf: OTContextNode) and: [ requestor isSelected: target ]! ! !OTCmdDebugger methodsFor: 'accessing' stamp: 'lr 4/25/2007 20:41'! process ^ target process! ! !OTCmdDebugger methodsFor: 'actions' stamp: 'lr 10/7/2007 12:08'! update | processNode | processNode := requestor browser root. self announce: (OBChildrenChanged node: processNode). self announce: (OBSelectingNode node: processNode contextNode)! ! OTCmdDebugger subclass: #OTCmdInspect instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTCmdInspect methodsFor: 'execution' stamp: 'lr 4/26/2007 15:28'! execute target context inspect! ! !OTCmdInspect methodsFor: 'accessing' stamp: 'lr 4/26/2007 15:47'! group ^ #inspect! ! !OTCmdInspect methodsFor: 'accessing' stamp: 'lr 4/26/2007 15:28'! label ^ 'inspect context'! ! OTCmdInspect subclass: #OTCmdInspectReceiver instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTCmdInspectReceiver methodsFor: 'execution' stamp: 'lr 4/26/2007 15:28'! execute target context receiver inspect! ! !OTCmdInspectReceiver methodsFor: 'accessing' stamp: 'lr 4/26/2007 15:28'! label ^ 'inspect receiver'! ! OTCmdDebugger subclass: #OTCmdInto instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTCmdInto methodsFor: 'execution' stamp: 'lr 4/26/2007 09:34'! execute target process step: target context; stepToSendOrReturn. self update! ! !OTCmdInto methodsFor: 'accessing' stamp: 'lr 4/25/2007 18:07'! label ^ 'into'! ! !OTCmdInto methodsFor: 'testing' stamp: 'lr 4/25/2007 18:10'! wantsButton ^ true! ! OTCmdDebugger subclass: #OTCmdOver instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTCmdOver methodsFor: 'execution' stamp: 'lr 4/26/2007 15:49'! execute target process completeStep: target context; stepToSendOrReturn. self update! ! !OTCmdOver methodsFor: 'accessing' stamp: 'lr 4/25/2007 18:07'! label ^ 'over'! ! !OTCmdOver methodsFor: 'testing' stamp: 'lr 4/25/2007 18:10'! wantsButton ^ true! ! OTCmdDebugger subclass: #OTCmdProceed instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTCmdProceed methodsFor: 'execution' stamp: 'lr 7/14/2007 19:43'! execute World allMorphs do: [ :each | each model == requestor browser ifTrue: [ each delete ] ]. target process resume! ! !OTCmdProceed methodsFor: 'accessing' stamp: 'lr 4/25/2007 18:07'! label ^ 'proceed'! ! !OTCmdProceed methodsFor: 'testing' stamp: 'lr 4/25/2007 18:10'! wantsButton ^ true! ! OTCmdDebugger subclass: #OTCmdRestart instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTCmdRestart methodsFor: 'execution' stamp: 'lr 4/26/2007 09:35'! execute self process popTo: self context; restartTop; stepToSendOrReturn. self update! ! !OTCmdRestart methodsFor: 'accessing' stamp: 'lr 4/25/2007 18:09'! label ^ 'restart'! ! !OTCmdRestart methodsFor: 'testing' stamp: 'lr 4/25/2007 18:10'! wantsButton ^ true! ! OTCmdDebugger subclass: #OTCmdReturn instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTCmdReturn methodsFor: 'execution' stamp: 'lr 8/3/2007 19:40'! execute | expression value | expression := OBTextRequest prompt: 'Enter expression for return value:' template: 'nil'. value := Compiler new evaluate: expression in: target context to: target context receiver. target process popTo: target context sender value: value; stepToSendOrReturn. self update! ! !OTCmdReturn methodsFor: 'accessing' stamp: 'lr 4/25/2007 18:15'! label ^ 'return'! ! !OTCmdReturn methodsFor: 'testing' stamp: 'lr 4/25/2007 18:15'! wantsButton ^ true! ! OTCmdDebugger subclass: #OTCmdThrough instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Debugger'! !OTCmdThrough methodsFor: 'execution' stamp: 'lr 4/26/2007 09:34'! execute target process stepToHome: target context; stepToSendOrReturn. self update! ! !OTCmdThrough methodsFor: 'accessing' stamp: 'lr 5/31/2007 07:41'! label ^ 'through'! ! !OTCmdThrough methodsFor: 'testing' stamp: 'lr 4/25/2007 18:10'! wantsButton ^ true! ! OBCommand subclass: #OTCmdInspector instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! OTCmdInspector subclass: #OTCmdInspectObject instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! !OTCmdInspectObject methodsFor: 'execution' stamp: 'lr 4/26/2007 16:37'! execute target value inspect! ! !OTCmdInspectObject methodsFor: 'accessing' stamp: 'dc 3/28/2007 17:06'! keystroke ^ $i! ! !OTCmdInspectObject methodsFor: 'accessing' stamp: 'dc 3/28/2007 17:05'! label ^ 'inspect'! ! OTCmdInspector subclass: #OTCmdInspectReferences instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Inspector'! !OTCmdInspectReferences methodsFor: 'execution' stamp: 'lr 5/7/2007 16:03'! execute (Utilities pointersTo: target value except: (Array with: target)) inspect! ! !OTCmdInspectReferences methodsFor: 'accessing' stamp: 'dc 3/28/2007 17:07'! label ^ 'inspect references'! ! !OTCmdInspector methodsFor: 'accessing' stamp: 'lr 4/26/2007 16:38'! group ^ #inspection! ! !OTCmdInspector methodsFor: 'testing' stamp: 'lr 4/26/2007 16:38'! isActive ^ requestor isSelected: target! ! OBCommand subclass: #OTCmdProcessBrowser instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Processes'! OTCmdProcessBrowser subclass: #OTCmdDebugProcessBrowser instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Processes'! !OTCmdDebugProcessBrowser methodsFor: 'execution' stamp: 'lr 8/3/2007 18:59'! execute target process resume; debugWithTitle: 'Interrupted from the Process Browser'! ! !OTCmdDebugProcessBrowser methodsFor: 'testing' stamp: 'lr 8/3/2007 16:46'! isEnabled ^ target allowDebug! ! !OTCmdDebugProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:04'! keystroke ^ $d! ! !OTCmdDebugProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:03'! label ^ 'debug'! ! OTCmdProcessBrowser subclass: #OTCmdPriorityProcessBrowser instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Processes'! !OTCmdPriorityProcessBrowser methodsFor: 'execution' stamp: 'lr 8/3/2007 19:00'! execute | priority | priority := (OBTextRequest prompt: 'New priority' template: target process priority asString) ifNil: [ ^ self ]. priority := priority asNumber asInteger. (priority between: Processor lowestPriority and: Processor highestPriority) ifFalse: [ ^ OBInformRequest message: 'Bad priority' ]. target process priority: priority. self update! ! !OTCmdPriorityProcessBrowser methodsFor: 'testing' stamp: 'lr 8/3/2007 16:47'! isEnabled ^ target allowDebug! ! !OTCmdPriorityProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:05'! keystroke ^ $p! ! !OTCmdPriorityProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 19:05'! label ^ 'priority'! ! !OTCmdProcessBrowser methodsFor: 'testing' stamp: 'lr 8/23/2007 11:43'! isActive ^ ( target class = OTProcessNode) and: [ requestor isSelected: target ]! ! !OTCmdProcessBrowser methodsFor: 'actions' stamp: 'lr 8/3/2007 16:37'! update requestor announce: OBRefreshRequired! ! OTCmdProcessBrowser subclass: #OTCmdProfileProcessBrowser instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Processes'! !OTCmdProfileProcessBrowser methodsFor: 'execution' stamp: 'lr 8/3/2007 19:09'! execute | seconds | seconds := (OBTextRequest prompt: 'Profile for how many seconds?' template: '4') ifNil: [ ^ self ]. seconds := seconds asNumber asInteger. seconds isZero ifTrue: [ ^ self ]. [ TimeProfileBrowser spyOnProcess: target process forMilliseconds: seconds * 1000 ] forkAt: target process priority + 1! ! !OTCmdProfileProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:04'! keystroke ^ $m! ! !OTCmdProfileProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 19:05'! label ^ 'profile'! ! OTCmdProcessBrowser subclass: #OTCmdResumeProcessBrowser instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Processes'! !OTCmdResumeProcessBrowser methodsFor: 'execution' stamp: 'lr 8/3/2007 16:37'! execute target process resume. self update! ! !OTCmdResumeProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 19:03'! group ^ #controlling! ! !OTCmdResumeProcessBrowser methodsFor: 'testing' stamp: 'lr 8/3/2007 19:02'! isActive ^ super isActive and: [ target process isSuspended ]! ! !OTCmdResumeProcessBrowser methodsFor: 'testing' stamp: 'lr 8/3/2007 19:03'! isEnabled ^ target allowStop! ! !OTCmdResumeProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:16'! keystroke ^ $r! ! !OTCmdResumeProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:16'! label ^ 'resume'! ! OTCmdProcessBrowser subclass: #OTCmdSignalProcessBrowser instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Processes'! !OTCmdSignalProcessBrowser methodsFor: 'execution' stamp: 'lr 8/3/2007 16:41'! execute | semaphore | semaphore := target process suspendingList. (semaphore isKindOf: Semaphore) ifFalse: [ ^ self ]. [ semaphore signal ] forkAndWait. self update! ! !OTCmdSignalProcessBrowser methodsFor: 'testing' stamp: 'lr 8/3/2007 16:40'! isEnabled ^ target process suspendingList isKindOf: Semaphore! ! !OTCmdSignalProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:05'! keystroke ^ $S! ! !OTCmdSignalProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 19:05'! label ^ 'signal'! ! OTCmdProcessBrowser subclass: #OTCmdSuspendProcessBrowser instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Processes'! !OTCmdSuspendProcessBrowser methodsFor: 'execution' stamp: 'lr 8/3/2007 16:37'! execute target process suspend. self update! ! !OTCmdSuspendProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 19:03'! group ^ #controlling! ! !OTCmdSuspendProcessBrowser methodsFor: 'testing' stamp: 'lr 8/3/2007 19:02'! isActive ^ super isActive and: [ target process isSuspended not ]! ! !OTCmdSuspendProcessBrowser methodsFor: 'testing' stamp: 'lr 8/3/2007 19:03'! isEnabled ^ target allowStop! ! !OTCmdSuspendProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:04'! keystroke ^ $s! ! !OTCmdSuspendProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:03'! label ^ 'suspend'! ! OTCmdProcessBrowser subclass: #OTCmdTerminateProcessBrowser instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Processes'! !OTCmdTerminateProcessBrowser methodsFor: 'execution' stamp: 'lr 8/3/2007 16:37'! execute target process terminate. self update! ! !OTCmdTerminateProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 19:03'! group ^ #controlling! ! !OTCmdTerminateProcessBrowser methodsFor: 'testing' stamp: 'lr 8/3/2007 16:44'! isEnabled ^ target allowStop! ! !OTCmdTerminateProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:04'! keystroke ^ $t! ! !OTCmdTerminateProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:03'! label ^ 'terminate'! ! OTCmdProcessBrowser subclass: #OTCmdUpdateProcessBrowser instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'OB-Tools-Processes'! !OTCmdUpdateProcessBrowser methodsFor: 'execution' stamp: 'lr 8/3/2007 16:37'! execute self update! ! !OTCmdUpdateProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 19:04'! group ^ #updating! ! !OTCmdUpdateProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:25'! keystroke ^ $u! ! !OTCmdUpdateProcessBrowser methodsFor: 'accessing' stamp: 'lr 8/3/2007 16:25'! label ^ 'update'! ! !Morph methodsFor: '*ob-tools' stamp: 'dc 6/1/2007 14:31'! addMorph: aMorph frame: relFrame | frame | frame _ LayoutFrame new. frame leftFraction: relFrame left; rightFraction: relFrame right; topFraction: relFrame top; bottomFraction: relFrame bottom. self addMorph: aMorph fullFrame: frame. ! ! OTToolset initialize!