#include <TSK_DBI_Log.hxx>#include "TSeqNoAllocator.hxx"#include "Rtypes.h"#include <cstdlib>#include <iostream>#include <string>
Go to the source code of this file.
Functions | |
| int | main (int argc, char **argv) |
| int main | ( | int | argc, | |
| char ** | argv | |||
| ) |
Definition at line 27 of file allocate_seq_no.cxx.
References TSeqNoAllocator::GetSeqNo(), and SK_DBI_Error.
00027 { 00028 00029 if ( argc < 2 ) { 00030 SK_DBI_Error("ERROR: Insufficient arguments passed to allocate_seq_no.exe."); 00031 std::cout << "0" << std::endl; 00032 return 1; 00033 } 00034 std::string table_name(argv[1]); 00035 Int_t requireGlobal = 0; 00036 Int_t dbNo = 0; 00037 if ( argc > 2 ) requireGlobal = atoi(argv[2]); 00038 if ( argc > 3 ) dbNo = atoi(argv[3]); 00039 TSeqNoAllocator sna = TSeqNoAllocator(); 00040 Int_t seqno = sna.GetSeqNo(table_name,requireGlobal,dbNo); 00041 std::cout << seqno << std::endl; 00042 return 0; 00043 }

1.6.1