public POSContextGenerator getPOSContextGenerator(int cacheSize) { if (artifactProvider != null) { Properties manifest = (Properties) artifactProvider.getArtifact("manifest.properties"); String version = manifest.getProperty("OpenNLP-Version"); if (Version.parse(version).getMinor() < 8) { return new DefaultPOSContextGenerator(cacheSize, getDictionary()); } } return new ConfigurablePOSContextGenerator(cacheSize, createFeatureGenerators()); }
public POSContextGenerator getPOSContextGenerator(int cacheSize) { if (artifactProvider != null) { Properties manifest = (Properties) artifactProvider.getArtifact("manifest.properties"); String version = manifest.getProperty("OpenNLP-Version"); if (Version.parse(version).getMinor() < 8) { return new DefaultPOSContextGenerator(cacheSize, getDictionary()); } } return new ConfigurablePOSContextGenerator(cacheSize, createFeatureGenerators()); }
public POSContextGenerator getPOSContextGenerator(int cacheSize) { if (artifactProvider != null) { Properties manifest = (Properties) artifactProvider.getArtifact("manifest.properties"); String version = manifest.getProperty("OpenNLP-Version"); if (Version.parse(version).getMinor() < 8) { return new DefaultPOSContextGenerator(cacheSize, getDictionary()); } } return new ConfigurablePOSContextGenerator(cacheSize, createFeatureGenerators()); }