ChangeSetDiffComponent.st
author Jan Vrany <jan.vrany@fit.cvut.cz>
Thu, 28 Mar 2013 12:22:48 +0000
branchjv
changeset 3158 f8c56a311307
parent 3128 87750af738dc
parent 2880 0072cabff85a
child 3416 b02354ae5ecf
permissions -rw-r--r--
Merged 87750af738dc and 72ca7e81fbbf (branch default - CVS HEAD)
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
     1
"
cf06c39b234c initial checkin
vrany
parents:
diff changeset
     2
 Copyright (c) 2007-2010 Jan Vrany, SWING Research Group,
cf06c39b234c initial checkin
vrany
parents:
diff changeset
     3
                           Czech Technical University in Prague
cf06c39b234c initial checkin
vrany
parents:
diff changeset
     4
 Copyright (c) 2009-2010 eXept Software AG
cf06c39b234c initial checkin
vrany
parents:
diff changeset
     5
cf06c39b234c initial checkin
vrany
parents:
diff changeset
     6
 Permission is hereby granted, free of charge, to any person
cf06c39b234c initial checkin
vrany
parents:
diff changeset
     7
 obtaining a copy of this software and associated documentation
cf06c39b234c initial checkin
vrany
parents:
diff changeset
     8
 files (the 'Software'), to deal in the Software without
cf06c39b234c initial checkin
vrany
parents:
diff changeset
     9
 restriction, including without limitation the rights to use,
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    10
 copy, modify, merge, publish, distribute, sublicense, and/or sell
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    11
 copies of the Software, and to permit persons to whom the
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    12
 Software is furnished to do so, subject to the following
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    13
 conditions:
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    14
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    15
 The above copyright notice and this permission notice shall be
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    16
 included in all copies or substantial portions of the Software.
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    17
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    18
 THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    19
 EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    20
 OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    21
 NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    22
 HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    23
 WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    24
 FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    25
 OTHER DEALINGS IN THE SOFTWARE.
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    26
"
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    27
"{ Package: 'stx:libbasic3' }"
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    28
2424
bc7e320cec40 Inherit from object, not Model (to fix dependencies)
vrany
parents: 2406
diff changeset
    29
Object subclass:#ChangeSetDiffComponent
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    30
	instanceVariableNames:'parent'
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    31
	classVariableNames:''
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    32
	poolDictionaries:''
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    33
	category:'System-Changes-Diff'
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    34
!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    35
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    36
!ChangeSetDiffComponent class methodsFor:'documentation'!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    37
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    38
copyright
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    39
"
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    40
 Copyright (c) 2007-2010 Jan Vrany, SWING Research Group,
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    41
                           Czech Technical University in Prague
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    42
 Copyright (c) 2009-2010 eXept Software AG
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    43
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    44
 Permission is hereby granted, free of charge, to any person
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    45
 obtaining a copy of this software and associated documentation
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    46
 files (the 'Software'), to deal in the Software without
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    47
 restriction, including without limitation the rights to use,
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    48
 copy, modify, merge, publish, distribute, sublicense, and/or sell
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    49
 copies of the Software, and to permit persons to whom the
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    50
 Software is furnished to do so, subject to the following
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    51
 conditions:
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    52
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    53
 The above copyright notice and this permission notice shall be
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    54
 included in all copies or substantial portions of the Software.
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    55
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    56
 THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    57
 EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    58
 OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    59
 NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    60
 HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    61
 WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    62
 FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    63
 OTHER DEALINGS IN THE SOFTWARE.
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    64
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    65
"
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    66
! !
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    67
3158
f8c56a311307 Merged 87750af738dc and 72ca7e81fbbf (branch default - CVS HEAD)
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3128 2880
diff changeset
    68
2880
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
    69
!ChangeSetDiffComponent class methodsFor:'others'!
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
    70
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
    71
version_CVS
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
    72
    ^ '$Header: /cvs/stx/stx/libbasic3/ChangeSetDiffComponent.st,v 1.4 2012-07-31 12:34:40 vrany Exp $'
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
    73
! !
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
    74
3158
f8c56a311307 Merged 87750af738dc and 72ca7e81fbbf (branch default - CVS HEAD)
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3128 2880
diff changeset
    75
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    76
!ChangeSetDiffComponent methodsFor:'accessing'!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    77
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    78
changesetA
2643
vrany
parents: 2424
diff changeset
    79
    "Answers a changeset with containing all versionA changes"
vrany
parents: 2424
diff changeset
    80
    | cs |
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    81
2643
vrany
parents: 2424
diff changeset
    82
    cs := ChangeSet new name: self versionALabel.
