Unicode16String.st
author Claus Gittinger <cg@exept.de>
Wed, 03 Mar 2004 21:48:29 +0100
changeset 8049 ccd0e8f26439
parent 7982 0412a26c4621
child 8294 ba5f4421848f
permissions -rw-r--r--
printing - migrating towards unicodeSupport in ST-code

"{ Encoding: iso8859-1 }"

"
 COPYRIGHT (c) 1997 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:libbasic2' }"

TwoByteString variableWordSubclass:#Unicode16String
	instanceVariableNames:''
	classVariableNames:''
	poolDictionaries:''
	category:'Collections-Text'
!

!Unicode16String class methodsFor:'documentation'!

copyright
"
 COPYRIGHT (c) 1997 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
"
    Not yet finished - unicode support is currently being implemented.
"
! !

!Unicode16String class methodsFor:'initialization'!

initialize
    "initialize the class - private"

    self flags:(Behavior flagWords).

    Smalltalk at:#UnicodeString put:Unicode16String.

    "
     Unicode16String initialize
    "

    "Created: 30.6.1997 / 15:35:52 / cg"
    "Modified: 30.6.1997 / 15:39:21 / cg"
! !

!Unicode16String methodsFor:'conversion'!

asSymbolIfInterned
    |s|

    Error catch:[
        s := self asSingleByteString.
    ].
    s isNil ifTrue:[^ s].
    ^ s asSymbolIfInterned
!

asUnicodeString
    ^ self
!

printOn:aStream
    self utf8EncodedOn:aStream
! !

!Unicode16String methodsFor:'printing & storing'!

storeString
    "return a String for storing myself"

    ^ self basicStoreString.
! !

!Unicode16String class methodsFor:'documentation'!

version
    ^ '$Header: /cvs/stx/stx/libbasic/Unicode16String.st,v 1.4 2004-03-03 20:48:29 cg Exp $'
! !

Unicode16String initialize!