P2Array

Holds a collection of Ponder2 objects. An array may be returned from sending a message to an object or or may be created in PonderTalk with the

 #( obj1 obj2 obj3) 
syntax.

Factory Messages
OperationDescription

Operational Messages
OperationReturnDescription
add: aP2Object self adds a aP2Object to the receiver. Answers the receiver
addAll: anArray self adds all objects in anArray to the receiver. Answers the receiver
asHash P2Hash Returns a Hash comprising of the array contents taken as key, value pairs
at: anIndex P2Object returns the object at anIndex
collect: aBlock P2Array for each entry in the array executes aBlock with the entry given as an argument to the block. Answers an array of answers built from each execution of the block.
do: aBlock self for each object in the array executes aBlock with the object given as an argument to the block. Answers the receiver