[ 
https://issues.apache.org/jira/browse/OPENNLP-1219?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16620324#comment-16620324
 ] 

ASF GitHub Bot commented on OPENNLP-1219:
-----------------------------------------

kojisekig closed pull request #333: OPENNLP-1219: change private instance 
variable featureGenerators to p…
URL: https://github.com/apache/opennlp/pull/333
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git 
a/opennlp-tools/src/main/java/opennlp/tools/namefind/DefaultNameContextGenerator.java
 
b/opennlp-tools/src/main/java/opennlp/tools/namefind/DefaultNameContextGenerator.java
index 83318e4eb..5361165b6 100644
--- 
a/opennlp-tools/src/main/java/opennlp/tools/namefind/DefaultNameContextGenerator.java
+++ 
b/opennlp-tools/src/main/java/opennlp/tools/namefind/DefaultNameContextGenerator.java
@@ -36,7 +36,7 @@
  */
 public class DefaultNameContextGenerator implements NameContextGenerator {
 
-  private AdaptiveFeatureGenerator[] featureGenerators;
+  protected AdaptiveFeatureGenerator[] featureGenerators;
 
   @Deprecated
   private static AdaptiveFeatureGenerator windowFeatures = new 
CachedFeatureGenerator(


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


> change private instance variable featureGenerators to protected in 
> DefaultNameContextGenerator
> ----------------------------------------------------------------------------------------------
>
>                 Key: OPENNLP-1219
>                 URL: https://issues.apache.org/jira/browse/OPENNLP-1219
>             Project: OpenNLP
>          Issue Type: Improvement
>    Affects Versions: 1.9.0
>            Reporter: Koji Sekiguchi
>            Priority: Minor
>
> TokenNameFinderTrainer allows users to customize TokenNameFinderFactory via 
> -factory option. As I want to override 
> DefaultNameContextGenerator.getContext(), I made the sub-class of 
> TokenNameFinderFactory and created an instance of the sub-class of 
> DefaultNameContextGenerator in the constructor of my TokenNameFinderFactory. 
> However, I couldn't implement getContext() method of my 
> DefaultNameContextGenerator because I couldn't access private member 
> featureGenerators.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to