RCSB PDB Protein Data Bank A Member of the wwPDB
An Information Portal to Biological Macromolecular Structures
PDB Home | Contact Us
next up previous contents
Next: GetTablePtr Up: Methods Previous: WriteTable

IsTablePresent

NAME IsTablePresent

PROTOTYPE

#include "TblFileObj.h"

int TblFileObj::IsTablePresent(const char *blockName, 
                               const char *tableName)
int TblFileObj::IsTablePresent(const char *tableName)

EXAMPLE

#include "TblFileObj.h"

TblFileObj * fobjR = new TblFileObj("./test/TESTFILE1", WRITE_MODE);

s = new SSTable("MyTable");
FillTestTable(s, nRows, nCols, "ABCDEFGHIJKLMNOPQRSTUVWXYZ012345689");
fobjR->WriteTable(s,"MyDBlock","MyTable");
if (fobjR->isTablePresent("MyDBlock","MyTable"))
   cout<<"Table exist"<<endl;
PURPOSE

IsTablePresent(const char *, const char *) checks if table tableName exists in blockName in TblFileObj object. IsTablePresent(const char *) checks if table tableName exists in current datablock in TblFileObj object.

RECEIVES

IsTablePresent(const char *, const char *)

*blockName Name of datablock
*tableName Table name

IsTablePresent(const char *)

*tableName Table name

RETURN VALUE

Returns 0 when table dosn't exist, 1 when the table exists

REMARKS

None  



Olivera Tosic
6/12/2002

 

© RCSB PDB