TraitDefinitionChange.st
author Claus Gittinger <cg@exept.de>
Fri, 13 Dec 2019 20:15:45 +0100
changeset 4525 04f4bfb1f1ee
parent 3452 281e887a36c9
child 3838 474d8ec95b33
permissions -rw-r--r--
#BUGFIX by cg class: ClassChange added: #source: comment/format in: #nameSpaceName changed: #changeClass: #class: #class:source: decompose className into namespace and base-class name

"
 COPYRIGHT (c) 2006 by eXept Software AG
              All Rights Reserved

 This software is furnished under a license and may be used
 only in accordance with the terms of that license and with the
 inclusion of the above copyright notice.   This software may not
 be provided or otherwise made available to, or used by, any
 other person.  No title to or ownership of the software is
 hereby transferred.
"
"{ Package: 'stx:libbasic3' }"

ClassChange subclass:#TraitDefinitionChange
	instanceVariableNames:'baseTrait traitComposition category'
	classVariableNames:''
	poolDictionaries:''
	category:'System-Changes'
!

!TraitDefinitionChange class methodsFor:'documentation'!

copyright
"
 COPYRIGHT (c) 2006 by eXept Software AG
              All Rights Reserved

 This software is furnished under a license and may be used
 only in accordance with the terms of that license and with the
 inclusion of the above copyright notice.   This software may not
 be provided or otherwise made available to, or used by, any
 other person.  No title to or ownership of the software is
 hereby transferred.
"
!

documentation
"
    instances represent trait changes.
    These are not present or supported (currently) in st/x, but may be encountered
    when reading a monticello package containing traits.
    Mostly experimental.
"
! !

!TraitDefinitionChange methodsFor:'accessing'!

baseTrait
    ^ baseTrait
!

baseTrait:something
    baseTrait := something.
!

category
    ^ category
!

category:something
    category := something.
!

source
    ^ String streamContents:[:s |
        s 
            nextPutAll: 'Trait named: ';
            nextPutAll: className; cr;
            nextPutAll: '    uses: '. 
        traitComposition isEmptyOrNil ifTrue:[
            s nextPutAll: '{}'. 
        ] ifFalse:[
            s nextPutAll: traitComposition. 
        ].
        s 
            cr; 
            nextPutAll: '    category: '.
        category asString storeOn:s.    
    ]
!

traitComposition
    ^ traitComposition
!

traitComposition:something
    traitComposition := something.
! !

!TraitDefinitionChange methodsFor:'printing & storing'!

printOn:aStream
    aStream nextPutAll:className; nextPutAll:' {trait definition}'

    "Modified: / 12-10-2006 / 17:48:28 / cg"
! !

!TraitDefinitionChange class methodsFor:'documentation'!

version
    ^ '$Header: /cvs/stx/stx/libbasic3/TraitDefinitionChange.st,v 1.3 2014-02-05 17:52:06 cg Exp $'
!

version_CVS
    ^ '$Header: /cvs/stx/stx/libbasic3/TraitDefinitionChange.st,v 1.3 2014-02-05 17:52:06 cg Exp $'
! !