Skip to content

Commit 45c5ab9

Browse files
authored
Merge pull request #23 from imsweb/hcpcs-api
Add support for HCPCS API
2 parents 04f5099 + 10a4c90 commit 45c5ab9

13 files changed

Lines changed: 299 additions & 8 deletions

File tree

README.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,14 @@ Download [the latest JAR][1] or grab via Maven:
2929
<dependency>
3030
<groupId>com.imsweb</groupId>
3131
<artifactId>seerapi-client-java</artifactId>
32-
<version>3.14</version>
32+
<version>3.15</version>
3333
</dependency>
3434
```
3535

3636
or via Gradle:
3737

3838
```
39-
compile 'com.imsweb:seerapi-client-java:3.14'
39+
compile 'com.imsweb:seerapi-client-java:3.15'
4040
```
4141

4242
## Usage
@@ -150,6 +150,10 @@ The site-specific surgery tables available on the SEER website.
150150
api.surgery().tables().execute().body()
151151
```
152152

153+
### HCPCS
154+
155+
Healthcare Common Procedure Coding Systems (HCPCS) nomenclatures. The information is maintained through [CanMED](https://seer.cancer.gov/oncologytoolbox).
156+
153157
### Staging
154158

155159
Cancer staging algorithms. Currently supports Collaborative Stage which is a unified data collection system designed to provide a

build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ plugins {
1010
}
1111

1212
group = 'com.imsweb'
13-
version = '3.15-SNAPSHOT'
13+
version = '3.15'
1414
description = 'Java client library for SEER*API'
1515

1616
println "Starting build using ${Jvm.current()}"
@@ -67,7 +67,7 @@ spotbugs {
6767
excludeFilter = file('config/spotbugs/spotbugs-exclude.xml')
6868
}
6969
wrapper {
70-
gradleVersion = '5.2.1'
70+
gradleVersion = '5.4.1'
7171
distributionType = Wrapper.DistributionType.ALL
7272
}
7373

config/checkstyle/checkstyle.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,5 +161,8 @@
161161
</module>
162162
<module name="HiddenField" />
163163
</module>
164+
<module name="SuppressionFilter">
165+
<property name="file" value="${suppressionFile}" default="config/checkstyle/suppressions.xml"/>
166+
</module>
164167
<module name="Translation" />
165168
</module>

config/checkstyle/suppressions.xml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<?xml version="1.0"?>
2+
3+
<!DOCTYPE suppressions PUBLIC "-//Puppy Crawl//DTD Suppressions 1.1//EN" "http://www.puppycrawl.com/dtds/suppressions_1_1.dtd">
4+
5+
<suppressions>
6+
<suppress checks="MemberNameCheck" files=".*Hcpcs\.java"/>
7+
</suppressions>

gradle/wrapper/gradle-wrapper.jar

426 Bytes
Binary file not shown.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-5.2.1-all.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-5.4.1-all.zip
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists

gradlew

Lines changed: 17 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

gradlew.bat

Lines changed: 17 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/main/java/com/imsweb/seerapi/client/SeerApi.java

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323

2424
import com.imsweb.seerapi.client.disease.DiseaseService;
2525
import com.imsweb.seerapi.client.glossary.GlossaryService;
26+
import com.imsweb.seerapi.client.hcpcs.HcpcsService;
2627
import com.imsweb.seerapi.client.mph.MphService;
2728
import com.imsweb.seerapi.client.naaccr.NaaccrService;
2829
import com.imsweb.seerapi.client.ndc.NdcService;
@@ -45,6 +46,7 @@ public final class SeerApi {
4546
private SiteRecodeService _siteRecodeService;
4647
private StagingService _stagingService;
4748
private SurgeryService _surgeryService;
49+
private HcpcsService _hcpcsService;
4850

4951
/**
5052
* Creates a client API root object
@@ -87,6 +89,7 @@ private SeerApi(String baseUrl, final String apiKey) {
8789
_siteRecodeService = retrofit.create(SiteRecodeService.class);
8890
_stagingService = retrofit.create(StagingService.class);
8991
_surgeryService = retrofit.create(SurgeryService.class);
92+
_hcpcsService = retrofit.create(HcpcsService.class);
9093
}
9194

9295
/**
@@ -182,6 +185,14 @@ public SurgeryService surgery() {
182185
return _surgeryService;
183186
}
184187

188+
/**
189+
* Return the HCPCS service
190+
* @return an interface to all the HCPCS APIs
191+
*/
192+
public HcpcsService hcpcs() {
193+
return _hcpcsService;
194+
}
195+
185196
/**
186197
* Class to build a connection to SeerApi
187198
*/
Lines changed: 115 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,115 @@
1+
/*
2+
* Copyright (C) 2015 Information Management Services, Inc.
3+
*/
4+
package com.imsweb.seerapi.client.hcpcs;
5+
6+
import java.util.Date;
7+
import java.util.List;
8+
9+
import com.fasterxml.jackson.annotation.JsonProperty;
10+
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
11+
12+
@JsonPropertyOrder({"hcpcs_code", "generic_name", "brand_names", "strength", "fda_approval_year", "fda_discontinuation_year", "cms_approval_date",
13+
"cms_discontinuation_date", "categories", "major_drug_class", "minor_drug_class", "oral", "date_added", "date_modified", "score"})
14+
public class Hcpcs {
15+
16+
@JsonProperty("hcpcs_code")
17+
private String _hcpcsCode;
18+
@JsonProperty("generic_name")
19+
private String _genericName;
20+
@JsonProperty("brand_names")
21+
private List<String> _brandNames;
22+
@JsonProperty("strength")
23+
private String _strength;
24+
@JsonProperty("fda_approval_year")
25+
private String _fdaApprovalYear;
26+
@JsonProperty("fda_discontinuation_year")
27+
private String _fdaDiscontinuationYear;
28+
@JsonProperty("cms_approval_date")
29+
private String _cmsApprovalDate;
30+
@JsonProperty("cms_discontinuation_date")
31+
private String _cmsDiscontinuationDate;
32+
@JsonProperty("categories")
33+
private List<Category> _categories;
34+
@JsonProperty("major_drug_class")
35+
private String _majorDrugClass;
36+
@JsonProperty("minor_drug_class")
37+
private String _minorDrugClass;
38+
@JsonProperty("oral")
39+
private Boolean _oral;
40+
@JsonProperty("date_added")
41+
private Date _dateAdded;
42+
@JsonProperty("date_modified")
43+
private Date _dateModified;
44+
@JsonProperty("score")
45+
private Double score;
46+
47+
public String getHcpcsCode() {
48+
return _hcpcsCode;
49+
}
50+
51+
public String getGenericName() {
52+
return _genericName;
53+
}
54+
55+
public List<String> getBrandNames() {
56+
return _brandNames;
57+
}
58+
59+
public String getStrength() {
60+
return _strength;
61+
}
62+
63+
public String getFdaApprovalYear() {
64+
return _fdaApprovalYear;
65+
}
66+
67+
public String getFdaDiscontinuationYear() {
68+
return _fdaDiscontinuationYear;
69+
}
70+
71+
public String getCmsApprovalDate() {
72+
return _cmsApprovalDate;
73+
}
74+
75+
public String getCmsDiscontinuationDate() {
76+
return _cmsDiscontinuationDate;
77+
}
78+
79+
public List<Category> getCategories() {
80+
return _categories;
81+
}
82+
83+
public String getMajorDrugClass() {
84+
return _majorDrugClass;
85+
}
86+
87+
public String getMinorDrugClass() {
88+
return _minorDrugClass;
89+
}
90+
91+
public Boolean getOral() {
92+
return _oral;
93+
}
94+
95+
public Date getDateAdded() {
96+
return _dateAdded;
97+
}
98+
99+
public Date getDateModified() {
100+
return _dateModified;
101+
}
102+
103+
public Double getScore() {
104+
return score;
105+
}
106+
107+
// drug categories
108+
public enum Category {
109+
HORMONAL_THERAPY,
110+
ANCILLARY,
111+
CHEMOTHERAPY,
112+
IMMUNOTHERAPY,
113+
RADIOPHARMACEUTICAL;
114+
}
115+
}

0 commit comments

Comments
 (0)