ClassCategoryChange.st
author Claus Gittinger <cg@exept.de>
Tue, 22 Jan 2008 23:31:03 +0100
changeset 1984 e24fdc626215
parent 1177 91756124439b
child 2166 c133e744f529
permissions -rw-r--r--
copyright
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1984
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
     1
"
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
     2
 COPYRIGHT (c) 2002 by eXept Software AG
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
     3
              All Rights Reserved
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
     4
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
     5
 This software is furnished under a license and may be used
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
     6
 only in accordance with the terms of that license and with the
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
     8
 be provided or otherwise made available to, or used by, any
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
     9
 other person.  No title to or ownership of the software is
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    10
 hereby transferred.
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    11
"
1177
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    12
"{ Package: 'stx:libbasic3' }"
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    13
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    14
ClassChange subclass:#ClassCategoryChange
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    15
	instanceVariableNames:'category'
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    16
	classVariableNames:''
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    17
	poolDictionaries:''
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    18
	category:'System-Changes'
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    19
!
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    20
1984
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    21
!ClassCategoryChange class methodsFor:'documentation'!
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    22
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    23
copyright
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    24
"
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    25
 COPYRIGHT (c) 2002 by eXept Software AG
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    26
              All Rights Reserved
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    27
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    28
 This software is furnished under a license and may be used
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    29
 only in accordance with the terms of that license and with the
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    30
 inclusion of the above copyright notice.   This software may not
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    31
 be provided or otherwise made available to, or used by, any
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    32
 other person.  No title to or ownership of the software is
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    33
 hereby transferred.
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    34
"
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
    35
! !
1177
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    36
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    37
!ClassCategoryChange methodsFor:'accessing'!
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    38
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    39
category
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    40
    ^ category
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    41
!
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    42
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    43
category:aCategory
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    44
    ^ category := aCategory
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    45
!
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    46
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    47
className:clsName category:aCategoryString
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    48
    className := clsName.
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    49
    category := aCategoryString
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    50
! !
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    51
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    52
!ClassCategoryChange methodsFor:'comparing'!
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    53
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    54
isForSameAs:changeB
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    55
    "return true, if the given change represents a change for the same
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    56
     thingy as the receiver (i.e. same method, same definition etc.)."
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    57
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    58
    changeB isClassCategoryChange ifFalse:[^ false].   
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    59
    ^ className = changeB className
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    60
!
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    61
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    62
sameAs:changeB
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    63
    "return true, if the given change represents the same change as the receiver."
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    64
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    65
    changeB isClassCategoryChange ifFalse:[^ false].
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    66
    className = changeB className ifFalse:[^ false].
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    67
    ^ category = changeB category 
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    68
!
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    69
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    70
source
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    71
    "synthesize the changes source"
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    72
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    73
    ^ className , ' category: ' , category storeString
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    74
! !
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    75
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    76
!ClassCategoryChange methodsFor:'printing & storing'!
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    77
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    78
printOn:aStream
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    79
    "append a user printed representation of the receiver to aStream.
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    80
     The format is suitable for a human - not meant to be read back."
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    81
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    82
    aStream nextPutAll:className; nextPutAll:' category:'
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    83
!
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    84
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    85
printWithoutClassNameOn:aStream
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    86
    (className endsWith:' class') ifTrue:[
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    87
        aStream nextPutAll:'class '
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    88
    ].
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    89
    aStream nextPutAll:'category:'
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    90
! !
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    91
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    92
!ClassCategoryChange methodsFor:'queries'!
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    93
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    94
isClassCategoryChange
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    95
    ^ true
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    96
! !
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    97
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    98
!ClassCategoryChange class methodsFor:'documentation'!
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    99
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   100
version
1984
e24fdc626215 copyright
Claus Gittinger <cg@exept.de>
parents: 1177
diff changeset
   101
    ^ '$Header: /cvs/stx/stx/libbasic3/ClassCategoryChange.st,v 1.2 2008-01-22 22:31:03 cg Exp $'
1177
91756124439b initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   102
! !