[squeak-dev] The Trunk: Collections-pre.961.mcz

commits at source.squeak.org commits at source.squeak.org
Wed Nov 10 14:22:44 UTC 2021


Patrick Rein uploaded a new version of Collections to project The Trunk:
http://source.squeak.org/trunk/Collections-pre.961.mcz

==================== Summary ====================

Name: Collections-pre.961
Author: pre
Time: 10 November 2021, 3:22:38.585616 pm
UUID: f3d7c967-3623-5f4b-8166-59aeeeee1600
Ancestors: Collections-eem.960

Recategorizes unclassified or misclassified methods.

=============== Diff against Collections-eem.960 ===============

Item was changed:
+ ----- Method: Base64MimeConverter class>>decodeInteger: (in category 'convenience') -----
- ----- Method: Base64MimeConverter class>>decodeInteger: (in category 'as yet unclassified') -----
  decodeInteger: mimeString
  	| bytes sum |
  	"Decode the MIME string into an integer of any length"
  
  	bytes := (Base64MimeConverter mimeDecodeToBytes: 
  				(ReadStream on: mimeString)) contents.
  	sum := 0.
  	bytes reverseDo: [:by | sum := sum * 256 + by].
  	^ sum!

Item was changed:
+ ----- Method: Base64MimeConverter class>>encodeInteger: (in category 'convenience') -----
- ----- Method: Base64MimeConverter class>>encodeInteger: (in category 'as yet unclassified') -----
  encodeInteger: int
  	| strm |
  	"Encode an integer of any length and return the MIME string"
  
  	strm := WriteStream on: (ByteArray new: int digitLength).
  	1 to: int digitLength do: [:ii | strm nextPut: (int digitAt: ii)].
  	^ ((self mimeEncode: strm readStream) contents) copyUpTo: $=	"remove padding"!

Item was changed:
+ ----- Method: Base64MimeConverter class>>initialize (in category 'class initialization') -----
- ----- Method: Base64MimeConverter class>>initialize (in category 'as yet unclassified') -----
  initialize
  
  	FromCharTable := Array new: 256.	"nils"
  	ToCharTable := ($A to: $Z) , ($a to: $z) , ($0 to: $9) , '+/'.
  	ToCharTable keysAndValuesDo: [:ind :char |
  		FromCharTable at: char asciiValue + 1 put: ind - 1].!

