View Javadoc
1   package ca.uhn.fhir.jpa.term;
2   
3   /*
4    * #%L
5    * HAPI FHIR JPA Server
6    * %%
7    * Copyright (C) 2014 - 2018 University Health Network
8    * %%
9    * Licensed under the Apache License, Version 2.0 (the "License");
10   * you may not use this file except in compliance with the License.
11   * You may obtain a copy of the License at
12   * 
13   *      http://www.apache.org/licenses/LICENSE-2.0
14   * 
15   * Unless required by applicable law or agreed to in writing, software
16   * distributed under the License is distributed on an "AS IS" BASIS,
17   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18   * See the License for the specific language governing permissions and
19   * limitations under the License.
20   * #L%
21   */
22  
23  import org.hl7.fhir.r4.model.CodeType;
24  import org.hl7.fhir.r4.model.Coding;
25  import org.hl7.fhir.r4.model.Parameters.ParametersParameterComponent;
26  import org.hl7.fhir.r4.model.UriType;
27  
28  public class TranslationMatch {
29  	private Coding myConcept;
30  	private CodeType myEquivalence;
31  	private UriType mySource;
32  
33  	public TranslationMatch() {
34  		super();
35  	}
36  
37  	public Coding getConcept() {
38  		return myConcept;
39  	}
40  
41  	public void setConcept(Coding theConcept) {
42  		myConcept = theConcept;
43  	}
44  
45  	public CodeType getEquivalence() {
46  		return myEquivalence;
47  	}
48  
49  	public void setEquivalence(CodeType theEquivalence) {
50  		myEquivalence = theEquivalence;
51  	}
52  
53  	public UriType getSource() {
54  		return mySource;
55  	}
56  
57  	public void setSource(UriType theSource) {
58  		mySource = theSource;
59  	}
60  
61  	public void toParameterParts(ParametersParameterComponent theParam) {
62  		if (myEquivalence != null) {
63  			theParam.addPart().setName("equivalence").setValue(myEquivalence);
64  		}
65  
66  		if (myConcept != null) {
67  			theParam.addPart().setName("concept").setValue(myConcept);
68  		}
69  
70  		if (mySource != null) {
71  			theParam.addPart().setName("source").setValue(mySource);
72  		}
73  	}
74  }