eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'JavaScriptMetaclass':



Class: JavaScriptMetaclass



rev: 1.24 date: 2019/06/27 10:42:22
user: cg
file: JavaScriptMetaclass.st directory: libjavascript
module: stx stc-classLibrary: libjavascript

Class protocol:

class creation
o  classTemplateFor: aSuperClass in: categoryString asNamespace: asNameSpace private: isPrivateWanted
(comment from inherited method)
returning nil here, will let the browser generate a template.
However, special metaclasses (other languages)
may redefine this

creating classes
o  new
creating a new metaclass - have to set the new classes
flags correctly to have it behave like a metaclass ...
Not for normal applications - creating new metaclasses is a very
tricky thing; should be left to the gurus ;-)

Instance protocol:

compiler interface
o  programmingLanguage
me myself, I am written in Smalltalk !

o  realSubclassDefinerClass

o  subclassDefinerClass

o  basicFileOutDefinitionOf: aClass on: aStream withNameSpace: forceNameSpace withPackage: showPackage
append an expression on aStream, which defines myself.

o  fileOutAllDefinitionsOn: aStream
append expressions on aStream, which defines myself and all of my private classes.

o  fileOutClassInstVarDefinitionOn: aStream withNameSpace: withNameSpace

o  fileOutOn: outStreamArg withTimeStamp: stampIt withInitialize: initIt withDefinition: withDefinition methodFilter: methodFilter encoder: encoderOrNil
file out my definition and all methods onto aStream.
If stampIt is true, a timeStamp comment is prepended.
If initIt is true, and the class implements a class-initialize method,
append a corresponding doIt expression for initialization.
The order by which the fileOut is done is used to put the version string at the end.
Thus, if the version string is expanded (by CVS), the characterPositions of methods should not move

o  isJavaScriptMetaclass

o  nameInBrowser
return a nameString as shown in browsers

source management
o  sourceFileSuffix
Answers a default suffix for source files, i.e.
'st' for Smalltalk, 'js' for JavaScript or 'rb' for Ruby', etc.

ui support
o  iconInBrowserSymbol
(comment from inherited method)
can be redefined for a private icon in the browser.
The returned symbol must be a selector of the ToolbarIconLibrary.

ST/X; WebServer 1.670 at bd0aa1f87cdd.unknown:8081; Tue, 17 May 2022 20:52:41 GMT