Changeset 29815 for main/trunk/gli

Show
Ignore:
Timestamp:
30.03.2015 13:08:18 (5 years ago)
Author:
kjdon
Message:

removed some debugging statements

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/gli/src/org/greenstone/gatherer/metadata/FilenameEncoding.java

    r29793 r29815  
    347347             
    348348            String filename_ascii = filename_uri.toASCIIString(); 
    349             DebugStream.println("ascii = "+filename_ascii); 
    350349            String filename_raw_bytes = URLDecoder.decode(filename_ascii,"ISO-8859-1"); 
    351             DebugStream.println("raw = "+filename_raw_bytes); 
    352350            filename_url_encoded = iso_8859_1_filename_to_url_encoded(filename_raw_bytes); 
    353351             
     
    358356            filename_url_encoded = file.getAbsolutePath();  
    359357        } 
    360             DebugStream.println("returning "+filename_url_encoded); 
    361358        return filename_url_encoded; 
    362359    } 
     
    372369    { 
    373370        String urlEncoded = ""; 
    374 DebugStream.println("in iso 8859 to url encoded, "+raw_bytes_filename); 
     371 
    375372        try { 
    376373            // By this point we have a UTF-8 encoded string that captures 
     
    390387            String unicode_filename = new String(raw_bytes,"UTF-8"); 
    391388             
    392                 //urlEncoded = URLEncoder.encode(unicode_filename, "UTF-8"); 
    393389            for(int i = 0; i < unicode_filename.length(); i++) { 
    394390            char charVal = unicode_filename.charAt(i); 
    395391            if ((int)charVal > 255) { 
    396392                urlEncoded += String.format("&#x%02X;", (int)charVal); 
    397                     //urlEncoded += String.format("\\u%04X", (int)charVal); 
    398393            } 
    399394            else if((int)charVal > 127) { 
    400395                urlEncoded += String.format("%%%02X", (int)charVal); 
    401                     //urlEncoded += Integer.toHexString((int)charVal); 
    402396            } else { 
    403397                urlEncoded += String.format("%c", (char)charVal); 
     
    409403            throw(e); 
    410404        } 
    411 DebugStream.println("returning "+urlEncoded); 
     405 
    412406        return urlEncoded; 
    413407    }