"{ Package: 'stx:libtool' }"
"{ NameSpace: Tools }"
ToDoListEntry subclass:#CompilerWarningToDoListEntry
instanceVariableNames:'checkAction className class selector position equalityParameter'
classVariableNames:''
poolDictionaries:''
category:'Interface-Smalltalk-ToDo'
!
!CompilerWarningToDoListEntry methodsFor:'accessing'!
className
^ className
"Created: / 22-10-2006 / 01:39:43 / cg"
!
className:classNameArg selector:selectorArg checkAction:checkActionArg equalityParameter:equalityParameterArg
checkAction := checkActionArg.
className := classNameArg.
selector := selectorArg.
equalityParameter := equalityParameterArg.
"Created: / 22-10-2006 / 01:38:26 / cg"
!
equalityParameter
^ equalityParameter
"Created: / 21-10-2006 / 21:57:01 / cg"
!
methodOrClassName
selector isNil ifTrue:[^ className ].
^ className,' ',selector
"Created: / 22-10-2006 / 11:05:21 / cg"
!
position
^ position
!
position:something
position := something.
!
problemClass
^ Smalltalk classNamed:className
"Created: / 21-10-2006 / 21:50:38 / cg"
"Modified: / 22-10-2006 / 01:39:39 / cg"
!
problemClassName
^ className
"Created: / 22-10-2006 / 01:40:11 / cg"
!
problemMethod
|cls|
selector isNil ifTrue:[^ nil].
cls := self problemClass.
cls isNil ifTrue:[^ nil].
^ cls compiledMethodAt:selector
"Created: / 22-10-2006 / 02:42:39 / cg"
!
problemSelector
^ selector
"Created: / 21-10-2006 / 21:50:58 / cg"
!
update:something with:aParameter from:changedObject
self revalidate.
"Created: / 21-10-2006 / 21:28:35 / cg"
! !
!CompilerWarningToDoListEntry methodsFor:'duplicate detection'!
sameAs:anotherEntry
^ anotherEntry sameAsCompilerWarningToDoListEntry:self
"Created: / 21-10-2006 / 21:38:15 / cg"
!
sameAsCompilerWarningToDoListEntry:anotherEntry
anotherEntry problemClassName = className ifFalse:[^ false].
anotherEntry problemSelector = selector ifFalse:[^ false].
anotherEntry equalityParameter = equalityParameter ifFalse:[^ false].
^ true
"Created: / 21-10-2006 / 21:41:57 / cg"
"Modified: / 22-10-2006 / 01:40:03 / cg"
! !
!CompilerWarningToDoListEntry methodsFor:'misc'!
browse
|brwsr|
brwsr := UserPreferences browserClass
openInClass:(self problemClass) selector:selector.
brwsr codeView cursorToCharacterPosition:position.
"/ brwsr codeView selectLine:(brwsr codeView cursorLine).
"Created: / 22-10-2006 / 01:38:11 / cg"
"Modified: / 11-11-2006 / 14:49:35 / cg"
! !
!CompilerWarningToDoListEntry methodsFor:'validation'!
checkIfClassIsStillValid
className notNil ifTrue:[
(Smalltalk classNamed:className) isNil ifTrue:[^ false].
].
^ true
"Created: / 21-10-2006 / 21:58:26 / cg"
"Modified: / 22-10-2006 / 01:41:53 / cg"
!
checkIfSelectorIsStillValid
selector notNil ifTrue:[
(self problemClass compiledMethodAt:selector) isNil ifTrue:[^ false].
].
^ true
"Created: / 21-10-2006 / 21:58:44 / cg"
"Modified: / 22-10-2006 / 01:40:40 / cg"
!
checkIfStillValid
self checkIfClassIsStillValid ifFalse:[^ false].
self checkIfSelectorIsStillValid ifFalse:[^ false].
^ (checkAction value:self)
"Created: / 21-10-2006 / 21:31:27 / cg"
"Modified: / 21-10-2006 / 23:10:33 / cg"
! !
!CompilerWarningToDoListEntry class methodsFor:'documentation'!
version
^ '$Header: /cvs/stx/stx/libtool/Tools__CompilerWarningToDoListEntry.st,v 1.2 2006-11-13 12:20:34 cg Exp $'
! !