Back: Class-testing functionality Up: Base classes Forward: ClassDescription-compiling   Top: GNU Smalltalk Library Reference Contents: Table of Contents Index: Class index About: About this document

1.32 ClassDescription

Defined in namespace Smalltalk
Superclass: Behavior
Category: Language-Implementation
My instances provide methods that access classes by category, and allow whole categories of classes to be filed out to external disk files.

1.32.1 ClassDescription: compiling  (instance)
1.32.2 ClassDescription: conversion  (instance)
1.32.3 ClassDescription: copying  (instance)
1.32.4 ClassDescription: filing  (instance)
1.32.5 ClassDescription: organization of messages and classes  (instance)
1.32.6 ClassDescription: parsing class declarations  (instance)
1.32.7 ClassDescription: printing  (instance)
1.32.8 ClassDescription: still unclassified  (instance)


1.32.1 ClassDescription: compiling

compile: code classified: categoryName
Compile code in the receiver, assigning the method to the given category. Answer the newly created CompiledMethod, or nil if an error was found.

compile: code classified: categoryName ifError: block
Compile method source and install in method category, categoryName. If there are parsing errors, invoke exception block, 'block' (see compile:ifError:). Return the method

compile: code classified: categoryName notifying: requestor
Compile method source and install in method category, categoryName. If there are parsing errors, send an error message to requestor


1.32.2 ClassDescription: conversion

asClass
This method's functionality should be implemented by subclasses of ClassDescription

asMetaclass
Answer the metaclass associated to the receiver

binding
Answer a VariableBinding object whose value is the receiver


1.32.3 ClassDescription: copying

copy: selector from: aClass
Copy the given selector from aClass, assigning it the same category

copy: selector from: aClass classified: categoryName
Copy the given selector from aClass, assigning it the given category

copyAll: arrayOfSelectors from: class
Copy all the selectors in arrayOfSelectors from class, assigning them the same category they have in class

copyAll: arrayOfSelectors from: class classified: categoryName
Copy all the selectors in arrayOfSelectors from aClass, assigning them the given category

copyAllCategoriesFrom: aClass
Copy all the selectors in aClass, assigning them the original category

copyCategory: categoryName from: aClass
Copy all the selectors in from aClass that belong to the given category

copyCategory: categoryName from: aClass classified: newCategoryName
Copy all the selectors in from aClass that belong to the given category, reclassifying them as belonging to the given category


1.32.4 ClassDescription: filing

fileOut: fileName
Open the given file and to file out a complete class description to it. Requires package Parser.

fileOutCategory: categoryName to: fileName
File out all the methods belonging to the method category, categoryName, to the fileName file. Requires package Parser.

fileOutOn: aFileStream
File out complete class description: class definition, class and instance methods. Requires package Parser.

fileOutSelector: selector to: fileName
File out the given selector to fileName. Requires package Parser.


1.32.5 ClassDescription: organization of messages and classes

classify: aSelector under: aString
Put the method identified by the selector aSelector under the category given by aString.

createGetMethod: what
Create a method accessing the variable `what'.

createGetMethod: what default: value
Create a method accessing the variable `what', with a default value of `value', using lazy initialization

createSetMethod: what
Create a method which sets the variable `what'.

defineAsyncCFunc: cFuncNameString withSelectorArgs: selectorAndArgs args: argsArray
See documentation. This function is deprecated, you should use the <asyncCCall: ... > special syntax instead.

defineCFunc: cFuncNameString withSelectorArgs: selectorAndArgs returning: returnTypeSymbol args: argsArray
See documentation. This function is deprecated, you should use the <asyncCCall: ... > special syntax instead.

removeCategory: aString
Remove from the receiver every method belonging to the given category

whichCategoryIncludesSelector: selector
Answer the category for the given selector, or nil if the selector is not found


1.32.6 ClassDescription: parsing class declarations

addSharedPool: aDictionary
Add the given shared pool to the list of the class' pool dictionaries

import: aDictionary
Add the given shared pool to the list of the class' pool dictionaries


1.32.7 ClassDescription: printing

classVariableString
This method's functionality should be implemented by subclasses of ClassDescription

instanceVariableString
Answer a string containing the name of the receiver's instance variables.

nameIn: aNamespace
Answer the class name when the class is referenced from aNamespace

printOn: aStream in: aNamespace
Print on aStream the class name when the class is referenced from aNamespace

sharedVariableString
This method's functionality should be implemented by subclasses of ClassDescription


1.32.8 ClassDescription: still unclassified

fileOutCategory: category toStream: aFileStream
File out all the methods belonging to the method category, category, to aFileStream. Requires package Parser.

fileOutSelector: aSymbol toStream: aFileStream
File out all the methods belonging to the method category, category, to aFileStream. Requires package Parser.



Back: ClassDescription-printing Up: ClassDescription Forward: CLong   Top: GNU Smalltalk Library Reference Contents: Table of Contents Index: Class index About: About this document


This document was generated on July, 23 2009 using texi2html