spielwiese
Last change
on this file since 8c0163 was
8c0163,
checked in by Jens Schmidt <schmidt@…>, 26 years ago
|
#include <config.h> added
the header config.h will be included be makeheader
git-svn-id: file:///usr/local/Singular/svn/trunk@161 2c84dea3-7e68-4137-9b89-c4e89433aadc
|
-
Property mode set to
100644
|
File size:
1.2 KB
|
Line | |
---|
1 | // emacs edit mode for this file is -*- C++ -*- |
---|
2 | // $Id: ftmpl_array.h,v 1.3 1997-04-15 10:04:24 schmidt Exp $ |
---|
3 | |
---|
4 | #ifndef INCL_ARRAY_H |
---|
5 | #define INCL_ARRAY_H |
---|
6 | |
---|
7 | /* |
---|
8 | $Log: not supported by cvs2svn $ |
---|
9 | Revision 1.2 1997/03/27 10:29:30 schmidt |
---|
10 | stream-io wrapped by NOSTREAMIO |
---|
11 | |
---|
12 | Revision 1.1 1996/07/16 12:24:57 stobbe |
---|
13 | "operators += and *= deleted sincethey are not needed in an general |
---|
14 | array class als well as the functions sum, prod, crossprod. |
---|
15 | " |
---|
16 | |
---|
17 | Revision 1.0 1996/05/17 11:06:32 stobbe |
---|
18 | Initial revision |
---|
19 | |
---|
20 | */ |
---|
21 | |
---|
22 | /*MAKEHEADER*/ |
---|
23 | #include "templates/config.h" |
---|
24 | |
---|
25 | #ifndef NOSTREAMIO |
---|
26 | #include <iostream.h> |
---|
27 | #endif /* NOSTREAMIO */ |
---|
28 | |
---|
29 | template <class T> |
---|
30 | class Array { |
---|
31 | private: |
---|
32 | T * data; |
---|
33 | int _min; |
---|
34 | int _max; |
---|
35 | int _size; |
---|
36 | public: |
---|
37 | Array(); |
---|
38 | Array( const Array<T>& ); |
---|
39 | Array( int size ); |
---|
40 | Array( int min, int max ); |
---|
41 | ~Array(); |
---|
42 | Array<T>& operator= ( const Array<T>& ); |
---|
43 | T& operator[] ( int i ) const; |
---|
44 | int size() const; |
---|
45 | int min() const; |
---|
46 | int max() const; |
---|
47 | #ifndef NOSTREAMIO |
---|
48 | void print ( ostream& ) const; |
---|
49 | #endif /* NOSTREAMIO */ |
---|
50 | }; |
---|
51 | |
---|
52 | #ifndef NOSTREAMIO |
---|
53 | template <class T> |
---|
54 | ostream& operator<< ( ostream & os, const Array<T> & a ); |
---|
55 | #endif /* NOSTREAMIO */ |
---|
56 | |
---|
57 | #endif /* INCL_ARRAY_H */ |
---|
Note: See
TracBrowser
for help on using the repository browser.