public String getId() {
   try {
     return adaptedClass.getId();
   } catch (Exception e) {
     throw new RuntimeException("Error getting Id", e);
   }
 }
 public qicoremedicationIngredientAdapter setIsActiveIngredient(BooleanType param) {
   adaptedClass
       .addExtension()
       .setUrl("http://hl7.org/fhir/StructureDefinition/medication-isActiveIngredient")
       .setValue(param);
   return this;
 }
 public Reference getItemReference() {
   try {
     return adaptedClass.getItemReference();
   } catch (Exception e) {
     throw new RuntimeException("Error getting ItemReference", e);
   }
 }
 public Ratio getAmount() {
   try {
     return adaptedClass.getAmount();
   } catch (Exception e) {
     throw new RuntimeException("Error getting Amount", e);
   }
 }
 public Type getItem() {
   try {
     return adaptedClass.getItem();
   } catch (Exception e) {
     throw new RuntimeException("Error getting Item", e);
   }
 }
 public CodeableConcept getItemCodeableConcept() {
   try {
     return adaptedClass.getItemCodeableConcept();
   } catch (Exception e) {
     throw new RuntimeException("Error getting ItemCodeableConcept", e);
   }
 }
 public BooleanType getIsActiveIngredient() {
   List<org.hl7.fhir.dstu3.model.Extension> extensions =
       adaptedClass.getExtensionsByUrl(
           "http://hl7.org/fhir/StructureDefinition/medication-isActiveIngredient");
   if (extensions == null || extensions.size() <= 0) {
     return null;
   } else if (extensions.size() == 1) {
     return (org.hl7.fhir.dstu3.model.BooleanType) extensions.get(0).getValue();
   } else {
     throw new RuntimeException("More than one extension exists for isActiveIngredient");
   }
 }
 public qicoremedicationIngredientAdapter setId(String param) {
   adaptedClass.setId(param);
   return this;
 }
 public boolean hasIdElement() {
   return adaptedClass.hasIdElement();
 }
 public boolean hasId() {
   return adaptedClass.hasId();
 }
 public boolean hasItemCodeableConcept() {
   return adaptedClass.hasItemCodeableConcept();
 }
 public qicoremedicationIngredientAdapter setAmount(Ratio param) {
   adaptedClass.setAmount(param);
   return this;
 }
 public qicoremedicationIngredientAdapter setItemTarget(Medication param) {
   Reference reference = new Reference(param);
   adaptedClass.setItem(reference);
   return this;
 }
 public Medication getItemMedicationTarget() {
   return (org.hl7.fhir.dstu3.model.Medication)
       ((org.hl7.fhir.dstu3.model.Reference) adaptedClass.getItem()).getResource();
 }
 public Substance getItemSubstanceTarget() {
   return (org.hl7.fhir.dstu3.model.Substance)
       ((org.hl7.fhir.dstu3.model.Reference) adaptedClass.getItem()).getResource();
 }
 public qicoremedicationIngredientAdapter setItem(Type param) {
   adaptedClass.setItem(param);
   return this;
 }
 public boolean hasAmount() {
   return adaptedClass.hasAmount();
 }