7444
|
1 |
"{ Package: 'stx:libtool' }"
|
|
2 |
|
|
3 |
"{ NameSpace: Tools }"
|
|
4 |
|
|
5 |
Object subclass:#ToDoListEntry
|
|
6 |
instanceVariableNames:'list stillValid severity priority timestamp message'
|
|
7 |
classVariableNames:''
|
|
8 |
poolDictionaries:''
|
|
9 |
category:'Interface-Smalltalk-ToDo'
|
|
10 |
!
|
|
11 |
|
|
12 |
|
|
13 |
!ToDoListEntry methodsFor:'accessing'!
|
|
14 |
|
|
15 |
list:something
|
|
16 |
list := something.
|
|
17 |
!
|
|
18 |
|
|
19 |
message
|
|
20 |
^ message
|
|
21 |
!
|
|
22 |
|
|
23 |
priority
|
|
24 |
^ priority ? 0
|
|
25 |
|
|
26 |
"Modified: / 22-10-2006 / 11:09:36 / cg"
|
|
27 |
!
|
|
28 |
|
|
29 |
severity
|
|
30 |
^ severity ? 0
|
|
31 |
|
|
32 |
"Modified: / 22-10-2006 / 11:09:42 / cg"
|
|
33 |
!
|
|
34 |
|
|
35 |
severity:severityArg priority:priorityArg timestamp:timestampArg message:messageArg
|
|
36 |
severity := severityArg.
|
|
37 |
priority := priorityArg.
|
|
38 |
timestamp := timestampArg.
|
|
39 |
message := messageArg.
|
|
40 |
!
|
|
41 |
|
|
42 |
stillValid
|
|
43 |
^ stillValid ? true
|
|
44 |
|
|
45 |
"Created: / 21-10-2006 / 20:45:33 / cg"
|
|
46 |
!
|
|
47 |
|
|
48 |
time
|
|
49 |
^ timestamp asTime
|
|
50 |
|
|
51 |
"Created: / 21-10-2006 / 20:58:14 / cg"
|
|
52 |
!
|
|
53 |
|
|
54 |
timestamp
|
|
55 |
^ timestamp
|
|
56 |
! !
|
|
57 |
|
|
58 |
!ToDoListEntry methodsFor:'duplicate detection'!
|
|
59 |
|
|
60 |
isAlreadyPresentIn:aList
|
|
61 |
^ aList contains:[:anEntry | anEntry sameAs:self ].
|
|
62 |
|
|
63 |
"Created: / 21-10-2006 / 21:36:57 / cg"
|
|
64 |
!
|
|
65 |
|
|
66 |
sameAs:anotherEntry
|
|
67 |
self subclassResponsibility
|
|
68 |
|
|
69 |
"Created: / 21-10-2006 / 21:37:42 / cg"
|
|
70 |
!
|
|
71 |
|
|
72 |
sameAsCompilerWarningToDoListEntry:anotherEntry
|
|
73 |
^ false
|
|
74 |
|
|
75 |
"Created: / 21-10-2006 / 21:40:47 / cg"
|
|
76 |
! !
|
|
77 |
|
|
78 |
!ToDoListEntry methodsFor:'misc'!
|
|
79 |
|
|
80 |
browse
|
|
81 |
self subclassResponsibility
|
|
82 |
|
|
83 |
"Created: / 22-10-2006 / 01:37:42 / cg"
|
|
84 |
! !
|
|
85 |
|
|
86 |
!ToDoListEntry methodsFor:'printing & storing'!
|
|
87 |
|
|
88 |
printOn:aStream
|
|
89 |
aStream nextPutAll:message
|
|
90 |
|
|
91 |
"Created: / 21-10-2006 / 23:13:39 / cg"
|
|
92 |
! !
|
|
93 |
|
|
94 |
!ToDoListEntry methodsFor:'validation'!
|
|
95 |
|
|
96 |
checkIfStillValid
|
|
97 |
self subclassResponsibility
|
|
98 |
|
|
99 |
"Created: / 21-10-2006 / 21:30:29 / cg"
|
|
100 |
!
|
|
101 |
|
|
102 |
revalidate
|
|
103 |
self checkIfStillValid ifFalse:[
|
|
104 |
stillValid := false.
|
|
105 |
list removeIdentical:self ifAbsent:[].
|
|
106 |
Smalltalk removeDependent:self.
|
|
107 |
].
|
|
108 |
|
|
109 |
"Created: / 21-10-2006 / 20:46:03 / cg"
|
|
110 |
"Modified: / 21-10-2006 / 22:00:52 / cg"
|
|
111 |
! !
|
|
112 |
|
|
113 |
!ToDoListEntry class methodsFor:'documentation'!
|
|
114 |
|
|
115 |
version
|
|
116 |
^ '$Header: /cvs/stx/stx/libtool/Tools__ToDoListEntry.st,v 1.1 2006-10-23 08:57:48 cg Exp $'
|
|
117 |
! !
|