Using objects with STL vector - minimal set of methods
- by osgx
Hello
What is "minimal framework" (necessary methods) of object, which I will use with STL <vector>?
For my assumptions:
#include <vector>
#include <cstring>
using namespace std;
class Doit {
private:
char *a;
public:
Doit(){a=(char*)malloc(10);}
~Doit(){free(a);}
};
int main(){
…