|
Last change
on this file was
2,
checked in by oldcode, 25 years ago
|
|
Initial revision
|
-
Property svn:eol-style set to
native
-
Property svn:keywords set to
Author Date Id Revision
|
|
File size:
1.3 KB
|
| Line | |
|---|
| 1 | // ----------------------------------------------------------------------------- |
|---|
| 2 | |
|---|
| 3 | #ifndef _A3_MATRIX_HXX |
|---|
| 4 | #define _A3_MATRIX_HXX |
|---|
| 5 | |
|---|
| 6 | // ----------------------------------------------------------------------------- |
|---|
| 7 | // Include-Dateien |
|---|
| 8 | // ----------------------------------------------------------------------------- |
|---|
| 9 | |
|---|
| 10 | #include "a3_darray.hxx" |
|---|
| 11 | |
|---|
| 12 | // ----------------------------------------------------------------------------- |
|---|
| 13 | // Datentypen |
|---|
| 14 | // ----------------------------------------------------------------------------- |
|---|
| 15 | |
|---|
| 16 | class A3Matrix // Matrix fuer beliebige Elemente |
|---|
| 17 | { |
|---|
| 18 | private: |
|---|
| 19 | |
|---|
| 20 | int width, // Spalten der Matrix |
|---|
| 21 | height, // Zeilen der Matrix |
|---|
| 22 | free; // Sollen Elemente explizit mit delete freigegeben werden |
|---|
| 23 | vp *matrix; // Eigentliche Matrix |
|---|
| 24 | |
|---|
| 25 | void Init ( int xlen, |
|---|
| 26 | int ylen, |
|---|
| 27 | int del ); |
|---|
| 28 | |
|---|
| 29 | public: |
|---|
| 30 | |
|---|
| 31 | A3Matrix ( int len, |
|---|
| 32 | int del ); |
|---|
| 33 | A3Matrix ( int xlen, |
|---|
| 34 | int ylen, |
|---|
| 35 | int del ); |
|---|
| 36 | A3Matrix ( A3Matrix &other ); |
|---|
| 37 | ~A3Matrix ( void ); |
|---|
| 38 | |
|---|
| 39 | int Set ( int xpos, |
|---|
| 40 | int ypos, |
|---|
| 41 | vp val ); |
|---|
| 42 | |
|---|
| 43 | vp Get ( int xpos, |
|---|
| 44 | int ypos ); |
|---|
| 45 | |
|---|
| 46 | void Clear ( void ); |
|---|
| 47 | |
|---|
| 48 | void Dump ( dumpfunc edump ); |
|---|
| 49 | }; |
|---|
| 50 | |
|---|
| 51 | // ----------------------------------------------------------------------------- |
|---|
| 52 | |
|---|
| 53 | #endif |
|---|
| 54 | |
|---|
| 55 | // ----------------------------------------------------------------------------- |
|---|
Note: See
TracBrowser
for help on using the repository browser.