Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "Vector.h"
- Vector::Vector()
- {
- //ctor
- }
- Vector::~Vector()
- {
- //dtor
- }
- void Vector::push (std::unique_ptr<Vehicle> toPush)
- {
- content.push_back(toPush);
- }
- void Vector::pop (int toPop)
- {
- content.erase(content.begin()+toPop);
- }
- void Vector::showAll(std::ostream& out)
- {
- for (int i=0; i<content.size(); ++i)
- {
- out<<i+1<<" "<<*(content[i])<<"\n";
- }
- }
- int Vector::getSize()
- {
- return content.size();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement