| false |  |
| example disablebuttons | ...Enabled = false; btFirst->Enabled = false; btLast->Enabled = false; btNext->Enabled = false; btPrev->Enabled = false; btSearch->Enabled = false; btBackup->Enabled=false; btRestore->Enabled=false; btDupl->Enabled=false; btClear->Enabled=false; btAdd->Enabled=false; btUpdate->En... |
| example disablebuttons | ...Enabled = false; btLast->Enabled = false; btNext->Enabled = false; btPrev->Enabled = false; btSearch->Enabled = false; btBackup->Enabled=false; btRestore->Enabled=false; btDupl->Enabled=false; btClear->Enabled=false; btAdd->Enabled=false; btUpdate->Enabled=false; btDelete->Ena... |
| example disablebuttons | ...Enabled=false; btAdd->Enabled=false; btUpdate->Enabled=false; btDelete->Enabled=false; } ... |
| example disablebuttons | ...Enabled=false; btUpdate->Enabled=false; btDelete->Enabled=false; } ... |
| example disablebuttons | ...Enabled=false; btDelete->Enabled=false; } ... |
| example disablebuttons | ...Enabled=false; } ... |
| example disablebuttons | ...Enabled = false; btNext->Enabled = false; btPrev->Enabled = false; btSearch->Enabled = false; btBackup->Enabled=false; btRestore->Enabled=false; btDupl->Enabled=false; btClear->Enabled=false; btAdd->Enabled=false; btUpdate->Enabled=false; btDelete->Enabled=false; } ... |
| example disablebuttons | ...Enabled = false; btPrev->Enabled = false; btSearch->Enabled = false; btBackup->Enabled=false; btRestore->Enabled=false; btDupl->Enabled=false; btClear->Enabled=false; btAdd->Enabled=false; btUpdate->Enabled=false; btDelete->Enabled=false; } ... |
| example disablebuttons | ...Enabled = false; btSearch->Enabled = false; btBackup->Enabled=false; btRestore->Enabled=false; btDupl->Enabled=false; btClear->Enabled=false; btAdd->Enabled=false; btUpdate->Enabled=false; btDelete->Enabled=false; } ... |
| example disablebuttons | ...Enabled = false; btBackup->Enabled=false; btRestore->Enabled=false; btDupl->Enabled=false; btClear->Enabled=false; btAdd->Enabled=false; btUpdate->Enabled=false; btDelete->Enabled=false; } ... |
| example disablebuttons | ...Enabled=false; btRestore->Enabled=false; btDupl->Enabled=false; btClear->Enabled=false; btAdd->Enabled=false; btUpdate->Enabled=false; btDelete->Enabled=false; } ... |
| example disablebuttons | ...Enabled=false; btDupl->Enabled=false; btClear->Enabled=false; btAdd->Enabled=false; btUpdate->Enabled=false; btDelete->Enabled=false; } ... |
| example disablebuttons | ...Enabled=false; btClear->Enabled=false; btAdd->Enabled=false; btUpdate->Enabled=false; btDelete->Enabled=false; } ... |
| example formcreate | ...Checked==false; else cb->Checked=true; // GetVersion Number dict->Version(tmp); MainForm->Caption = "Alpes Software - " + AnsiString(tmp); // Get Number of Keys rc = dict->NumberOfKeys(INDEX); lKeys->Caption = AnsiString(rc); if (rc) First(); } //------------------------------... |
| fast |  |
| realisamdoc overview | ...6 in different kind of application : Text Retrieval, CGI Internet, databases to store HTML pages, scripts and HTML macros, XML records, with a very fast access time. Tests were conducted to store million of keys and records associated. ... |
| realisamdoc overview | ...Fast access to data ... |
| faster |  |
| realisamdoc overview | ...RealIsam uses the object-oriented technology for a faster and easier development and to simplify the source code. ... |
| fclose |  |
| example backup | ...ProcessMessages(); } fclose(fp); StatusBar1->SimpleText = "Number of Keys: " + AnsiString(nbisam); lRecords->Caption = AnsiString(nbseq); lKeys->Caption = AnsiString(nbisam); gettime(&t); nbsec2 = t.ti_hour*3600+t.ti_min*60 + t.ti_sec; int elapsed = nbsec2-nbsec1; lElap-... |
| example restore | ...ProcessMessages(); } fclose(fp); int nbk = dict->NumberOfKeys(INDEX); StatusBar1->SimpleText = "Number of Keys: " + AnsiString(nbk); lRecords->Caption = AnsiString(nbisam); lKeys->Caption = AnsiString(nbk); gettime(&t); nbsec2 = t.ti_hour*3600+t.ti_min... |
| example start | ...ProcessMessages(); } fclose(fp); } int nbk = dict->NumberOfKeys(INDEX); lRecords->Caption = AnsiString(nbrecords); lKeys->Caption = AnsiString(nbk); gettime(&t); nbsec2 = t.ti_hour*3600+t.ti_min*60 + t.ti_sec; hund2 = nbsec2*100 + t.ti_hund; float diff = floa... |
| features |  |
| realisamdoc overview | ...realisam Features : ... |
| feof |  |
| example restore | ...Cursor = oldCursor; return; } nbrecords=0; nbisam=0; // read sequential data while (!feof(fp)) { buffer[0]=0; fgets(buffer,BUF_LEN,fp); if (strlen(buffer)>0) { nbisam++; IndexBuffer(buffer); } else nbrecords=nbrecords; ... |
| example start | ...Cursor = oldCursor; return; } // read sequential data while (!feof(fp)) { tmp[0]=0; fgets(buffer,BUF_LEN,fp); // IndexBuffer(buffer); Application->ProcessMessages(); } fclose(fp); } int nbk = dict->NumberOfKeys(INDEX)... |
| fgets |  |
| example restore | ...Cursor; return; } nbrecords=0; nbisam=0; // read sequential data while (!feof(fp)) { buffer[0]=0; fgets(buffer,BUF_LEN,fp); if (strlen(buffer)>0) { nbisam++; IndexBuffer(buffer); } else nbrecords=nbrecords; Application... |
| example start | ...Cursor = oldCursor; return; } // read sequential data while (!feof(fp)) { tmp[0]=0; fgets(buffer,BUF_LEN,fp); // IndexBuffer(buffer); Application->ProcessMessages(); } fclose(fp); } int nbk = dict->NumberOfKeys(INDEX)... |
| field |  |
| example clear | ... Clear Search Field... |
| index_summary item53 | ... Search Field... |
| realisamdoc overview | ...Real Isam, at contrary to other relational databases, ignores the field notion, and does not try to classify data in numeric, date or text fields : it writes binary or text data according the length specified, and returns all these bytes when a reading operation is required. It is the responsab... |
| fields |  |
| realisamdoc overview | ...Real Isam, at contrary to other relational databases, ignores the field notion, and does not try to classify data in numeric, date or text fields : it writes binary or text data according the length specified, and returns all these bytes when a reading operation is required. It is the responsab... |
| realisamdoc overview | ...l these bytes when a reading operation is required. It is the responsability of the developer to organize records and to know how to extract the fields. Realisam is better adapted to store variable length text data like XML strings. ... |
| file |  |
| example backup | ...Cursor; char tmp[250]; char *p,*p1; FILE *fp; strcpy(tmp,"Backup your Data in Text File Dict.txt ? "); if (Application->MessageBoxA(tmp,"Backup Dictionary",MB_YESNO)==IDNO) return; strcpy(tmp,dict_directory); strcat(tmp,"dict.txt"); fp=fopen(tmp,"w+t"); if (fp==NULL) { Applicati... |
| example backup | ...Cursor; char tmp[250]; char *p,*p1; FILE *fp; strcpy(tmp,"Backup your Data in Text File Dict.txt ? "); if (Application->MessageBoxA(tmp,"Backup Dictionary",MB_YESNO)==IDNO) return; strcpy(tmp,dict_directory); strcat(tmp,"dict.txt"); fp=fopen(tmp,"w+t"); if (fp==NULL) { Applicati... |
| example backup | ... Backup Isam Files in Text File... |
| example backup | ...MessageBoxA("Problem Opening Dict.Txt File", "Backup Dictionary",MB_OK); return; } if (cb->Checked==true) multi=1; else multi=0; Screen->Cursor = crHourGlass; strcpy(tmp,lIndex->Caption.c_str()); INDEX=atoi(tmp); DisableButtons(); eWord->Text==... |
| example download | ... Files are packed in a ZIP file Borland DLL,or BPL are also incuded if you want to run the TESTISAM.EXE program without having the BCB development compiler. ... |
| example download | ...The ZIP file countains the following files ... |
| example include | ... Include File MAIN.H... |
| example principle | ... The goal of this application is to build a dictionary from sequential files provided by the webster dictionnary. Each sequential file is associated to a letter : wb_a, wb_b, .... wb_z. Sequential files should installed in a subdirectory ("dictionary") of your application. The program will buil... |
| example principle | ...Backup database : Sequential read of the database and save the content in the dict.txt file ... |
| example principle | ...Restore database : Delete the database, and restore it from the dict.txt file ... |
| example restore | ... Restore Isam Files from the text file... |
| example restore | ... void __fastcall TMainForm::btRestoreClick(TObject *Sender) { char tmp[250]; char name[250]; FILE *fp; int rc,nbisam; char buffer[BUF_LEN]; struct time t; int nbsec1,nbsec2; strcpy(tmp,"Restore Data from Dict.txt ? \r\n Isam Files will be deleted, and rebuilt"); if (Application-... |
| example restore | ...MessageBoxA("File DICT.txt not Found","File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; return; } nbrecords=0; nbisam=0; // read sequential data while (!feof(fp)) { buffer[0]=0; fgets(buffer,BUF_LEN,f... |
| example restore | ...MessageBoxA("File DICT.txt not Found","File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; return; } nbrecords=0; nbisam=0; // read sequential data while (!feof(fp)) { buffer[0]=0; fgets(buffer,BUF_LEN,f... |
| example start | ... void __fastcall TMainForm::btStartClick(TObject *Sender) { char tmp[250]; char name[250]; char html[250]; int i; FILE *fp; int rc; char buffer[BUF_LEN]; struct time t; int nbsec1,nbsec2; int hund1,hund2; int nbf; int K; TCursor oldCursor = Screen->Cursor; if (cb->Checked==tr... |
| example start | ...SimpleText = "Indexing " + AnsiString(tmp) + " File"; strcpy(html,dict_directory); strcat(html,tmp); fp = fopen(html,"r"); if (!fp) {Application->MessageBoxA(html,"File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; return... |
| example start | ...MessageBoxA(html,"File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; return; } // read sequential data while (!feof(fp)) { tmp[0]=0; fgets(buffer,BUF_LEN,fp); // IndexBuffer(buffer); Applic... |
| example stat | ...-Read Sequential record in the dictionnary file ... |
| index_summary item33 | ...de File MAIN.H... |
| index_summary item3 | ...oad Real Isam ZIP file... |
| index_summary item47 | ...p Isam Files in Text File... |
| index_summary item48 | ...re Isam Files from the text file... |
| index_summary item5 | ...sam.h : include file... |
| realisamdoc close | ... Close the .NDX index file and the .DAT file ... |
| realisamdoc close | ... Close the .NDX index file and the .DAT file ... |
| realisamdoc closereopen | ...Index file extension ... |
| realisamdoc closereopen | ...Data file extension ... |
| realisamdoc deleteisam | ... Delete the index file and the data file. The programmer should provide the right full name for the index and the data file. After deleting these file, It is recommended to create a new database, and not try to access function through the old db pointer. ... |
| realisamdoc deleteisam | ... Delete the index file and the data file. The programmer should provide the right full name for the index and the data file. After deleting these file, It is recommended to create a new database, and not try to access function through the old db pointer. ... |
| realisamdoc deleteisam | ... Delete the index file and the data file. The programmer should provide the right full name for the index and the data file. After deleting these file, It is recommended to create a new database, and not try to access function through the old db pointer. ... |
| realisamdoc deleteisam | ... Delete the index file and the data file. The programmer should provide the right full name for the index and the data file. After deleting these file, It is recommended to create a new database, and not try to access function through the old db pointer. ... |
| realisamdoc download | ...Download realisam.zip File (35 KB)... |
| realisamdoc download | ...RealIsam ZIP file to download ... |
| realisamdoc download | ... The DLL file name is "realisam.dll". Another files are needed for development purpose : ... |
| realisamdoc download | ..."realisam.h" is the header file to include in an application ... |
| realisamdoc download | ...The Zip file countains the following files : ... |
| realisamdoc getnew | ...Return the new physical position where to write data in the data file. Use a WriteRecord to write the data. ... |
| realisamdoc include | ...Include File REALISAM.H... |
| realisamdoc open | ...Open the index file and the data file associated to the database. The index file, will have the extension specified in the indx parameter,and the data file have the extension specified in the dat parameter. Realisam creates these files if they don't exist. Notice : always open / reopen the data... |
| realisamdoc open | ...Open the index file and the data file associated to the database. The index file, will have the extension specified in the indx parameter,and the data file have the extension specified in the dat parameter. Realisam creates these files if they don't exist. Notice : always open / reopen the data... |
| realisamdoc open | ...Open the index file and the data file associated to the database. The index file, will have the extension specified in the indx parameter,and the data file have the extension specified in the dat parameter. Realisam creates these files if they don't exist. Notice : always open / reopen the data... |
| realisamdoc open | ...the index file and the data file associated to the database. The index file, will have the extension specified in the indx parameter,and the data file have the extension specified in the dat parameter. Realisam creates these files if they don't exist. Notice : always open / reopen the database ... |
| realisamdoc open | ...lock of datalen+8 bytes will be allocated and written. If data length is bigger than datalen, a second block is allocated, and so on... The Windows file management system works with multiples of 1024 bytes, and we recommand to work with datalen+8 such as 120 , 248, 504, 1016,2040 ... bytes in order... |
| realisamdoc readfirst | ...ReadRecord(buffer,recdata); buffer[rc]=0; ............. } else ............ // another example : sequential reading of a file rc = db->ReadFirstKey(0,RetKey,&recdata); while (rc) { rc=db->ReadRecord(buffer,recdata); // processs the record ..................... |
| realisamdoc readfirst | ...ReadNextKey(RetKey,&recdata); // rc = 0 if end of file (last key of index) } ................... ... |
| realisamdoc readprev | ...CloseEngine(); ....................... ................. // procedure int rc, recdata; char ReturnKey[100]; // example : read a file in the reverse order // buffer is supposed to be allocated rc = db->ReadLast(0,ReturnKey,&recdata); while (rc) { rc = db->ReadRecord(buffer,rec... |
| realisamdoc writekey | ... Index : index number (0 to 63) Key : Key value recdata : pointer (address of the data record in the file .DAT. This value is provided when calling the function GetNewRecordNumber. ... |
| filename |  |
| realisamdoc closereopen | ...int CloseReopen(char *FileName,short BlockSize,char *ndx, char *dat); ... |
| realisamdoc include | ...#ifdef __cplusplus extern "C" { #endif class _export realisam { public: realisam(void); ~realisam(void); int OpenEngine(char *FileName,short BlockSize,char *ndx, char*dat); int CloseEngine(void); int SetIndexMode(short Index, short Value); int WriteRecord(char *pdata,in... |
| realisamdoc include | ...nt RecNumber); int Version(char *p); int GetIndexMode(int ndx); int DeleteIsam(char *indexname,char *dataname); int CloseReopen(char *FileName,short BlockSize,char *ndx, char *dat); }; #ifdef __cplusplus } #endif #endif ... |
| realisamdoc open | ...OpenEngine(char *filename,int datalen, char *indx,char *dat); db is a pointer on the database ... |
| realisamdoc open | ... filename = filename, with no extension (this function opens or creates the Isam files , according the extension required) datalen = Data physical block length . This value is not the real data length, but an average size. realisam will write data in consecutive blocks of datalen + 8 bytes. If re... |
| realisamdoc open | ... filename = filename, with no extension (this function opens or creates the Isam files , according the extension required) datalen = Data physical block length . This value is not the real data length, but an average size. realisam will write data in consecutive blocks of datalen + 8 bytes. If re... |
| files |  |
| example backup | ... Backup Isam Files in Text File... |
| example download | ...The ZIP file countains the following files ... |
| example download | ...and a subdirectory Dictionary that contains 26 html files, ... |
| example download | ... Files are packed in a ZIP file Borland DLL,or BPL are also incuded if you want to run the TESTISAM.EXE program without having the BCB development compiler. ... |
| example duplicate | ... Duplicate Isam Files... |
| example duplicate | ... = new realisam(); char RetKey[MAX_KEY]; char buffer[BUF_LEN]; char tmp[250]; strcpy(tmp,"Do you want to build a duplicate dictionnary : files Dupli.ndx and Dupli.dat ? "); if (Application->MessageBoxA(tmp,"Isam Dictionary",MB_YESNO)==IDNO) return; TCursor oldCursor = Screen->C... |
| example principle | ...Number of Files to index : 26-1 (26 = all letters of the alphabet) ... |
| example principle | ... The goal of this application is to build a dictionary from sequential files provided by the webster dictionnary. Each sequential file is associated to a letter : wb_a, wb_b, .... wb_z. Sequential files should installed in a subdirectory ("dictionary") of your application. The program will buil... |
| example principle | ...y from sequential files provided by the webster dictionnary. Each sequential file is associated to a letter : wb_a, wb_b, .... wb_z. Sequential files should installed in a subdirectory ("dictionary") of your application. The program will build an Isam database, where entries can be accessed dir... |
| example restore | ... Restore Isam Files from the text file... |
| example restore | ...CloseEngine(); // delete isam files strcpy(name,dict_directory);strcat(name,"dict.ndx"); rc = unlink (name); strcpy(name,dict_directory);strcat(name,"dict.dat"); rc =unlink (name); Screen->Cursor = crHourGlass; DisableButtons(); eWord->Text==""; mWord->Clear(); gettime(&t); ... |
| example restore | ...]; FILE *fp; int rc,nbisam; char buffer[BUF_LEN]; struct time t; int nbsec1,nbsec2; strcpy(tmp,"Restore Data from Dict.txt ? \r\n Isam Files will be deleted, and rebuilt"); if (Application->MessageBoxA(tmp,"Restore Dictionary",MB_YESNO)==IDNO) return; TCursor oldCursor = Screen->C... |
| example start | ...CloseEngine(); // delete isam files strcpy(tmp,dict_directory);strcat(tmp,"dict.ndx"); rc = unlink (tmp); strcpy(name,dict_directory);strcat(name,"dict.dat"); rc =unlink (name); Screen->Cursor = crHourGlass; DisableButtons(); eWord->Text=""; mWord->Clear(); RK->Caption... |
| example start | ...SetIndexMode(INDEX+1,multi); nbrecords=0; // read contents of the 1-26 HTML Files (in alphabetic reverse order, just for fun) for (i=nbf;i>=0;i--) // for (i=0;i... |
| example start | ...ProcessMessages(); // Get Number of Files to Index strcpy(tmp,edFile->Text.c_str()); nbf=atoi(tmp); nbf--; if (nbf... |
| index_summary item47 | ...p Isam Files in Text File... |
| index_summary item48 | ...re Isam Files from the text file... |
| index_summary item52 | ...cate Isam Files... |
| realisamdoc closereopen | ...0 = Error opening files ... |
| realisamdoc closereopen | ... This function is used to save data, closing the files, and open them again for further processing. ... |
| realisamdoc download | ... The DLL file name is "realisam.dll". Another files are needed for development purpose : ... |
| realisamdoc download | ...The Zip file countains the following files : ... |
| realisamdoc open | ... have the extension specified in the indx parameter,and the data file have the extension specified in the dat parameter. Realisam creates these files if they don't exist. Notice : always open / reopen the database with the same physical block size. ... |
| realisamdoc open | ... filename = filename, with no extension (this function opens or creates the Isam files , according the extension required) datalen = Data physical block length . This value is not the real data length, but an average size. realisam will write data in consecutive blocks of datalen + 8 bytes. If re... |
| realisamdoc open | ...0 = Error at opening files ... |
| realisamdoc overview | ... Real Isam is a tool used to manage files using the well known ISAM method (Indexed Sequential Access Method). This method is still very convenient for applications such as Internet, Intranet, Text database retrieval, when you need to store and get variable length documents at very high spee... |
| find |  |
| realisamdoc readdirect | ...Key = Key to find in the index ... |
| finished |  |
| example duplicate | ...MessageBoxA("Duplication Finished","RealIsam",MB_OK); } //--------------------------------------------------------------------------- ... |
| example start | ...MessageBoxA("Indexation Finished","RealIsam",MB_OK); } //--------------------------------------------------------------------------- ... |
| first |  |
| example backup | ...Caption = AnsiString(elapsed); First(); Screen->Cursor = oldCursor; Beep(); EnableButtons(); Application->MessageBoxA("Backup Done","RealIsam",MB_OK); } //--------------------------------------------------------------------------- ... |
| example delete | ...DeleteRecord(M_recdata); First(); StatusBar1->SimpleText="Entry Deleted"; } //--------------------------------------------------------------------------- ... |
| example duplicate | ...CloseEngine(); First(); Screen->Cursor = oldCursor; EnableButtons(); Application->MessageBoxA("Duplication Finished","RealIsam",MB_OK); } //--------------------------------------------------------------------------- ... |
| example first | ... Search First Record... |
| example first | ... void __fastcall TMainForm::First() { int rc,recdata; char Key[MAX_KEY],RetKey[MAX_KEY]; char buffer[BUF_LEN]; char tmp[50]; INDEX=0; mWord->Clear(); rc = dict->ReadFirstKey(INDEX,RetKey,&recdata); RK->Caption=AnsiString(RetKey); eWord->Text=AnsiString(RetKey); if (rc==1... |
| example first | ...SetTextBuf(buffer); } } void __fastcall TMainForm::btFirstClick(TObject *Sender) { First(); } //--------------------------------------------------------------------------- ... |
| example formcreate | ...Caption = AnsiString(rc); if (rc) First(); } //--------------------------------------------------------------------------- ... |
| example include | ...ue(char *result, char *buff, char *tag, int posdeb); int __fastcall IndexBuffer(char *buff); void __fastcall Search(); void __fastcall First(); void __fastcall EnableButtons(); void __fastcall DisableButtons(); public: // User declarations __fastcall TMainForm(TComp... |
| example principle | ...First Key : Returns the first key of the index ... |
| example principle | ...First Key : Returns the first key of the index ... |
| example restore | ...Caption = AnsiString(elapsed); First(); Screen->Cursor = oldCursor; Beep(); EnableButtons(); Application->MessageBoxA("Restoration Done","RealIsam",MB_OK); } //--------------------------------------------------------------------------- ... |
| example start | ...SimpleText = ""; First(); Screen->Cursor = oldCursor; Beep(); EnableButtons(); Application->MessageBoxA("Indexation Finished","RealIsam",MB_OK); } //--------------------------------------------------------------------------- ... |
| index_summary item41 | ...h First Record... |
| realisamdoc readfirst | ...read the first key on a specified. This function allows to start to read the first key of a specified index. ... |
| realisamdoc readfirst | ...read the first key on a specified. This function allows to start to read the first key of a specified index. ... |
| realisamdoc readprev | ...rc = 0 : error or empty index, or under first key ... |
| float |  |
| example start | ...Caption = AnsiString(nbk); gettime(&t); nbsec2 = t.ti_hour*3600+t.ti_min*60 + t.ti_sec; hund2 = nbsec2*100 + t.ti_hund; float diff = float(hund2-hund1); sprintf(tmp,"%.02f",diff/100.0); int elapsed = nbsec2-nbsec1; lElap->Caption = AnsiString(tmp); // elapsed); // Clo... |
| example start | ...Caption = AnsiString(nbk); gettime(&t); nbsec2 = t.ti_hour*3600+t.ti_min*60 + t.ti_sec; hund2 = nbsec2*100 + t.ti_hund; float diff = float(hund2-hund1); sprintf(tmp,"%.02f",diff/100.0); int elapsed = nbsec2-nbsec1; lElap->Caption = AnsiString(tmp); // elapsed); // Clo... |
| following |  |
| example download | ...The ZIP file countains the following files ... |
| example stat | ... Read/Write operations per second, each operation includes the following actions: ... |
| realisamdoc download | ...The Zip file countains the following files : ... |
| fonction |  |
| realisamdoc constr | ...Fonction :... |
| realisamdoc readdirect | ...Fonction :... |
| fopen |  |
| example backup | ...MessageBoxA(tmp,"Backup Dictionary",MB_YESNO)==IDNO) return; strcpy(tmp,dict_directory); strcat(tmp,"dict.txt"); fp=fopen(tmp,"w+t"); if (fp==NULL) { Application->MessageBoxA("Problem Opening Dict.Txt File", "Backup Dictionary",MB_OK); return; } if (... |
| example restore | ...SetIndexMode(INDEX+1,multi); nbrecords=0; strcpy(name,dict_directory);strcat(name,"dict.txt"); fp = fopen(name,"r"); if (!fp) {Application->MessageBoxA("File DICT.txt not Found","File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; ... |
| example start | ...SimpleText = "Indexing " + AnsiString(tmp) + " File"; strcpy(html,dict_directory); strcat(html,tmp); fp = fopen(html,"r"); if (!fp) {Application->MessageBoxA(html,"File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; return... |
| formclose |  |
| example formclose | ... void __fastcall TMainForm::FormClose(TObject *Sender, TCloseAction &Action) { dict->CloseEngine(); Action = caFree; } //--------------------------------------------------------------------------- ... |
| example include | ...dex; TLabel *Label3; TButton *btVersion; void __fastcall FormCreate(TObject *Sender); void __fastcall FormClose(TObject *Sender, TCloseAction &Action); void __fastcall btStartClick(TObject *Sender); void __fastcall btSearchClick(TObject *... |
| formcreate |  |
| example formcreate | ... /////////////////////////////////////////////////////////// void __fastcall TMainForm::FormCreate(TObject *Sender) { char name[250]; AnsiString Dir; int rc; int mode; char tmp[100]; Dir = GetCurrentDir(); strcpy(base_directory,Dir.c_str()); strcpy(dict_directory,base_directory); s... |
| example include | ...btAdd; TCheckBox *cbSec; TLabel *lIndex; TLabel *Label3; TButton *btVersion; void __fastcall FormCreate(TObject *Sender); void __fastcall FormClose(TObject *Sender, TCloseAction &Action); void __fastcall btStartClick(TObject *Sen... |
| found |  |
| example restore | ...MessageBoxA("File DICT.txt not Found","File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; return; } nbrecords=0; nbisam=0; // read sequential data while (!feof(fp)) { buffer[0]=0; fgets(buffer,BUF_LEN,f... |
| example restore | ...MessageBoxA("File DICT.txt not Found","File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; return; } nbrecords=0; nbisam=0; // read sequential data while (!feof(fp)) { buffer[0]=0; fgets(buffer,BUF_LEN,f... |
| example search | ...SetTextBuf("Word Not Found"); } M_recdata=recdata; strcpy(M_Key,RetKey); } ... |
| example start | ...MessageBoxA(html,"File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; return; } // read sequential data while (!feof(fp)) { tmp[0]=0; fgets(buffer,BUF_LEN,fp); // IndexBuffer(buffer); Applic... |
| realisamdoc deletekey | ...rc = 0 : error : Key not found ... |
| realisamdoc readdirect | ...ReturnKey = Key found after searching the index. ... |
| realisamdoc readdirect | ... 0 : Key not found (Retkey contains a key that is the closest key, usually the key before the searched key (in the alphabetic order). 1 : Key found : ReturnKey contains also Key ... |
| realisamdoc readdirect | ... 0 : Key not found (Retkey contains a key that is the closest key, usually the key before the searched key (in the alphabetic order). 1 : Key found : ReturnKey contains also Key ... |
| realisamdoc readdirect | ...ReadDirectKey(0,"microsoft",RetKey,&recdata); if (rc) // ok : key found { rc = db->ReadRecord(buffer,recdata); buffer[rc]=0; ............. } else ............ ... |
| realisamdoc readfirst | ...ReadFirstKey(0,RetKey,&recdata); if (rc) // key found { rc = db->ReadRecord(buffer,recdata); buffer[rc]=0; ............. } else ............ // another example : sequential reading of a file rc = db->ReadFirstKey(0,RetKey,&recdata); while (rc) { rc=db->Re... |
| realisamdoc readlast | ...rc = 1 : correct (key found, index not empty) ... |
| realisamdoc readlast | ...ReadLastKey(0,RetKey,&recdata); if (rc) // ok : key is found { rc = db->ReadRecord(buffer,recdata); buffer[rc]=0; ............. } else ............ ... |
| fp |  |
| example backup | ...Cursor; char tmp[250]; char *p,*p1; FILE *fp; strcpy(tmp,"Backup your Data in Text File Dict.txt ? "); if (Application->MessageBoxA(tmp,"Backup Dictionary",MB_YESNO)==IDNO) return; strcpy(tmp,dict_directory); strcat(tmp,"dict.txt"); fp=fopen(tmp,"w+t"); if (fp==NULL) { Applicati... |
| example backup | ...MessageBoxA(tmp,"Backup Dictionary",MB_YESNO)==IDNO) return; strcpy(tmp,dict_directory); strcat(tmp,"dict.txt"); fp=fopen(tmp,"w+t"); if (fp==NULL) { Application->MessageBoxA("Problem Opening Dict.Txt File", "Backup Dictionary",MB_OK); return; } if (... |
| example backup | ...MessageBoxA(tmp,"Backup Dictionary",MB_YESNO)==IDNO) return; strcpy(tmp,dict_directory); strcat(tmp,"dict.txt"); fp=fopen(tmp,"w+t"); if (fp==NULL) { Application->MessageBoxA("Problem Opening Dict.Txt File", "Backup Dictionary",MB_OK); return; } if (... |
| example backup | ...; strcat(html,"</B> (<I></I>) "); strcat(html,buffer); strcat(html,"</P>\n"); fputs(html,fp); nbseq++; } else // extract concatenated items { p1=buffer; p=strchr(p1,'\r'); whil... |
| example backup | ...t;/B> (<I></I>) "); strcat(html,p1); strcat(html,"</P>\n"); fputs(html,fp); nbseq++; p1=p+1; p=strchr(p1,'\n'); } strcpy(html,"<P><B>"); strcat(html,RetKey)... |
| example backup | ...html,"</B> (<I></I>) "); strcat(html,p1); strcat(html,"</P>\n"); fputs(html,fp); nbseq++; } } rc=dict->ReadNextKey(RetKey,&recdata); Application->ProcessMessages(); } fclose(fp); StatusB... |
| example backup | ...ProcessMessages(); } fclose(fp); StatusBar1->SimpleText = "Number of Keys: " + AnsiString(nbisam); lRecords->Caption = AnsiString(nbseq); lKeys->Caption = AnsiString(nbisam); gettime(&t); nbsec2 = t.ti_hour*3600+t.ti_min*60 + t.ti_sec; int elapsed = nbsec2-nbsec1; lElap-... |
| example restore | ... void __fastcall TMainForm::btRestoreClick(TObject *Sender) { char tmp[250]; char name[250]; FILE *fp; int rc,nbisam; char buffer[BUF_LEN]; struct time t; int nbsec1,nbsec2; strcpy(tmp,"Restore Data from Dict.txt ? \r\n Isam Files will be deleted, and rebuilt"); if (Application-... |
| example restore | ...Cursor = oldCursor; return; } nbrecords=0; nbisam=0; // read sequential data while (!feof(fp)) { buffer[0]=0; fgets(buffer,BUF_LEN,fp); if (strlen(buffer)>0) { nbisam++; IndexBuffer(buffer); } else nbrecords=nbrecords; ... |
| example restore | ... return; } nbrecords=0; nbisam=0; // read sequential data while (!feof(fp)) { buffer[0]=0; fgets(buffer,BUF_LEN,fp); if (strlen(buffer)>0) { nbisam++; IndexBuffer(buffer); } else nbrecords=nbrecords; Application->ProcessMessages()... |
| example restore | ...ProcessMessages(); } fclose(fp); int nbk = dict->NumberOfKeys(INDEX); StatusBar1->SimpleText = "Number of Keys: " + AnsiString(nbk); lRecords->Caption = AnsiString(nbisam); lKeys->Caption = AnsiString(nbk); gettime(&t); nbsec2 = t.ti_hour*3600+t.ti_min... |
| example restore | ...SetIndexMode(INDEX+1,multi); nbrecords=0; strcpy(name,dict_directory);strcat(name,"dict.txt"); fp = fopen(name,"r"); if (!fp) {Application->MessageBoxA("File DICT.txt not Found","File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; ... |
| example restore | ...SetIndexMode(INDEX+1,multi); nbrecords=0; strcpy(name,dict_directory);strcat(name,"dict.txt"); fp = fopen(name,"r"); if (!fp) {Application->MessageBoxA("File DICT.txt not Found","File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; ... |
| example start | ... void __fastcall TMainForm::btStartClick(TObject *Sender) { char tmp[250]; char name[250]; char html[250]; int i; FILE *fp; int rc; char buffer[BUF_LEN]; struct time t; int nbsec1,nbsec2; int hund1,hund2; int nbf; int K; TCursor oldCursor = Screen->Cursor; if (cb->Checked==tr... |
| example start | ...sor = oldCursor; return; } // read sequential data while (!feof(fp)) { tmp[0]=0; fgets(buffer,BUF_LEN,fp); // IndexBuffer(buffer); Application->ProcessMessages(); } fclose(fp); } int nbk = dict->NumberOfKeys(INDEX); ... |
| example start | ...ProcessMessages(); } fclose(fp); } int nbk = dict->NumberOfKeys(INDEX); lRecords->Caption = AnsiString(nbrecords); lKeys->Caption = AnsiString(nbk); gettime(&t); nbsec2 = t.ti_hour*3600+t.ti_min*60 + t.ti_sec; hund2 = nbsec2*100 + t.ti_hund; float diff = floa... |
| example start | ...SimpleText = "Indexing " + AnsiString(tmp) + " File"; strcpy(html,dict_directory); strcat(html,tmp); fp = fopen(html,"r"); if (!fp) {Application->MessageBoxA(html,"File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; return... |
| example start | ...SimpleText = "Indexing " + AnsiString(tmp) + " File"; strcpy(html,dict_directory); strcat(html,tmp); fp = fopen(html,"r"); if (!fp) {Application->MessageBoxA(html,"File Not Found",MB_OK); EnableButtons(); Screen->Cursor = oldCursor; return... |
| example start | ...Cursor = oldCursor; return; } // read sequential data while (!feof(fp)) { tmp[0]=0; fgets(buffer,BUF_LEN,fp); // IndexBuffer(buffer); Application->ProcessMessages(); } fclose(fp); } int nbk = dict->NumberOfKeys(INDEX)... |
| fputs |  |
| example backup | ...l,RetKey); strcat(html,"</B> (<I></I>) "); strcat(html,buffer); strcat(html,"</P>\n"); fputs(html,fp); nbseq++; } else // extract concatenated items { p1=buffer; p=strchr(p1,'\r'); ... |
| example backup | ...(html,"</B> (<I></I>) "); strcat(html,p1); strcat(html,"</P>\n"); fputs(html,fp); nbseq++; p1=p+1; p=strchr(p1,'\n'); } strcpy(html,"<P><B>"); strcat(htm... |
| example backup | ...; strcat(html,"</B> (<I></I>) "); strcat(html,p1); strcat(html,"</P>\n"); fputs(html,fp); nbseq++; } } rc=dict->ReadNextKey(RetKey,&recdata); Application->ProcessMessages(); } fclose(fp); ... |
| free |  |
| realisamdoc deleterecord | ...Delete a data record (more precisely, rewrite the record with a null data length). The free space is not managed under realisam. It is recommended to write an utility to copy a old database in a new one if there is too many records deleted. ... |
| full |  |
| realisamdoc deleteisam | ... Delete the index file and the data file. The programmer should provide the right full name for the index and the data file. After deleting these file, It is recommended to create a new database, and not try to access function through the old db pointer. ... |
| fun |  |
| example start | ...SetIndexMode(INDEX+1,multi); nbrecords=0; // read contents of the 1-26 HTML Files (in alphabetic reverse order, just for fun) for (i=nbf;i>=0;i--) // for (i=0;i... |
| function |  |
| realisamdoc close | ...Function :... |
| realisamdoc closereopen | ...Function :... |
| realisamdoc closereopen | ... This function is used to save data, closing the files, and open them again for further processing. ... |
| realisamdoc deleteisam | ...Function :... |
| realisamdoc deleteisam | ...e right full name for the index and the data file. After deleting these file, It is recommended to create a new database, and not try to access function through the old db pointer. ... |
| realisamdoc deletekey | ...Function :... |
| realisamdoc deletekey | ...Delete a key in a specified index. The key and its related record number have to be provided as parameters (for duplicate keys, the function needs to know this association). ... |
| realisamdoc deleterecord | ...Function :... |
| realisamdoc getindex | ...Function :... |
| realisamdoc getnew | ...Function :... |
| realisamdoc number | ...Function :... |
| realisamdoc number | ...This function provides the number of keys existing for a specified index. ... |
| realisamdoc open | ...Function :... |
| realisamdoc open | ... filename = filename, with no extension (this function opens or creates the Isam files , according the extension required) datalen = Data physical block length . This value is not the real data length, but an average size. realisam will write data in consecutive blocks of datalen + 8 bytes. If re... |
| realisamdoc readfirst | ...Function :... |
| realisamdoc readfirst | ...read the first key on a specified. This function allows to start to read the first key of a specified index. ... |
| realisamdoc readlast | ...Function :... |
| realisamdoc readnext | ...Function :... |
| realisamdoc readnext | ...Read the next key in the current index . This function is generally used after a call to ReadFirstKey or un ReadDirectKey. The index is not specified in the call. ... |
| realisamdoc readprev | ...Function :... |
| realisamdoc readrecord | ...fer. The memory allocated for this transfer must be large enough to receive the data. If the length is totally unknown, a call to RecordLength function allows to allocate the right amount of memory. ReadRecord restores the entire data written previously, including binary data. For character stri... |
| realisamdoc readrecord | ...Function :... |
| realisamdoc recordlength | ...return the length of a data record. This function allows to know the size of a record before reading it, and the developer can allocate memory depending on the size returned. ... |
| realisamdoc recordlength | ...Function :... |
| realisamdoc rewriterecord | ...Function :... |
| realisamdoc rewriterecord | ...Rewrite a data record to a previous location. If data length is bigger than the previous write, the function can create new physical blocks. Developer has to specifiy the new data length. ... |
| realisamdoc setindex | ...Function :... |
| realisamdoc setindex | ...s an error when trying to write again the same key. For indexes with duplicate keys, there is no limit to the number of duplicate keys. If this function is not called, the default value is 0 (no duplicate keys). ... |
| realisamdoc version | ...Function :... |
| realisamdoc writekey | ...Function :... |
| realisamdoc writekey | ... index number (0 to 63) Key : Key value recdata : pointer (address of the data record in the file .DAT. This value is provided when calling the function GetNewRecordNumber. ... |
| realisamdoc writerecord | ...Function :... |
| functions |  |
| realisamdoc constr | ...Return a pointer to the instance. This pointer has to be used for any call to realisam functions. ... |
| further |  |
| realisamdoc closereopen | ... This function is used to save data, closing the files, and open them again for further processing. ... |