Class.st
changeset 8075 819735e0ca47
parent 8072 e7542f2dbb9c
child 8085 b1ce10168352
equal deleted inserted replaced
8074:4dce05d6d0a1 8075:819735e0ca47
     1 "{ Encoding: utf8 }"
       
     2 
       
     3 "
     1 "
     4  COPYRIGHT (c) 1989 by Claus Gittinger
     2  COPYRIGHT (c) 1989 by Claus Gittinger
     5 	       All Rights Reserved
     3 	       All Rights Reserved
     6 
     4 
     7  This software is furnished under a license and may be used
     5  This software is furnished under a license and may be used
   255 ! !
   253 ! !
   256 
   254 
   257 !Class class methodsFor:'queries'!
   255 !Class class methodsFor:'queries'!
   258 
   256 
   259 defaultExternalEncoding
   257 defaultExternalEncoding
   260     "/ ^ nil    "/ for backward compatibility
   258     ^ nil    "/ for backward compatibility
   261     ^ #'utf-8'
   259     "/ ^ #'utf-8'
   262 !
   260 !
   263 
   261 
   264 isBuiltInClass
   262 isBuiltInClass
   265     "return true if this class is known by the run-time-system.
   263     "return true if this class is known by the run-time-system.
   266      Here, true is returned for myself, false for subclasses."
   264      Here, true is returned for myself, false for subclasses."
  2510      If initIt is true, and the class implements a class-initialize method,
  2508      If initIt is true, and the class implements a class-initialize method,
  2511      append a corresponding doIt expression for initialization.
  2509      append a corresponding doIt expression for initialization.
  2512      The order by which the fileOut is done is used to put the version string at the end.
  2510      The order by which the fileOut is done is used to put the version string at the end.
  2513      Thus, if the version string is expanded (by CVS), the characterPositions of methods should not move"
  2511      Thus, if the version string is expanded (by CVS), the characterPositions of methods should not move"
  2514 
  2512 
       
  2513     |encoding encoder|
       
  2514 
       
  2515     encoding := Class defaultExternalEncoding.
       
  2516     encoding notNil ifTrue:[
       
  2517         encoder := CharacterEncoder encoderFor:encoding
       
  2518     ].
  2515     ^ self
  2519     ^ self
  2516         fileOutOn:aStream 
  2520         fileOutOn:aStream 
  2517         withTimeStamp:stampIt 
  2521         withTimeStamp:stampIt 
  2518         withInitialize:initIt 
  2522         withInitialize:initIt 
  2519         withDefinition:withDefinition 
  2523         withDefinition:withDefinition 
  2520         methodFilter:methodFilter 
  2524         methodFilter:methodFilter 
  2521         encoder:(CharacterEncoder encoderFor:(Class defaultExternalEncoding))
  2525         encoder:encoder
  2522 !
  2526 !
  2523 
  2527 
  2524 fileOutOn:outStreamArg withTimeStamp:stampIt withInitialize:initIt withDefinition:withDefinition methodFilter:methodFilter encoder:encoderOrNil
  2528 fileOutOn:outStreamArg withTimeStamp:stampIt withInitialize:initIt withDefinition:withDefinition methodFilter:methodFilter encoder:encoderOrNil
  2525     "file out my definition and all methods onto aStream.
  2529     "file out my definition and all methods onto aStream.
  2526      If stampIt is true, a timeStamp comment is prepended.
  2530      If stampIt is true, a timeStamp comment is prepended.
  4856 ! !
  4860 ! !
  4857 
  4861 
  4858 !Class class methodsFor:'documentation'!
  4862 !Class class methodsFor:'documentation'!
  4859 
  4863 
  4860 version
  4864 version
  4861     ^ '$Header: /cvs/stx/stx/libbasic/Class.st,v 1.456 2004-03-04 19:03:03 cg Exp $'
  4865     ^ '$Header: /cvs/stx/stx/libbasic/Class.st,v 1.457 2004-03-04 20:01:41 cg Exp $'
  4862 ! !
  4866 ! !