vrany
parents: 2424
diff changeset
    83
    self do:[:item|
3122
91c582043a51 Added support for writing extensions files as sources. Added version_HG to classes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
    84
        (item versionA notNil and:[item versionMerged isClassDefinitionChange or:[item versionMerged isMethodCodeChange]]) ifTrue:[
2880
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
    85
            cs add: item versionA
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
    86
        ]
2643
vrany
parents: 2424
diff changeset
    87
    ].
vrany
parents: 2424
diff changeset
    88
    ^cs
vrany
parents: 2424
diff changeset
    89
3122
91c582043a51 Added support for writing extensions files as sources. Added version_HG to classes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
    90
    "Modified: / 29-01-2013 / 18:44:17 / Jan Vrany <jan.vrany@fit.cvut.cz>"
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    91
!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    92
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    93
changesetB
2880
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
    94
    "Answers a changeset with containing all versionA changes"
2643
vrany
parents: 2424
diff changeset
    95
    | cs |
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
    96
2643
vrany
parents: 2424
diff changeset
    97
    cs := ChangeSet new name: self versionBLabel.
vrany
parents: 2424
diff changeset
    98
    self do:[:item|
3122
91c582043a51 Added support for writing extensions files as sources. Added version_HG to classes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
    99
        (item versionB notNil and:[item versionMerged isClassDefinitionChange or:[item versionMerged isMethodCodeChange]]) ifTrue:[
2880
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   100
            cs add: item versionB
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   101
        ]
2643
vrany
parents: 2424
diff changeset
   102
    ].
vrany
parents: 2424
diff changeset
   103
    ^cs
vrany
parents: 2424
diff changeset
   104
3122
91c582043a51 Added support for writing extensions files as sources. Added version_HG to classes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
   105
    "Modified: / 29-01-2013 / 18:44:43 / Jan Vrany <jan.vrany@fit.cvut.cz>"
2880
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   106
!
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   107
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   108
changesetBase
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   109
    "Answers a changeset with containing all versionA changes"
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   110
    | cs |
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   111
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   112
    cs := ChangeSet new name: self versionBaseLabel.
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   113
    self do:[:item|
3122
91c582043a51 Added support for writing extensions files as sources. Added version_HG to classes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
   114
        (item versionBase notNil and:[item versionBase isClassDefinitionChange or:[item versionBase isMethodCodeChange]]) ifTrue:[
2880
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   115
            cs add: item versionBase
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   116
        ]
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   117
    ].
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   118
    ^cs
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   119
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   120
    "Created: / 20-03-2012 / 13:31:35 / Jan Vrany <jan.vrany@fit.cvut.cz>"
3122
91c582043a51 Added support for writing extensions files as sources. Added version_HG to classes.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
   121
    "Modified: / 29-01-2013 / 18:44:40 / Jan Vrany <jan.vrany@fit.cvut.cz>"
2880
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   122
!
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   123
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   124
changesetMerged
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   125
    "Answers a changeset with containing all versionA changes"
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   126
    | cs |
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   127
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   128
    cs := ChangeSet new name: 'Merged'.
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   129
    self do:[:item|
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   130
"/        (item versionMerged isClassDefinitionChange or:[item versionMerged isMethodCodeChange]) ifTrue:[
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   131
            cs add: item versionMerged
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   132
"/        ]
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   133
    ].
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   134
    ^cs
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   135
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   136
    "Created: / 20-03-2012 / 13:32:41 / Jan Vrany <jan.vrany@fit.cvut.cz>"
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   137
!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   138
3098
67aaf3fadffb Added ChangeSetDiffComponent>>depth
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3078
diff changeset
   139
depth
67aaf3fadffb Added ChangeSetDiffComponent>>depth
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3078
diff changeset
   140
    "Return the depth if diff component hierarchy, 0 if there is no nesting at all"
67aaf3fadffb Added ChangeSetDiffComponent>>depth
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3078
diff changeset
   141
    ^0
67aaf3fadffb Added ChangeSetDiffComponent>>depth
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3078
diff changeset
   142
67aaf3fadffb Added ChangeSetDiffComponent>>depth
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3078
diff changeset
   143
    "Created: / 15-01-2013 / 11:26:10 / Jan Vrany <jan.vrany@fit.cvut.cz>"
67aaf3fadffb Added ChangeSetDiffComponent>>depth
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3078
diff changeset
   144
