BIG5EncodedString.st
author Claus Gittinger <cg@exept.de>
Sat, 27 Apr 1996 13:24:41 +0200
changeset 264 1e508408ecf5
parent 261 2fd450dd712f
child 265 6024db111b9d
permissions -rw-r--r--
commentary
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
229
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     1
TwoByteString subclass:#BIG5EncodedString
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     2
	instanceVariableNames:''
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     3
	classVariableNames:''
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     4
	poolDictionaries:''
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     5
	category:'Collections-Text'
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     6
!
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     7
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     8
!BIG5EncodedString class methodsFor:'documentation'!
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     9
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    10
documentation
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    11
"
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    12
    BIG5EncodedString represents 16bit strings encoded in BIG-5.
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    13
    BIG-5 is a popular hanzi code used in Taiwan.
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    14
    Most of you are probably not interrested in those ...
261
2fd450dd712f commentary
Claus Gittinger <cg@exept.de>
parents: 260
diff changeset
    15
2fd450dd712f commentary
Claus Gittinger <cg@exept.de>
parents: 260
diff changeset
    16
    [author:]
2fd450dd712f commentary
Claus Gittinger <cg@exept.de>
parents: 260
diff changeset
    17
        Claus Gittinger
2fd450dd712f commentary
Claus Gittinger <cg@exept.de>
parents: 260
diff changeset
    18
2fd450dd712f commentary
Claus Gittinger <cg@exept.de>
parents: 260
diff changeset
    19
    [see also:]
2fd450dd712f commentary
Claus Gittinger <cg@exept.de>
parents: 260
diff changeset
    20
        GBEncodedString JISEncodedString 
2fd450dd712f commentary
Claus Gittinger <cg@exept.de>
parents: 260
diff changeset
    21
        TwoByteString String CharacterArray
2fd450dd712f commentary
Claus Gittinger <cg@exept.de>
parents: 260
diff changeset
    22
        StringCollection
229
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    23
"
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    24
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    25
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    26
! !
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    27
260
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    28
!BIG5EncodedString class methodsFor:'initialization'!
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    29
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    30
initialize
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    31
    "initialize the class - private"
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    32
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    33
    self flags:(Behavior flagWords)
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    34
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    35
    "
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    36
     BIG5EncodedString initialize
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    37
    "
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    38
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    39
    "Created: 27.4.1996 / 13:12:30 / cg"
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    40
! !
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
    41
231
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    42
!BIG5EncodedString class methodsFor:'code tables'!
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    43
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    44
romanBIG5DecoderTable
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    45
    "return a table to decode from roman ascii to 16 bit BIG5.
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    46
     This is an experimental interface - unfinished"
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    47
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    48
    ^ #(           "excla"          " # "   " $ "   " % "   " & "   " ' "
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    49
                  16ra149 16ra1b2 16ra1ad 16ra243 16ra248 16ra1ae 16ra1ac 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    50
            " ( "   " ) "   " * "   " + "   " , "   " - "   " . "   " / "
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    51
          16ra15d 16ra15e 16ra1ce 16ra1cf 16ra14d 16ra1df 16ra14f 16ra1fe
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    52
            " 0 "   " 1 "   " 2 "   " 3 "   " 4 "   " 5 "   " 6 "   " 7 "
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    53
          16ra2af 16ra2b0 16ra2b1 16ra2b2 16ra2b3 16ra2b4 16ra2b5 16ra2b6
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    54
            " 8 "   " 9 "   " : "   " ; "   " < "   " = "   " > "   " ? "
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    55
          16ra2b7 16ra2b8 16ra152 16ra151 16ra1e0 16ra1e2 16ra1e1 16ra148 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    56
            " @ "   " A "   " B "   " C "   " D "   " E "   " F "   " G "
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    57
          16ra249 16ra2cf 16ra2d0 16ra2d1 16ra2d2 16ra2d3 16ra2d4 16ra2d5 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    58
            " H "   " I "   " J "   " K "   " L "   " M "   " N "   " O "
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    59
          16ra2d6 16ra2d7 16ra2d8 16ra2d9 16ra2da 16ra2db 16ra2dc 16ra2dd 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    60
            " P "   " Q "   " R "   " S "   " T "   " U "   " V "   " W "
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    61
          16ra2de 16ra2df 16ra2e0 16ra2e1 16ra2e2 16ra2e3 16ra2e4 16ra2e5 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    62
            " X "   " Y "   " Z "   " [ "   " \ "   " ] "   " ^ "   " _ "
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    63
          16ra2e6 16ra2e7 16ra2e8 16ra169 16ra242 16ra16a 16ra173 16ra15a
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    64
            " ` "   " a "   " b "   " c "   " d "   " e "   " f "   " g "
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    65
          16ra1ab 16ra2e9 16ra2ea 16ra2eb 16ra2ec 16ra2ed 16ra2ee 16ra2ef 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    66
            " h "   " i "   " j "   " k "   " l "   " m "   " n "   " o "
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    67
          16ra2f0 16ra2f1 16ra2f2 16ra2f3 16ra2f4 16ra2f5 16ra2f6 16ra2f7 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    68
            " p "   " q "   " r "   " s "   " t "   " u "   " v "   " w "
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    69
          16ra2f8 16ra2f9 16ra2fa 16ra2fb 16ra2fc 16ra2fd 16ra2fe 16ra340 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    70
            " x "   " y "   " z "   " { "   " | "   " } "  " ~ "
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    71
          16ra341 16ra342 16ra343 16ra161 16ra157 16ra162 16ra1e3 16ra1bd
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    72
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    73
          16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    74
          16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    75
          16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    76
          16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    77
          16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    78
          16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    79
          16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    80
          16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc 16ra1bc ).
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    81
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    82
    "Modified: 17.4.1996 / 18:16:41 / cg"
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    83
    "Created: 17.4.1996 / 18:55:54 / cg"
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    84
! !
5d28780c8859 code table moved to BIG5EncodedString
Claus Gittinger <cg@exept.de>
parents: 229
diff changeset
    85
229
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    86
!BIG5EncodedString methodsFor:'queries'!
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    87
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    88
encoding
264
1e508408ecf5 commentary
Claus Gittinger <cg@exept.de>
parents: 261
diff changeset
    89
    "return the strings encoding as a symbol. 
1e508408ecf5 commentary
Claus Gittinger <cg@exept.de>
parents: 261
diff changeset
    90
     Here, the constant symbol #big5 is returned."
240
7af04274190d commentary
Claus Gittinger <cg@exept.de>
parents: 231
diff changeset
    91
229
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    92
    ^ #big5
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    93
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    94
    "Created: 17.4.1996 / 15:41:15 / cg"
264
1e508408ecf5 commentary
Claus Gittinger <cg@exept.de>
parents: 261
diff changeset
    95
    "Modified: 27.4.1996 / 13:23:01 / cg"
229
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    96
! !
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    97
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    98
!BIG5EncodedString class methodsFor:'documentation'!
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    99
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   100
version
264
1e508408ecf5 commentary
Claus Gittinger <cg@exept.de>
parents: 261
diff changeset
   101
    ^ '$Header: /cvs/stx/stx/libbasic2/BIG5EncodedString.st,v 1.6 1996-04-27 11:24:36 cg Exp $'
229
3b126b43392b intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   102
! !
260
427397326fac need explicit #initialize (due to startup optimization)
Claus Gittinger <cg@exept.de>
parents: 240
diff changeset
   103
BIG5EncodedString initialize!