Item was changed:
+ ----- Method: Base64MimeConverter class>>mimeDecodeToBytes: (in category 'convenience') -----
- ----- Method: Base64MimeConverter class>>mimeDecodeToBytes: (in category 'as yet unclassified') -----
  mimeDecodeToBytes: aStream 
  	"Return a ReadStream of the original ByteArray.  aStream has only 65 innocuous character values.  aStream is not binary.  (See class comment). 4 bytes in aStream goes to 3 bytes in output."
  
  	| me |
  	aStream position: 0.
  	me := self new mimeStream: aStream.
  	me dataStream: (WriteStream on: (ByteArray new: aStream size * 3 // 4)).
  	me mimeDecodeToByteArray.
  	^ me dataStream readStream!

Item was changed:
+ ----- Method: Base64MimeConverter class>>mimeDecodeToChars: (in category 'convenience') -----
- ----- Method: Base64MimeConverter class>>mimeDecodeToChars: (in category 'as yet unclassified') -----
  mimeDecodeToChars: aStream 
  	"Return a ReadWriteStream of the original String.  aStream has only 65 innocuous character values.  It is not binary.  (See class comment). 4 bytes in aStream goes to 3 bytes in output."
  
  	| me |
  	aStream position: 0.
  	me := self new mimeStream: aStream.
  	me dataStream: (WriteStream on: (String new: aStream size * 3 // 4)).
  	me mimeDecode.
  	^ me dataStream readStream!

Item was changed:
+ ----- Method: Base64MimeConverter class>>mimeEncode: (in category 'convenience') -----
- ----- Method: Base64MimeConverter class>>mimeEncode: (in category 'as yet unclassified') -----
  mimeEncode: aStream
  	"Return a ReadWriteStream of characters.  The data of aStream is encoded as 65 innocuous characters.  (See class comment). 3 bytes in aStream goes to 4 bytes in output."
  	^self mimeEncode: aStream multiLine: true atStart: true!

Item was changed:
+ ----- Method: Base64MimeConverter class>>mimeEncode:multiLine: (in category 'convenience') -----
- ----- Method: Base64MimeConverter class>>mimeEncode:multiLine: (in category 'as yet unclassified') -----
  mimeEncode: aStream multiLine: aBool
  	"Return a ReadWriteStream of characters.  The data of aStream is encoded as 65 innocuous characters.  (See class comment). 3 bytes in aStream goes to 4 bytes in output."
  
  	^self mimeEncode: aStream multiLine: aBool atStart: true!

Item was changed:
+ ----- Method: Base64MimeConverter class>>mimeEncode:multiLine:atStart: (in category 'private - convenience') -----
- ----- Method: Base64MimeConverter class>>mimeEncode:multiLine:atStart: (in category 'as yet unclassified') -----
  mimeEncode: aStream multiLine: aBool atStart: resetInput
  	"Return a ReadStream of characters.  The data of aStream is encoded as 65 innocuous characters.  (See class comment). 3 bytes in aStream goes to 4 bytes in output."
  
  	| me |
  	resetInput ifTrue:[aStream position: 0].
  	me := self new dataStream: aStream.
  	me multiLine: aBool.
  	me mimeStream: (WriteStream on: (String new: aStream size + 20 * 4 // 3)).
  	me mimeEncode.
  	^ me mimeStream readStream!

Item was changed:
+ ----- Method: Base64MimeConverter class>>mimeEncodeContinue: (in category 'private - convenience') -----
- ----- Method: Base64MimeConverter class>>mimeEncodeContinue: (in category 'as yet unclassified') -----
  mimeEncodeContinue: aStream
  	"Return a ReadWriteStream of characters.  The data of aStream is encoded as 65 innocuous characters.  (See class comment). 3 bytes in aStream goes to 4 bytes in output."
  	^self mimeEncode: aStream multiLine: true atStart: false!

Item was changed:
+ ----- Method: Bit7MimeConverter>>mimeDecode (in category 'conversion') -----
- ----- Method: Bit7MimeConverter>>mimeDecode (in category 'as yet unclassified') -----
  mimeDecode
  
  	dataStream nextPutAll: mimeStream upToEnd.
  	^ dataStream!

Item was changed:
+ ----- Method: Bit7MimeConverter>>mimeEncode (in category 'conversion') -----
- ----- Method: Bit7MimeConverter>>mimeEncode (in category 'as yet unclassified') -----
  mimeEncode
  
  	| character |
  	[dataStream atEnd] whileFalse: [
  		character := dataStream next.
  		self assert: character asciiValue < 128.
  		mimeStream nextPut: character].
  	
  	^ mimeStream!

Item was changed:
+ ----- Method: Generator class>>on: (in category 'instance creation') -----
- ----- Method: Generator class>>on: (in category 'instance-creation') -----
  on: aBlock
  	^ self basicNew initializeOn: aBlock!

Item was changed:
+ ----- Method: NullMimeConverter>>mimeDecode (in category 'conversion') -----
- ----- Method: NullMimeConverter>>mimeDecode (in category 'as yet unclassified') -----
  mimeDecode
  
  	dataStream nextPutAll: mimeStream upToEnd.
  	^ dataStream!

Item was changed:
+ ----- Method: NullMimeConverter>>mimeEncode (in category 'conversion') -----
- ----- Method: NullMimeConverter>>mimeEncode (in category 'as yet unclassified') -----
  mimeEncode
  
  	mimeStream nextPutAll: dataStream upToEnd.
  	^ mimeStream
  !

Item was changed:
+ ----- Method: QuotedPrintableMimeConverter>>encodeChar:to: (in category 'private - encoding') -----
- ----- Method: QuotedPrintableMimeConverter>>encodeChar:to: (in category 'as yet unclassified') -----
  encodeChar: aChar to: aStream
  
  	(self conversionNeededFor: aChar)
  			ifFalse: [aStream nextPut: aChar]
  			ifTrue: [aStream nextPut: $=;
  						nextPut: (Character digitValue: aChar asciiValue // 16);
  						nextPut: (Character digitValue: aChar asciiValue \\ 16)].
  			
  	
  !

Item was changed:
+ ----- Method: QuotedPrintableMimeConverter>>reservedCharacters (in category 'private - encoding') -----
- ----- Method: QuotedPrintableMimeConverter>>reservedCharacters (in category 'as yet unclassified') -----
  reservedCharacters
  
  	^ '=' !

Item was changed:
+ ----- Method: Stream>>sleep (in category 'file directory') -----
- ----- Method: Stream>>sleep (in category 'as yet unclassified') -----
  sleep
  
  	"an FTP-based stream might close the connection here"!



More information about the Squeak-dev mailing list