Initial
This commit is contained in:
51
mdiwin/VECTOR.HPP
Normal file
51
mdiwin/VECTOR.HPP
Normal file
@@ -0,0 +1,51 @@
|
||||
#ifndef _VECTOR_HPP_
|
||||
#define _VECTOR_HPP_
|
||||
#include <dos.h>
|
||||
#include <assert.h>
|
||||
#include <memory.h>
|
||||
#include <mdiwin/windows.hpp>
|
||||
#include <mdiwin/types.hpp>
|
||||
#include <mdiwin/block.hpp>
|
||||
|
||||
#ifndef HUGE
|
||||
#ifdef __FLAT__
|
||||
#define HUGE FAR
|
||||
#else
|
||||
#define HUGE huge
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef _EXPAND_VECTOR_TEMPLATES_
|
||||
//#pragma option -Jgd
|
||||
#endif
|
||||
|
||||
#if defined(_MSC_VER)
|
||||
#pragma warning(disable:4291)
|
||||
#endif
|
||||
|
||||
void FAR *operator new(size_t size,int n,void FAR*lpData);
|
||||
|
||||
template <class T>
|
||||
class Vector
|
||||
{
|
||||
public:
|
||||
Vector(void);
|
||||
virtual ~Vector();
|
||||
LONG size(LONG newSize);
|
||||
LONG size(void)const;
|
||||
T &operator[](LONG itemIndex);
|
||||
WORD operator=(Block<T> &someBlock);
|
||||
WORD operator==(const Vector<T> &someVector)const;
|
||||
WORD operator=(const Vector<T> &someVector);
|
||||
// operator T*();
|
||||
private:
|
||||
typedef LONG Index;
|
||||
void vectorNew(void);
|
||||
void vectorDelete(void);
|
||||
|
||||
LONG mEntries;
|
||||
T HUGE * HUGE *mlpVectorTable;
|
||||
T HUGE *mlpMemPool;
|
||||
};
|
||||
#include <mdiwin/vector.tpp>
|
||||
#endif
|
||||
Reference in New Issue
Block a user