| 1 | /* |
| 2 | $Id: main.cpp,v 1.3 2006/11/20 01:19:48 hachti Exp $ |
| 3 | $Log: main.cpp,v $ |
| 4 | Revision 1.3 2006/11/20 01:19:48 hachti |
| 5 | Another revision |
| 6 | |
| 7 | */ |
| 8 | #include <stdio.h> |
| 9 | #include <unistd.h> |
| 10 | |
| 11 | #include "tape_block.hh" |
| 12 | #include "data_block.hh" |
| 13 | |
| 14 | void tape_start(void* m){ |
| 15 | printf("tape_start\n"); |
| 16 | } |
| 17 | |
| 18 | void tape_stop(void* m){ |
| 19 | printf("tape_stop\n"); |
| 20 | } |
| 21 | |
| 22 | int main(){ |
| 23 | tape_block * myblock=0; |
| 24 | do{ |
| 25 | if (myblock) delete myblock; |
| 26 | myblock=tape_block::gen_from_fd(0); |
| 27 | |
| 28 | vector<string> desc=myblock->get_description(); |
| 29 | for (vector<string>::iterator iter=desc.begin(); |
| 30 | iter!=desc.end();iter++) |
| 31 | printf("%s\n",(*iter).c_str()); |
| 32 | } while (myblock->get_state()==tape_block::TBS_OK); |
| 33 | return 0; |
| 34 | } |