[ENH] Array2D
Michael Rueger
Michael.Rueger.-ND at disney.com
Wed Mar 1 22:56:57 UTC 2000
Change Set: Array2D-mir
Date: 1 March 2000
Author: Michael Rueger
Adds some convenience methods to Array2D.
--
"To improve is to change, to be perfect is to change often."
Winston Churchill
+------------------------------------------------------------+
| Michael Rueger |
| Phone: ++1 (818) 623 3283 Fax: ++1 (818) 623 3559 |
+---------- Michael.Rueger.-ND at corp.go.com ------------------+
-------------- next part --------------
"Change Set: Array2D-mir
Date: 1 March 2000
Author: Michael Rueger
Adds some convenience methods to Array2D.
"!
!Array2D methodsFor: 'enumerating' stamp: 'mir 2/14/2000 12:42'!
rowAndColumnValuesDo: aBlock
1 to: self width do: [:col |
1 to: self height do: [:row |
aBlock value: row value: col value: (self at: row at: col)]]! !
!Array2D methodsFor: 'enumerating' stamp: 'mir 2/14/2000 12:41'!
rowsAndColumnsDo: aBlock
1 to: self width do: [:col |
1 to: self height do: [:row |
aBlock value: row value: col]]! !
!Array2D class reorganize!
('instance creation' extent: new new:)
!
!Array2D class methodsFor: 'instance creation' stamp: 'mir 2/14/2000 12:34'!
extent: aPoint
^self new width: aPoint x height: aPoint y type: Array! !
More information about the Squeak-dev
mailing list
|