Right now i am trying to implement a vector class. However, i can't seem to get this to compile correctly. I can declare one in my main so I know the library exists, so what is going on here?
#ifndef _TABLE_HASH__
#define _TABLE_HASH__
#include <vector>
#include <iostream>
template <typename T>
class HashTable
{
public:
HashTable(int s);
bool inTable(T s);
void addEntry(T s);
bool retrieveEntry(T s);
int Collisions();
private:
int tableSize;
int collisions;
vector<T> hashVector;
};
#endif
template <typename T>
HashTable<T>::HashTable(int s)
{
tableSize = s;
}
template <typename T>
bool HashTable<T>::inTable(T s)
{
return true;
}
template <typename T>
void HashTable<T>::addEntry(T s)
{
}
template <typename T>
bool HashTable<T>::retrieveEntry(T s)
{
return true;
}
template <typename T>
int HashTable<T>::Collisions()
{
return collisions;
}