[go: up one dir, main page]

Menu

[r303]: / libpetey / vector_s.h  Maximize  Restore  History

Download this file

37 lines (26 with data), 757 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#ifndef VECTOR_S_H
#define VECTOR_S_H 1
#include "petey_pointer.h"
namespace libpetey {
//sortable vector class
//a vector class, designed for (at the moment) removing duplicates
//within a list through sorting...
template <class type>
class vector_s {
protected:
public:
int nel;
petey_pointer<type *> data;
vector_s(int n);
vector_s(type *dt, int n, int ncp_flag=0);
vector_s(type **dt, int n);
~vector_s();
type & operator [] (int ind);
int operator == (vector_s<type> &other);
int operator > (vector_s<type> &other);
int operator < (vector_s<type> &other);
int operator >= (vector_s<type> &other);
int operator <= (vector_s<type> &other);
};
}
#endif