Show
Ignore:
Timestamp:
21.01.2010 15:22:28 (10 years ago)
Author:
mdewsnip
Message:

Changed calls to GDBMUtils::gdbmCachedCollectionSet() to dbutil::write_infodb_entry(). Part of removing GDBMUtils.pm and making the code less GDBM-specific.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone2/perllib/IncrementalBuildUtils.pm

    r17283 r21562  
    390390        # Now use the GDBM utils to write a blank string to this oid in the 
    391391        # database 
    392         &GDBMUtils::gdbmCachedCollectionSet($collection, $oid, ""); 
     392    my $index_text_directory_path = &util::filename_cat($ENV{'GSDLHOME'}, "collect", $collection, "index", "text"); 
     393    my $infodb_file_path = &dbutil::get_infodb_file_path("gdbm", $collection, $index_text_directory_path); 
     394    my $infodb_file_handle = &dbutil::open_infodb_write_handle("gdbm", $infodb_file_path, "append"); 
     395    &dbutil::write_infodb_entry("gdbm", $infodb_file_handle, $oid, &dbutil::convert_infodb_string_to_hash("")); 
    393396        # Remove reverse lookup 
    394         &GDBMUtils::gdbmCachedCollectionSet($collection, $doc_num, ""); 
     397    &dbutil::write_infodb_entry("gdbm", $infodb_file_handle, $doc_num, &dbutil::convert_infodb_string_to_hash("")); 
     398    &dbutil::close_infodb_write_handle("gdbm", $infodb_file_handle); 
     399 
    395400        # And remove from the database 
    396401        &callGS2LuceneDelete($collection, $doc_num);