On 2 August 2013 00:33, Hady elsahar <[email protected]> wrote:
> Last update :
>
> https://github.com/hadyelsahar/extraction-framework/blob/lang-link-extract/scripts/src/main/scala/org/dbpedia/extraction/scripts/LanguageSpecificLinksGenerator.scala
>
>
Cool, thanks!
>
>
> On Tue, Jul 30, 2013 at 1:21 AM, Jona Christopher Sahnwaldt <
> [email protected]> wrote:
>
>> Two more things:
>>
>> 1. I just noticed that you changed the code to use FileOutputStream
>> and OutputStreamWriter instead of FileWriter, but you didn't actually
>> use the code I sent you. You don't pass an explicit encoding to the
>> OutputStreamWriter constructor, so your code still uses the platform
>> default encoding.
>
>
>> 2. Similarly for Source.fromFile. This method takes an implicit Codec
>> parameter. You should pass one explicitly.
>
>
>
> Please read this very good introduction to character encoding:
>>
>> http://www.joelonsoftware.com/articles/Unicode.html
>>
>> It's ten years old but I still recommend it to everyone. (BTW, its
>> author co-invented stackoverflow.com) Two short excerpts:
>>
>>
> i'm aware with character encoding , i'm not used to forcing it everytime
> ( this is wrong i confess ) , maybe because it works most of the time ,
> thanks for the link it's useful indeed.
>
Yes, in this case, it's required. The spec for Turtle requires UTF-8,
N-Triples require ASCII.
>
>
> I think the best way would be to add command-line arguments for the
>> file names or file suffixes instead of having them hard-coded. This
>> way, the user can either give ".ttl", ".ttl.gz" or ".ttl.bz2", and
>> IOUtils will automatically choose GZip, BZip2 or no compression.
>> Some more comments:
>
>
> done , as well as specific files folder name
>
> 1. Something's not quite right with these lines (they appear twice):
>> val baseDir = new File(args(1))
>> val file = Source.fromFile(baseDir)
>> The variable is called "baseDir", so it should be a directory, but
>> then you open it for reading, so it must be a file. You should
>> probably rename the variable.
>
>
> my bad sorry , fixed
>
>
>>
>> 2. It might be cleaner to split the code into two classes: one whose
>> main method executes "option 0", the other that executes "option 1".
>> But I guess that's a matter of taste. Otherwise, I think you should
>> give these options meaningful names, just like the "test" option. "0"
>> and "1" is not very user-friendly. :-)
>
>
> i was actually intending to ask about this , didn't manage to find a short
> expressive name , so i made it 0 1 for then ,
> i changed them to
> "master" for the masterLL file and "specific" for the specific ll files
> is that fine ?
>
Looks good!
Regards,
JC
>
>
> thanks
> Regard
> -------------------------------------------------
> Hady El-Sahar
> Research Assistant
> Center of Informatics Sciences | Nile
> University<http://nileuniversity.edu.eg/>
>
> email : [email protected]
> Phone : +2-01220887311
> http://hadyelsahar.me/
>
> <http://www.linkedin.com/in/hadyelsahar>
>
>
------------------------------------------------------------------------------
Get your SQL database under version control now!
Version control is standard for application code, but databases havent
caught up. So what steps can you take to put your SQL databases under
version control? Why should you start doing it? Read more to find out.
http://pubads.g.doubleclick.net/gampad/clk?id=49501711&iu=/4140/ostg.clktrk
_______________________________________________
Dbpedia-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dbpedia-developers