!
67aaf3fadffb Added ChangeSetDiffComponent>>depth
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3078
diff changeset
   145
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   146
diffs
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   147
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   148
    ^#()
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   149
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   150
    "Created: / 10-11-2009 / 11:29:05 / Jan Vrany <jan.vrany@fit.cvut.cz>"
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   151
!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   152
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   153
flattened
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   154
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   155
    ^ChangeSetDiffSet new add: self
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   156
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   157
    "Created: / 05-12-2009 / 11:07:54 / Jan Vrany <jan.vrany@fit.cvut.cz>"
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   158
!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   159
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   160
name
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   161
    "raise an error: must be redefined in concrete subclass(es)"
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   162
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   163
    ^ self subclassResponsibility
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   164
!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   165
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   166
parent
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   167
    ^ parent
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   168
!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   169
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   170
parent:aDiffSet
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   171
    parent := aDiffSet.
2643
vrany
parents: 2424
diff changeset
   172
!
vrany
parents: 2424
diff changeset
   173
vrany
parents: 2424
diff changeset
   174
versionALabel
vrany
parents: 2424
diff changeset
   175
    ^ parent versionALabel
vrany
parents: 2424
diff changeset
   176
vrany
parents: 2424
diff changeset
   177
    "Created: / 09-11-2009 / 12:38:52 / Jan Vrany <jan.vrany@fit.cvut.cz>"
vrany
parents: 2424
diff changeset
   178
!
vrany
parents: 2424
diff changeset
   179
vrany
parents: 2424
diff changeset
   180
versionBLabel
vrany
parents: 2424
diff changeset
   181
    ^ parent versionBLabel
vrany
parents: 2424
diff changeset
   182
vrany
parents: 2424
diff changeset
   183
    "Created: / 09-11-2009 / 12:38:58 / Jan Vrany <jan.vrany@fit.cvut.cz>"
