Skip to content

Commit

Permalink
Cleanup for #254
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesagnew committed Nov 15, 2015
1 parent c516050 commit 8c087f0
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 29 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,26 +41,34 @@
import ca.uhn.fhir.rest.server.RestfulServer;
import ca.uhn.fhir.rest.server.provider.ServerConformanceProvider;
import ca.uhn.fhir.util.ExtensionConstants;
import net.sourceforge.cobertura.CoverageIgnore;

public class JpaConformanceProviderDstu1 extends ServerConformanceProvider {

private String myImplementationDescription;
private IFhirSystemDao<List<IResource>> mySystemDao;
private volatile Conformance myCachedValue;
private String myImplementationDescription;
private RestfulServer myRestfulServer;
private IFhirSystemDao<List<IResource>> mySystemDao;

/**
* Constructor
*/
@CoverageIgnore
public JpaConformanceProviderDstu1(){
super();
super.setCache(false);
}

/**
* Constructor
*/
public JpaConformanceProviderDstu1(RestfulServer theRestfulServer, IFhirSystemDao<List<IResource>> theSystemDao) {
super(theRestfulServer);
myRestfulServer = theRestfulServer;
mySystemDao = theSystemDao;
super.setCache(false);
}

public JpaConformanceProviderDstu1(){
super();
super.setCache(false);
}

@Override
public Conformance getServerConformance(HttpServletRequest theRequest) {
Conformance retVal = myCachedValue;
Expand Down Expand Up @@ -100,18 +108,20 @@ public Conformance getServerConformance(HttpServletRequest theRequest) {
return retVal;
}

@CoverageIgnore
public void setImplementationDescription(String theImplDesc) {
myImplementationDescription = theImplDesc;
}

@Override
public void setRestfulServer(RestfulServer theRestfulServer) {
this.myRestfulServer = theRestfulServer;
super.setRestfulServer(theRestfulServer);
}

public void setMySystemDao(IFhirSystemDao<List<IResource>> mySystemDao) {
@CoverageIgnore
public void setSystemDao(IFhirSystemDao<List<IResource>> mySystemDao) {
this.mySystemDao = mySystemDao;
}

public void setImplementationDescription(String theImplDesc) {
myImplementationDescription = theImplDesc;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,28 @@
import ca.uhn.fhir.rest.server.RestfulServer;
import ca.uhn.fhir.rest.server.provider.dstu2.ServerConformanceProvider;
import ca.uhn.fhir.util.ExtensionConstants;
import net.sourceforge.cobertura.CoverageIgnore;

public class JpaConformanceProviderDstu2 extends ServerConformanceProvider {

private String myImplementationDescription;
private IFhirSystemDao<Bundle> mySystemDao;
private volatile Conformance myCachedValue;
private RestfulServer myRestfulServer;
private DaoConfig myDaoConfig;
private String myImplementationDescription;
private RestfulServer myRestfulServer;
private IFhirSystemDao<Bundle> mySystemDao;

/**
* Constructor
*/
@CoverageIgnore
public JpaConformanceProviderDstu2(){
super();
super.setCache(false);
}

/**
* Constructor
*/
public JpaConformanceProviderDstu2(RestfulServer theRestfulServer, IFhirSystemDao<Bundle> theSystemDao, DaoConfig theDaoConfig) {
super(theRestfulServer);
myRestfulServer = theRestfulServer;
Expand All @@ -60,11 +73,6 @@ public JpaConformanceProviderDstu2(RestfulServer theRestfulServer, IFhirSystemDa
super.setCache(false);
}

public JpaConformanceProviderDstu2(){
super();
super.setCache(false);
}

@Override
public Conformance getServerConformance(HttpServletRequest theRequest) {
Conformance retVal = myCachedValue;
Expand Down Expand Up @@ -110,21 +118,23 @@ public Conformance getServerConformance(HttpServletRequest theRequest) {
return retVal;
}

public void setDaoConfig(DaoConfig myDaoConfig) {
this.myDaoConfig = myDaoConfig;
}

@CoverageIgnore
public void setImplementationDescription(String theImplDesc) {
myImplementationDescription = theImplDesc;
}

@Override
public void setRestfulServer(RestfulServer theRestfulServer) {
this.myRestfulServer = theRestfulServer;
super.setRestfulServer(theRestfulServer);
}

public void setMyDaoConfig(DaoConfig myDaoConfig) {
this.myDaoConfig = myDaoConfig;
}

public void setMySystemDao(IFhirSystemDao<Bundle> mySystemDao) {
@CoverageIgnore
public void setSystemDao(IFhirSystemDao<Bundle> mySystemDao) {
this.mySystemDao = mySystemDao;
}

public void setImplementationDescription(String theImplDesc) {
myImplementationDescription = theImplDesc;
}
}

0 comments on commit 8c087f0

Please sign in to comment.