ReadStream.st
changeset 15583 891cdc8bd093
parent 15582 11a8428d9a10
child 15638 42d68430a684
child 18079 7b5afc0ad3d5
--- a/ReadStream.st	Tue Jul 30 20:59:59 2013 +0200
+++ b/ReadStream.st	Tue Jul 30 21:02:48 2013 +0200
@@ -124,6 +124,15 @@
 
 !ReadStream methodsFor:'queries'!
 
+collectionSize
+    "return the overall number of elements in the streamed collection   
+     (both already read and to be read)."
+
+    ^ collection size
+
+    "Created: / 30-07-2013 / 20:55:51 / cg"
+!
+
 copyFrom:beginning to:end
     ^ collection copyFrom:beginning to:end
 !
@@ -155,7 +164,11 @@
 size
     "return the number of remaining elements in the streamed collection."
 
-    ^ collection size - position
+    "/ will change back soon for VW and Squeak compatibility.
+    "/ ^ self collectionSize.
+    ^  self remainingSize
+
+    "Modified (comment): / 30-07-2013 / 20:57:23 / cg"
 ! !
 
 !ReadStream methodsFor:'reading'!
@@ -855,10 +868,10 @@
 !ReadStream class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic/ReadStream.st,v 1.70 2013-07-30 18:59:59 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/ReadStream.st,v 1.71 2013-07-30 19:02:48 cg Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libbasic/ReadStream.st,v 1.70 2013-07-30 18:59:59 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/ReadStream.st,v 1.71 2013-07-30 19:02:48 cg Exp $'
 ! !