eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'ClassDefinitionChange':

Home

Documentation
www.exept.de
Everywhere
for:
[back]

Class: ClassDefinitionChange


Inheritance:

   Object
   |
   +--Change
      |
      +--ClassChange
         |
         +--ClassDefinitionChange

Package:
stx:libbasic3
Category:
System-Changes
Version:
rev: 1.115 date: 2024/02/29 13:37:34
user: cg
file: ClassDefinitionChange.st directory: libbasic3
module: stx stc-classLibrary: libbasic3

Description:


instances represent class definition-changes. 
They are typically held in a ChangeSet.

copyright

COPYRIGHT (c) 1993 by Claus Gittinger 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.

Instance protocol:

accessing
o  basicSuperClassName

o  category

o  category: aStringOrSymbol
Modified (format): / 30-06-2018 / 17:49:08 / Claus Gittinger

o  classInstanceVariableNames

o  classInstanceVariableNames: aCollectionOfWords

o  classInstanceVariableString

o  classInstanceVariableString: aString

o  classVariableNames

o  classVariableNames: aCollectionOfWords

o  classVariableString

o  classVariableString: aString

o  delta
Tools::TextDiff2Tool openOn: changeSource label: 'Change' and: imageSource label: 'Image'

o  deltaDetail
Returns a delta to the current state as a ChangeDelta object

o  imageSource
return the source for the in-image version of the method

o  indexedType

o  instanceVariableNames

o  instanceVariableNames: aCollectionOfWords

o  instanceVariableString

o  instanceVariableString: aString

o  localClassName
for private classes, this returns the name relative to its owner;
for non-private ones, this is the regular name.
Notice that className always returns the full name (incl. any owner prefix)

o  nameSpaceName
"/ JV: What is the following good for? Please explain..."

Usage example(s):

^ self cutNameSpaceOf:(self nameSpaceOverride ? super nameSpaceName)

o  nameSpaceName: aNameSpaceName classType: aClassType otherParameters: otherParametersArg
this instance setup message is used when reading from a VW-xml change file.
Support for this is not yet complete.

o  objectType
return the value of the instance variable 'objectType' (automatically generated)

o  objectType: something
set the value of the instance variable 'objectType' (automatically generated)

o  poolDictionaries

o  poolDictionaries: aStringWithPoolNames
Modified (format): / 30-06-2018 / 17:52:07 / Claus Gittinger

o  poolDictionaryNames: aCollectionOfPoolNames

o  private: aBoolean

o  source
return the source of the change;
either the original source or a synthesized

o  superClassName
returns nil, if no superclass.
Notice, that squeak returns the string 'nil' in this case;
so this might change in the future;
in the meantime, senders should be written to accept both nil and 'nil'

o  superClassName: aString

o  superClassNameWithoutMyNamespace

o  superClassNameWithoutNamespace

o  traitsUsed

o  traitsUsed: aCollectionOfTraitNames

applying
o  apply
Some classes have nil superclass (such as Object)...

Usage example(s):

      (ClassDefinitionChange className: #TestB source: 'TestA subclass: #TestB
          instanceVariableNames:''''
          classVariableNames:''''
          poolDictionaries:''''
          category:''* remove me *''')
          apply

comparing
o  isConflict
true if this change is different than what is already in the image
(i.e. it overwrites some existing code)

o  isForSameAs: changeB
return true, if the given change represents a change for the same
thingy as the receiver (i.e. same method, same definition etc.).

o  sameAs: changeB
return true, if the given change represents the same change as the receiver.

converting
o  asAntiChange
(comment from inherited method)
Returns my anti-change, i.e. change that does the
opposite. For class definition change it returns
class remove change, for method definition change
it returns method remove change. If there is no way
how to revert the change, an error is triggered.

JV: personal note: we should switch to deltastreams
(http://wiki.squeak.org/squeak/6001)

CG: is the above really true - what about a classDefChange for
an existing class????

printing & storing
o  definitionString
owningClassName isNil ifTrue:[

o  definitionStringInNamespace: nsOrNil
a visualWorks static variable definition change.

o  definitionStringWithoutNamespace
cg - huh - who needs that? (the definitionString already does NOT include the classes namespace)

o  printOn: aStream
(comment from inherited method)
append a user printed representation of the receiver to aStream.
The format is suitable for a human - not meant to be read back.

o  printWithoutClassNameOn: aStream

queries
o  definitionSelector

o  definitionSelector: aSelector

o  owningClassName
the owner's name, excluding the namespace

o  owningClassName: aStringOrSymbol

special
o  installAsAutoloadedClassIfPublicWithFilename: aFilenameString
install the class defined by this change as autoloaded.
Skip private classes.
Enter class file name as abbreviation

o  invalidateSource
internal - flush the sourceString if it got invalidated due to a
className, superclassName, etc... change

o  setupFromSource
Extract data from class definition string in source.
WARNING: This overwrites values in instvars!

testing
o  isClassDefinitionChange

o  isOrContainsClassDefinitionChange

o  isPrivateClassDefinitionChange
compute lazily; remember in private

o  isVariable
(comment from inherited method)
return true if the receiver has indexed instance variables,
false otherwise.

visiting
o  acceptChangeVisitor: aVisitor



ST/X 7.7.0.0; WebServer 1.702 at 20f6060372b9.unknown:8081; Mon, 30 Dec 2024 18:02:34 GMT