2880
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   184
!
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   185
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   186
versionBaseLabel
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   187
    ^ parent versionBaseLabel
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   188
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   189
    "Created: / 20-03-2012 / 13:31:51 / Jan Vrany <jan.vrany@fit.cvut.cz>"
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   190
! !
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   191
3158
f8c56a311307 Merged 87750af738dc and 72ca7e81fbbf (branch default - CVS HEAD)
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3128 2880
diff changeset
   192
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   193
!ChangeSetDiffComponent methodsFor:'change & update'!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   194
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   195
changed: aspect with: param
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   196
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   197
    (aspect = #resolution and:[parent notNil])
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   198
        ifTrue:[parent changed: aspect with: param].
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   199
    super changed: aspect with: param.
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   200
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   201
    "Created: / 24-11-2009 / 12:58:32 / Jan Vrany <jan.vrany@fit.cvut.cz>"
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   202
! !
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   203
3158
f8c56a311307 Merged 87750af738dc and 72ca7e81fbbf (branch default - CVS HEAD)
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3128 2880
diff changeset
   204
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   205
!ChangeSetDiffComponent methodsFor:'enumerating'!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   206
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   207
do: aBlock
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   208
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   209
    self subclassResponsibility
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   210
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   211
    "Created: / 25-11-2009 / 10:22:09 / Jan Vrany <jan.vrany@fit.cvut.cz>"
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   212
! !
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   213
3158
f8c56a311307 Merged 87750af738dc and 72ca7e81fbbf (branch default - CVS HEAD)
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3128 2880
diff changeset
   214
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   215
!ChangeSetDiffComponent methodsFor:'printing & storing'!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   216
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   217
printOn:aStream
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   218
    "append a printed representation if the receiver to the argument, aStream"
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   219
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   220
    super printOn:aStream.
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   221
    aStream nextPut:$(.
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   222
    self name printOn: aStream.
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   223
    aStream nextPut:$).
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   224
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   225
    "Modified: / 26-11-2009 / 16:25:54 / Jan Vrany <jan.vrany@fit.cvut.cz>"
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   226
! !
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   227
3158
f8c56a311307 Merged 87750af738dc and 72ca7e81fbbf (branch default - CVS HEAD)
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3128 2880
diff changeset
   228
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   229
!ChangeSetDiffComponent methodsFor:'private'!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   230
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   231
flattenOn: stream
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   232
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   233
    ^stream nextPut: self
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   234
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   235
    "Created: / 05-12-2009 / 11:06:22 / Jan Vrany <jan.vrany@fit.cvut.cz>"
3099
be6ff432a2ad Fixes in ChangeSetDiff...
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3098
diff changeset
   236
!
be6ff432a2ad Fixes in ChangeSetDiff...
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3098
diff changeset
   237
be6ff432a2ad Fixes in ChangeSetDiff...
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3098
diff changeset
   238
sort
be6ff432a2ad Fixes in ChangeSetDiff...
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3098
diff changeset
   239
    self sort: [:a :b|a printString < b printString ].
be6ff432a2ad Fixes in ChangeSetDiff...
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3098
diff changeset
   240
be6ff432a2ad Fixes in ChangeSetDiff...
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3098
diff changeset
   241
    "Created: / 17-01-2013 / 13:56:43 / Jan Vrany <jan.vrany@fit.cvut.cz>"
be6ff432a2ad Fixes in ChangeSetDiff...
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3098
diff changeset
   242
!
be6ff432a2ad Fixes in ChangeSetDiff...
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3098
diff changeset
   243
be6ff432a2ad Fixes in ChangeSetDiff...
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3098
diff changeset
   244
sort: sortBlock
be6ff432a2ad Fixes in ChangeSetDiff...
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3098
diff changeset
   245
    self subclassResponsibility
be6ff432a2ad Fixes in ChangeSetDiff...
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3098
diff changeset
   246
be6ff432a2ad Fixes in ChangeSetDiff...
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3098
diff changeset
   247
    "Created: / 17-01-2013 / 13:57:03 / Jan Vrany <jan.vrany@fit.cvut.cz>"
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   248
! !
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   249
3158
f8c56a311307 Merged 87750af738dc and 72ca7e81fbbf (branch default - CVS HEAD)
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3128 2880
diff changeset
   250
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   251
!ChangeSetDiffComponent methodsFor:'testing'!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   252
3074
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   253
isConflict
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   254
    "Return true, if there is a conflict."
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   255
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   256
    ^ self subclassResponsibility
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   257
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   258
    "Modified (comment): / 01-08-2012 / 17:11:36 / Jan Vrany <jan.vrany@fit.cvut.cz>"
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   259
!
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   260
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   261
isDiffItem
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   262
    ^ false
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   263
!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   264
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   265
isDiffSet
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   266
    ^ false
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   267
!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   268
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   269
isEmpty
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   270
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   271
    ^false
2880
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   272
!
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   273
3074
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   274
isForCopyrightMethod
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   275
    "Returns true, if this is an entry for #copyright method"
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   276
    ^self subclassResponsibility
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   277
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   278
    "Created: / 01-08-2012 / 16:37:53 / Jan Vrany <jan.vrany@fit.cvut.cz>"
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   279
!
e38a06f751a5 Some more testing methods
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3069
diff changeset
   280
2880
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   281
isForVersionMethod
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   282
    "Returns true, if this is an entry for version method"
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   283
    ^self subclassResponsibility
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   284
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   285
    "Created: / 18-04-2012 / 19:04:25 / Jan Vrany <jan.vrany@fit.cvut.cz>"
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   286
!
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   287
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   288
isMerged
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   289
    "raise an error: must be redefined in concrete subclass(es)"
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   290
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   291
    ^ self subclassResponsibility
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   292
! !
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   293
3158
f8c56a311307 Merged 87750af738dc and 72ca7e81fbbf (branch default - CVS HEAD)
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3128 2880
diff changeset
   294
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   295
!ChangeSetDiffComponent class methodsFor:'documentation'!
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   296
3069
89d2cfee177f - stx_libbasic3
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3051
diff changeset
   297
version
3121
19723298dd2c Bugfix: reading of Java class extensions methods.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
   298
    ^ '$Header: ChangeSetDiffComponent.st 1986 2013-01-17 17:02:15Z vranyj1 $'
19723298dd2c Bugfix: reading of Java class extensions methods.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
   299
!
19723298dd2c Bugfix: reading of Java class extensions methods.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
   300
19723298dd2c Bugfix: reading of Java class extensions methods.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
   301
version_HG
19723298dd2c Bugfix: reading of Java class extensions methods.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
   302
19723298dd2c Bugfix: reading of Java class extensions methods.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
   303
    ^ '$Changeset: <not expanded> $'
3012
4f40b8304d54 Added InvalidChange
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3011
diff changeset
   304
!
4f40b8304d54 Added InvalidChange
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3011
diff changeset
   305
2880
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   306
version_SVN
0072cabff85a Merged from SVN
vrany
parents: 2643
diff changeset
   307
    ^ '§Id: ChangeSetDiffComponent.st 1920 2012-04-18 20:21:56Z vranyj1 §'
2406
cf06c39b234c initial checkin
vrany
parents:
diff changeset
   308
! !
3121
19723298dd2c Bugfix: reading of Java class extensions methods.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3099
diff changeset
   309