Next: , Up: ArrayedCollection   [Index]


1.5.1 ArrayedCollection class: instance creation

join: aCollection

Where aCollection is a collection of SequenceableCollections, answer a new instance with all the elements therein, in order.

join: aCollection separatedBy: sepCollection

Where aCollection is a collection of SequenceableCollections, answer a new instance with all the elements therein, in order, each separated by an occurrence of sepCollection.

new: size withAll: anObject

Answer a collection with the given size, whose elements are all set to anObject

streamContents: aBlock

Create a ReadWriteStream on an empty instance of the receiver; pass the stream to aBlock, then retrieve its contents and answer them.

with: element1

Answer a collection whose only element is element1

with: element1 with: element2

Answer a collection whose only elements are the parameters in the order they were passed

with: element1 with: element2 with: element3

Answer a collection whose only elements are the parameters in the order they were passed

with: element1 with: element2 with: element3 with: element4

Answer a collection whose only elements are the parameters in the order they were passed

with: element1 with: element2 with: element3 with: element4 with: element5

Answer a collection whose only elements are the parameters in the order they were passed

withAll: aCollection

Answer a collection whose elements are the same as those in aCollection