After deployment, the Javadoc API reference for the GeoTAX SDK is included in the sdk/javadoc folder. The API reference documents Java packages and classes provided with the GeoTAX SDK. This API reference is also posted to our Support site:
You can use this code snippet to get started:
ListDataSource dataSourceList = new ArrayList<>();
dataSourceList.add(new FileDataSource(Paths.get("{directory}/data")));
configuration = new TaxRateLookupConfigurationBuilder()
.withData(dataSourceList)
.withResources(Paths.get("{directory}/geotax-dist-$project.version/taxing-resources"))
.withRuntimeLib(Paths
.get("directory/geotax-dist-${project.version}/taxing-resources/bin/win64"))
.build();
lookup = new TaxRateLookupBuilder().withConfiguration(configuration)
.build();
Preferences preferences = new PreferencesBuilder().build();
TaxRateAddress address = new TaxRateAddress();
address.setAddressLines(Arrays.asList("1820 PAUL THOMAS BLVD BROWNSVILLE, PA"));
TaxResponse response = lookup.lookupByAddress(address, preferences);
printField("status", response.getStatus());
if(response.getStatus() == Status.OK) {
for(Result result: response.getResults()) {
printField("score", result.getConfidence());
printField("formattedAddress", result.getMatchedAddress().getFormattedAddress());
printField("formattedStreetAddress", result.getMatchedAddress().getFormattedStreetAddress());
printField("formattedLocationAddress", result.getMatchedAddress().getFormattedLocationAddress());
printField("matchCode", result.getMatchedAddress().getMatchCode());
}
}
try {
lookup.close();
} catch (Exception e) {
e.printStackTrace();
}