Advertisement
Guest User

Untitled

a guest
Nov 23rd, 2014
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.71 KB | None | 0 0
  1. #include "Zatvor.h"
  2. #include "Celija.h"
  3.  
  4. ostream&  operator <<(ostream& os, const Zatvor& z)
  5. {
  6.     os << z.razina << " " << z.ime << " " << z.prezime << endl;
  7.  
  8.    
  9.     vector<Celija> temp = z.celije;
  10.     vector<Celija>::iterator i;
  11.     for(i = temp.begin(); i != temp.end() ; i++)
  12.     {
  13.         os << i->brojKreveta << " " << i->blok << " " << i->broj << endl;
  14.     }
  15.     return os;
  16. }
  17.  
  18. Zatvor::Zatvor(string razina1, string ime1, string prezime1)
  19. {
  20.     razina=razina1;
  21.     ime=ime1;
  22.     prezime=prezime1;
  23. }
  24.  
  25. Zatvor Zatvor::operator +=(const Celija &c)
  26. {
  27.     celije.push_back(c);
  28.     return *this;
  29. }
  30.  
  31. Zatvor Zatvor::operator --(int)
  32. {
  33.     celije.pop_back();
  34.     return *this;
  35. }
  36.  
  37. Zatvor::Zatvor(void)
  38. {
  39. }
  40.  
  41.  
  42. Zatvor::~Zatvor(void)
  43. {
  44. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement