Ignore:
Timestamp:
2013-05-06T15:29:38+12:00 (11 years ago)
Author:
jmt12
Message:

Moving the critical file-related functions (copy, rm, etc) out of util.pm into their own proper class FileUtils. Use of the old functions in util.pm will prompt deprecated warning messages. There may be further functions that could be moved across in the future, but these are the critical ones when considering supporting other filesystems (HTTP, HDFS, WebDav, etc). Updated some key files to use the new functions so now deprecated messages thrown when importing/building demo collection 'out of the box'

File:
1 edited

Legend:

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

    r24193 r27306  
    3636use strict;
    3737use util;
     38use FileUtils;
    3839use MIME::Base64; # for base64 encoding
    3940
     
    247248    my $encodename = "$encoding-unicode";
    248249    my $enc_info = $encodings::encodings->{$encoding};
    249     my $mapfile = &util::filename_cat($ENV{'GSDLHOME'}, "mappings",
     250    my $mapfile = &FileUtils::filenameConcatenate($ENV{'GSDLHOME'}, "mappings",
    250251                      "to_uc", $enc_info->{'mapfile'});
    251252    if (!&loadmapencoding ($encodename, $mapfile)) {
     
    499500
    500501    my $enc_info = $encodings::encodings->{$encoding};
    501     my $mapfile = &util::filename_cat($ENV{'GSDLHOME'}, "mappings",
     502    my $mapfile = &FileUtils::filenameConcatenate($ENV{'GSDLHOME'}, "mappings",
    502503                      "from_uc", $enc_info->{'mapfile'});
    503504    if (!&loadmapencoding ($encodename, $mapfile)) {
Note: See TracChangeset for help on using the changeset viewer.