You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@opennlp.apache.org by Jörn Kottmann <ko...@gmail.com> on 2013/10/24 13:47:25 UTC

Re: svn commit: r1535339 - /opennlp/trunk/opennlp-tools/src/main/java/opennlp/tools/entitylinker/EntityLinkerProperties.java

On 10/24/2013 12:58 PM, markg@apache.org wrote:
> +  public EntityLinkerProperties(String propertiesfile) throws IOException, FileNotFoundException {
> +    this.propertyFileLocation = propertiesfile;
>       stream = new FileInputStream(propertiesfile);
>       props.load(stream);
> +    stream.close();
>     }

In other parts of OpenNLP we removed all these constructors and methods 
which take a String for a file,
because it makes it clear from the method signature what is expected.

Jörn

Re: svn commit: r1535339 - /opennlp/trunk/opennlp-tools/src/main/java/opennlp/tools/entitylinker/EntityLinkerProperties.java

Posted by Mark G <gi...@gmail.com>.
sounds good, I'll remove
thanks
MG


On Thu, Oct 24, 2013 at 7:47 AM, Jörn Kottmann <ko...@gmail.com> wrote:

> On 10/24/2013 12:58 PM, markg@apache.org wrote:
>
>> +  public EntityLinkerProperties(String propertiesfile) throws
>> IOException, FileNotFoundException {
>> +    this.propertyFileLocation = propertiesfile;
>>       stream = new FileInputStream(**propertiesfile);
>>       props.load(stream);
>> +    stream.close();
>>     }
>>
>
> In other parts of OpenNLP we removed all these constructors and methods
> which take a String for a file,
> because it makes it clear from the method signature what is expected.
>
> Jörn
>