CharacterEncoderImplementations__SingleByteEncoder.st
branchjv
changeset 17732 a1892eeca6c0
parent 17728 bbc5fa73dfab
child 17735 6a5bc05f696a
--- a/CharacterEncoderImplementations__SingleByteEncoder.st	Fri Aug 28 12:38:51 2009 +0100
+++ b/CharacterEncoderImplementations__SingleByteEncoder.st	Sat Oct 24 16:48:19 2009 +0100
@@ -9,7 +9,6 @@
  other person.  No title to or ownership of the software is
  hereby transferred.
 "
-
 "{ Package: 'stx:libbasic' }"
 
 "{ NameSpace: CharacterEncoderImplementations }"
@@ -62,8 +61,42 @@
     ^ String uninitializedNew:size
 ! !
 
+!SingleByteEncoder methodsFor:'queries'!
+
+characterSize:codePoint
+
+    ^1
+
+    "Created: / 15-06-2005 / 15:11:24 / janfrog"
+! !
+
+!SingleByteEncoder methodsFor:'stream support'!
+
+readNext:charactersToRead charactersFrom:stream
+
+    ^self decodeString:(stream next:charactersToRead)
+
+    "Created: / 16-06-2005 / 11:45:52 / masca"
+!
+
+readNextCharacterFrom:aStream
+
+    | c |
+
+    c := aStream next
+
+    ^ c isNil 
+        ifTrue: [nil]
+        ifFalse: [(self decode:c asInteger) asCharacter]
+
+    "Created: / 14-06-2005 / 17:03:21 / janfrog"
+    "Modified: / 15-06-2005 / 15:27:49 / janfrog"
+    "Modified: / 20-06-2005 / 13:13:52 / masca"
+! !
+
 !SingleByteEncoder class methodsFor:'documentation'!
 
 version
-    ^ '$Id: CharacterEncoderImplementations__SingleByteEncoder.st 10467 2009-08-19 16:14:36Z vranyj1 $'
+    ^ '$Id: CharacterEncoderImplementations__SingleByteEncoder.st 10473 2009-10-24 15:48:19Z vranyj1 $'
 ! !
+