<?xml version="1.0" encoding="UTF-8"?>
<library xmlns="urn:hl7-org:elm:r1" xmlns:t="urn:hl7-org:elm-types:r1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:fhir="http://hl7.org/fhir" xmlns:qdm43="urn:healthit-gov:qdm:v4_3" xmlns:qdm53="urn:healthit-gov:qdm:v5_3" xmlns:a="urn:hl7-org:cql-annotations:r1" localId="0">
   <annotation translatorOptions="EnableAnnotations,EnableLocators,DisableListDemotion,DisableListPromotion" signatureLevel="Overloads" xsi:type="a:CqlToElmInfo"/>
   <annotation message="An operand identifier reference is hiding another identifier of the same name." errorType="semantic" errorSeverity="warning" xsi:type="a:CqlToElmError"/>
   <annotation message="An operand identifier reference is hiding another identifier of the same name." errorType="semantic" errorSeverity="warning" xsi:type="a:CqlToElmError"/>
   <annotation message="An operand identifier reference is hiding another identifier of the same name." errorType="semantic" errorSeverity="warning" xsi:type="a:CqlToElmError"/>
   <annotation xsi:type="a:Annotation">
      <a:s r="304">
         <a:s>/*
  * Library: IMMZD2DTJEEncounterElements
  */
library IMMZD2DTJEEncounterElements</a:s>
      </a:s>
   </annotation>
   <identifier id="IMMZD2DTJEEncounterElements" system="http://smart.who.int/immunizations"/>
   <schemaIdentifier id="urn:hl7-org:elm" version="r1"/>
   <usings>
      <def localId="1" localIdentifier="System" uri="urn:hl7-org:elm-types:r1" version="1.0.0"/>
      <def localId="206" locator="7:1-7:26" localIdentifier="FHIR" uri="http://hl7.org/fhir" version="4.0.1">
         <annotation xsi:type="a:Annotation">
            <a:s r="206">
               <a:s>using </a:s>
               <a:s>
                  <a:s>FHIR</a:s>
               </a:s>
               <a:s> version '4.0.1'</a:s>
            </a:s>
         </annotation>
      </def>
   </usings>
   <includes>
      <def localId="208" locator="8:1-8:35" localIdentifier="FHIRHelpers" path="http://hl7.org/fhir/FHIRHelpers" version="4.0.1">
         <annotation xsi:type="a:Annotation">
            <a:s r="208">
               <a:s>include </a:s>
               <a:s>
                  <a:s>FHIRHelpers</a:s>
               </a:s>
               <a:s> version '4.0.1'</a:s>
            </a:s>
         </annotation>
      </def>
      <def localId="210" locator="10:1-10:19" localIdentifier="WHOConcepts" path="http://smart.who.int/immunizations/WHOConcepts">
         <annotation xsi:type="a:Annotation">
            <a:s r="210">
               <a:s>include </a:s>
               <a:s>
                  <a:s>WHOConcepts</a:s>
               </a:s>
            </a:s>
         </annotation>
      </def>
      <def localId="212" locator="11:1-11:27" localIdentifier="WC" path="http://smart.who.int/immunizations/WHOCommon">
         <annotation xsi:type="a:Annotation">
            <a:s r="212">
               <a:s>include </a:s>
               <a:s>
                  <a:s>WHOCommon</a:s>
               </a:s>
               <a:s> called WC</a:s>
            </a:s>
         </annotation>
      </def>
      <def localId="214" locator="12:1-12:29" localIdentifier="WE" path="http://smart.who.int/immunizations/WHOElements">
         <annotation xsi:type="a:Annotation">
            <a:s r="214">
               <a:s>include </a:s>
               <a:s>
                  <a:s>WHOElements</a:s>
               </a:s>
               <a:s> called WE</a:s>
            </a:s>
         </annotation>
      </def>
      <def localId="216" locator="14:1-14:32" localIdentifier="Common" path="http://smart.who.int/immunizations/IMMZCommon">
         <annotation xsi:type="a:Annotation">
            <a:s r="216">
               <a:s>include </a:s>
               <a:s>
                  <a:s>IMMZCommon</a:s>
               </a:s>
               <a:s> called Common</a:s>
            </a:s>
         </annotation>
      </def>
      <def localId="218" locator="15:1-15:36" localIdentifier="Concepts" path="http://smart.who.int/immunizations/IMMZConcepts">
         <annotation xsi:type="a:Annotation">
            <a:s r="218">
               <a:s>include </a:s>
               <a:s>
                  <a:s>IMMZConcepts</a:s>
               </a:s>
               <a:s> called Concepts</a:s>
            </a:s>
         </annotation>
      </def>
      <def localId="220" locator="16:1-16:46" localIdentifier="Encounter" path="http://smart.who.int/immunizations/IMMZEncounterElements">
         <annotation xsi:type="a:Annotation">
            <a:s r="220">
               <a:s>include </a:s>
               <a:s>
                  <a:s>IMMZEncounterElements</a:s>
               </a:s>
               <a:s> called Encounter</a:s>
            </a:s>
         </annotation>
      </def>
      <def localId="222" locator="18:1-18:44" localIdentifier="JEElements" path="http://smart.who.int/immunizations/IMMZD2DTJEElements">
         <annotation xsi:type="a:Annotation">
            <a:s r="222">
               <a:s>include </a:s>
               <a:s>
                  <a:s>IMMZD2DTJEElements</a:s>
               </a:s>
               <a:s> called JEElements</a:s>
            </a:s>
         </annotation>
      </def>
   </includes>
   <parameters>
      <def localId="224" locator="20:1-20:36" name="Today" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:s r="224">
               <a:s>parameter Today </a:s>
               <a:s r="228">
                  <a:s>Date</a:s>
               </a:s>
               <a:s> default </a:s>
               <a:s r="227">
                  <a:s>Today()</a:s>
               </a:s>
            </a:s>
         </annotation>
         <default localId="227" locator="20:30-20:36" xsi:type="Today"/>
         <parameterTypeSpecifier localId="228" locator="20:17-20:20" name="t:Date" xsi:type="NamedTypeSpecifier"/>
      </def>
      <def localId="230" locator="21:1-21:28" name="EncounterId" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:s r="230">
               <a:s>parameter EncounterId </a:s>
               <a:s r="231">
                  <a:s>String</a:s>
               </a:s>
            </a:s>
         </annotation>
         <parameterTypeSpecifier localId="231" locator="21:23-21:28" name="t:String" xsi:type="NamedTypeSpecifier"/>
      </def>
   </parameters>
   <contexts>
      <def localId="236" locator="23:1-23:15" name="Patient"/>
   </contexts>
   <statements>
      <def localId="234" locator="23:1-23:15" name="Patient" context="Patient">
         <expression localId="235" xsi:type="SingletonFrom">
            <operand localId="233" locator="23:1-23:15" dataType="fhir:Patient" templateId="http://hl7.org/fhir/StructureDefinition/Patient" xsi:type="Retrieve"/>
         </expression>
      </def>
      <def localId="239" locator="28:1-31:43" name="JE Doses Administered to Patient" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="internal" value="JE containing Doses Administered to Patient"/>
            <a:s r="239">
               <a:s>/*
@internal: JE containing Doses Administered to Patient
*/
define &quot;JE Doses Administered to Patient&quot;:
  </a:s>
               <a:s r="251">
                  <a:s>
                     <a:s r="240">
                        <a:s r="242">
                           <a:s>
                              <a:s>Encounter.&quot;Doses Administered to Patient&quot;</a:s>
                           </a:s>
                        </a:s>
                        <a:s> I</a:s>
                     </a:s>
                  </a:s>
                  <a:s>
  </a:s>
                  <a:s r="248">
                     <a:s>where
    </a:s>
                     <a:s r="248">
                        <a:s r="245">
                           <a:s r="244">
                              <a:s>I</a:s>
                           </a:s>
                           <a:s>.</a:s>
                           <a:s r="245">
                              <a:s>vaccineCode</a:s>
                           </a:s>
                        </a:s>
                        <a:s> in </a:s>
                        <a:s r="247">
                           <a:s r="246">
                              <a:s>Concepts</a:s>
                           </a:s>
                           <a:s>.</a:s>
                           <a:s r="247">
                              <a:s>&quot;JE vaccines&quot;</a:s>
                           </a:s>
                        </a:s>
                     </a:s>
                  </a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="251" locator="29:3-31:43" xsi:type="Query">
            <source localId="240" locator="29:3-29:45" alias="I">
               <expression localId="242" locator="29:3-29:43" name="Doses Administered to Patient" libraryName="Encounter" xsi:type="ExpressionRef"/>
            </source>
            <where localId="248" locator="30:3-31:43" xsi:type="InValueSet">
               <signature localId="250" name="t:Concept" xsi:type="NamedTypeSpecifier"/>
               <code localId="249" name="ToConcept" libraryName="FHIRHelpers" xsi:type="FunctionRef">
                  <operand localId="245" locator="31:5-31:17" path="vaccineCode" scope="I" xsi:type="Property"/>
               </code>
               <valueset localId="247" locator="31:22-31:43" name="JE vaccines" libraryName="Concepts" preserve="true"/>
            </where>
         </expression>
      </def>
      <def localId="254" locator="36:1-37:52" name="JE Primary Series Doses Administered to Patient" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="internal" value="JE containing Doses Administered to Patient that are in the Primary series"/>
            <a:s r="254">
               <a:s>/*
@internal: JE containing Doses Administered to Patient that are in the Primary series
*/
define &quot;JE Primary Series Doses Administered to Patient&quot;:
  </a:s>
               <a:s r="256">
                  <a:s r="255">
                     <a:s>&quot;JE Doses Administered to Patient&quot;</a:s>
                  </a:s>
                  <a:s>.</a:s>
                  <a:s r="256">
                     <a:s>seriesPrimary()</a:s>
                  </a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="256" locator="37:3-37:52" name="seriesPrimary" libraryName="Common" xsi:type="FunctionRef">
            <operand localId="255" locator="37:3-37:36" name="JE Doses Administered to Patient" xsi:type="ExpressionRef"/>
         </expression>
      </def>
      <def localId="259" locator="42:1-43:58" name="Number of JE Primary Series Doses Administered" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="internal" value="Number of JE Primary Series doses"/>
            <a:s r="259">
               <a:s>/*
@internal: Number of JE Primary Series doses
*/
define &quot;Number of JE Primary Series Doses Administered&quot;:
  </a:s>
               <a:s r="263">
                  <a:s>Count(</a:s>
                  <a:s r="260">
                     <a:s>&quot;JE Primary Series Doses Administered to Patient&quot;</a:s>
                  </a:s>
                  <a:s>)</a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="263" locator="43:3-43:58" xsi:type="Count">
            <source localId="260" locator="43:9-43:57" name="JE Primary Series Doses Administered to Patient" xsi:type="ExpressionRef"/>
         </expression>
      </def>
      <def localId="266" locator="52:1-53:47" name="Client's age is less than 6 months" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="Client's age is less than 6 months"/>
            <a:t name="pseudocode" value="&quot;Date of birth&quot; &lt; 6 months"/>
            <a:t name="code" value="Client's age is less than 6 months-41"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="266">
               <a:s>/*
@input: Client's age is less than 6 months
@pseudocode: Today's date − &quot;Date of birth&quot; &lt; 6 months
@code: Client's age is less than 6 months-41
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;Client's age is less than 6 months&quot;:
  </a:s>
               <a:s r="267">
                  <a:s r="269">
                     <a:s r="268">
                        <a:s>Encounter</a:s>
                     </a:s>
                     <a:s>.</a:s>
                     <a:s r="269">
                        <a:s>&quot;Current Patient Age In Months&quot;</a:s>
                     </a:s>
                  </a:s>
                  <a:s r="270"> &lt; 6</a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="267" locator="53:3-53:47" xsi:type="Less">
            <signature localId="271" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <signature localId="272" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <operand localId="269" locator="53:3-53:43" name="Current Patient Age In Months" libraryName="Encounter" xsi:type="ExpressionRef"/>
            <operand localId="270" locator="53:47" valueType="t:Integer" value="6" xsi:type="Literal"/>
         </expression>
      </def>
      <def localId="275" locator="66:1-67:54" name="No JE primary series doses were administered" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="No JE primary series doses were administered"/>
            <a:t name="pseudocode" value="&quot;Vaccine type&quot; = &quot;JE vaccines&quot; and &quot;Type of dose&quot; = &quot;Primary series&quot;) = 0"/>
            <a:t name="code" value="No JE primary series doses were administered-111"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="275">
               <a:s>/*
@input: No JE primary series doses were administered
@pseudocode: Count of vaccines administered (where &quot;Vaccine type&quot; = &quot;JE vaccines&quot; and &quot;Type of dose&quot; = &quot;Primary series&quot;) = 0
@code: No JE primary series doses were administered-111
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
@decision: IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
@decision: IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;No JE primary series doses were administered&quot;:
  </a:s>
               <a:s r="276">
                  <a:s r="277">
                     <a:s>&quot;Number of JE Primary Series Doses Administered&quot;</a:s>
                  </a:s>
                  <a:s r="278"> = 0</a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="276" locator="67:3-67:54" xsi:type="Equal">
            <signature localId="279" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <signature localId="280" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <operand localId="277" locator="67:3-67:50" name="Number of JE Primary Series Doses Administered" xsi:type="ExpressionRef"/>
            <operand localId="278" locator="67:54" valueType="t:Integer" value="0" xsi:type="Literal"/>
         </expression>
      </def>
      <def localId="283" locator="76:1-77:48" name="Client's age is more than or equal to 6 months" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="Client's age is more than or equal to 6 months"/>
            <a:t name="pseudocode" value="&quot;Date of birth&quot; ≥ 6 months"/>
            <a:t name="code" value="Client's age is more than or equal to 6 months-41"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="283">
               <a:s>/*
@input: Client's age is more than or equal to 6 months
@pseudocode: Today's date − &quot;Date of birth&quot; ≥ 6 months
@code: Client's age is more than or equal to 6 months-41
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;Client's age is more than or equal to 6 months&quot;:
  </a:s>
               <a:s r="284">
                  <a:s r="286">
                     <a:s r="285">
                        <a:s>Encounter</a:s>
                     </a:s>
                     <a:s>.</a:s>
                     <a:s r="286">
                        <a:s>&quot;Current Patient Age In Months&quot;</a:s>
                     </a:s>
                  </a:s>
                  <a:s r="287"> >= 6</a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="284" locator="77:3-77:48" xsi:type="GreaterOrEqual">
            <signature localId="288" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <signature localId="289" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <operand localId="286" locator="77:3-77:43" name="Current Patient Age In Months" libraryName="Encounter" xsi:type="ExpressionRef"/>
            <operand localId="287" locator="77:48" valueType="t:Integer" value="6" xsi:type="Literal"/>
         </expression>
      </def>
      <def localId="292" locator="88:1-89:54" name="One JE primary series dose was administered" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="One JE primary series dose was administered"/>
            <a:t name="pseudocode" value="&quot;Vaccine type&quot; = &quot;JE vaccines&quot; and &quot;Type of dose&quot; = &quot;Primary series&quot;) = 1"/>
            <a:t name="code" value="One JE primary series dose was administered-111"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="292">
               <a:s>/*
@input: One JE primary series dose was administered
@pseudocode: Count of vaccines administered (where &quot;Vaccine type&quot; = &quot;JE vaccines&quot; and &quot;Type of dose&quot; = &quot;Primary series&quot;) = 1
@code: One JE primary series dose was administered-111
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
@decision: IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;One JE primary series dose was administered&quot;:
  </a:s>
               <a:s r="293">
                  <a:s r="294">
                     <a:s>&quot;Number of JE Primary Series Doses Administered&quot;</a:s>
                  </a:s>
                  <a:s r="295"> = 1</a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="293" locator="89:3-89:54" xsi:type="Equal">
            <signature localId="296" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <signature localId="297" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <operand localId="294" locator="89:3-89:50" name="Number of JE Primary Series Doses Administered" xsi:type="ExpressionRef"/>
            <operand localId="295" locator="89:54" valueType="t:Integer" value="1" xsi:type="Literal"/>
         </expression>
      </def>
      <def localId="304" locator="199:1-200:92" name="Date of Latest JE Dose" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="internal" value="Date of Latest JE Dose"/>
            <a:s r="304">
               <a:s>/*
@internal: Date of Latest JE Dose
*/
define &quot;Date of Latest JE Dose&quot;:
  </a:s>
               <a:s r="305">
                  <a:s>date from </a:s>
                  <a:s r="306">
                     <a:s>start of </a:s>
                     <a:s r="312">
                        <a:s r="311">
                           <a:s r="308">
                              <a:s r="307">
                                 <a:s>&quot;JE Doses Administered to Patient&quot;</a:s>
                              </a:s>
                              <a:s>.</a:s>
                              <a:s r="308">
                                 <a:s>mostRecent()</a:s>
                              </a:s>
                           </a:s>
                           <a:s>.</a:s>
                           <a:s r="311">
                              <a:s>occurrence</a:s>
                           </a:s>
                        </a:s>
                        <a:s>.</a:s>
                        <a:s r="312">
                           <a:s>toInterval()</a:s>
                        </a:s>
                     </a:s>
                  </a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="305" locator="200:3-200:92" xsi:type="DateFrom">
            <operand localId="306" locator="200:13-200:92" xsi:type="Start">
               <operand localId="312" locator="200:22-200:92" name="toInterval" libraryName="WC" xsi:type="FunctionRef">
                  <operand localId="311" locator="200:22-200:79" path="occurrence" xsi:type="Property">
                     <source localId="308" locator="200:22-200:68" name="mostRecent" libraryName="WC" xsi:type="FunctionRef">
                        <signature localId="309" xsi:type="ListTypeSpecifier">
                           <elementType localId="310" name="fhir:Immunization" xsi:type="NamedTypeSpecifier"/>
                        </signature>
                        <operand localId="307" locator="200:22-200:55" name="JE Doses Administered to Patient" xsi:type="ExpressionRef"/>
                     </source>
                  </operand>
               </operand>
            </operand>
         </expression>
      </def>
      <def localId="300" locator="98:1-100:72" name="The latest JE dose was administered less than 4 weeks ago" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="The latest JE dose was administered less than 4 weeks ago"/>
            <a:t name="pseudocode" value="&quot;Date and time of vaccination&quot; (where &quot;Vaccine type&quot; = &quot;JE vaccines&quot;) &lt; 4 weeks"/>
            <a:t name="code" value="The latest JE dose was administered less than 4 weeks ago-94"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="300">
               <a:s>/*
@input: The latest JE dose was administered less than 4 weeks ago
@pseudocode: Today's date − &quot;Date and time of vaccination&quot; (where &quot;Vaccine type&quot; = &quot;JE vaccines&quot;) &lt; 4 weeks
@code: The latest JE dose was administered less than 4 weeks ago-94
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;The latest JE dose was administered less than 4 weeks ago&quot;:
  </a:s>
               <a:s r="301">
                  <a:s r="315">
                     <a:s r="313">
                        <a:s>&quot;Date of Latest JE Dose&quot;</a:s>
                     </a:s>
                     <a:s> is not null</a:s>
                  </a:s>
                  <a:s>
    and </a:s>
                  <a:s r="316">
                     <a:s r="317">
                        <a:s>duration in weeks between </a:s>
                        <a:s r="318">
                           <a:s>&quot;Date of Latest JE Dose&quot;</a:s>
                        </a:s>
                        <a:s> and </a:s>
                        <a:s r="319">
                           <a:s>Today</a:s>
                        </a:s>
                     </a:s>
                     <a:s r="322"> &lt; 4</a:s>
                  </a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="301" locator="99:3-100:72" xsi:type="And">
            <operand localId="315" locator="99:3-99:38" xsi:type="Not">
               <operand localId="314" locator="99:3-99:38" xsi:type="IsNull">
                  <operand localId="313" locator="99:3-99:26" name="Date of Latest JE Dose" xsi:type="ExpressionRef"/>
               </operand>
            </operand>
            <operand localId="316" locator="100:9-100:72" xsi:type="Less">
               <signature localId="323" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
               <signature localId="324" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
               <operand localId="317" locator="100:9-100:68" precision="Week" xsi:type="DurationBetween">
                  <signature localId="320" name="t:Date" xsi:type="NamedTypeSpecifier"/>
                  <signature localId="321" name="t:Date" xsi:type="NamedTypeSpecifier"/>
                  <operand localId="318" locator="100:35-100:58" name="Date of Latest JE Dose" xsi:type="ExpressionRef"/>
                  <operand localId="319" locator="100:64-100:68" name="Today" xsi:type="ParameterRef"/>
               </operand>
               <operand localId="322" locator="100:72" valueType="t:Integer" value="4" xsi:type="Literal"/>
            </operand>
         </expression>
      </def>
      <def localId="327" locator="109:1-110:65" name="The latest JE dose was administered more than 4 weeks ago" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="The latest JE dose was administered more than 4 weeks ago"/>
            <a:t name="pseudocode" value="&quot;Date and time of vaccination&quot; (where &quot;Vaccine type&quot; = &quot;JE vaccines&quot;) ≥ 4 weeks"/>
            <a:t name="code" value="The latest JE dose was administered more than 4 weeks ago-94"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="327">
               <a:s>/*
@input: The latest JE dose was administered more than 4 weeks ago
@pseudocode: Today's date − &quot;Date and time of vaccination&quot; (where &quot;Vaccine type&quot; = &quot;JE vaccines&quot;) ≥ 4 weeks
@code: The latest JE dose was administered more than 4 weeks ago-94
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;The latest JE dose was administered more than 4 weeks ago&quot;:
  </a:s>
               <a:s r="328">
                  <a:s>not </a:s>
                  <a:s r="329">
                     <a:s>&quot;The latest JE dose was administered less than 4 weeks ago&quot;</a:s>
                  </a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="328" locator="110:3-110:65" xsi:type="Not">
            <operand localId="329" locator="110:7-110:65" name="The latest JE dose was administered less than 4 weeks ago" xsi:type="ExpressionRef"/>
         </expression>
      </def>
      <def localId="332" locator="119:1-120:54" name="Two JE primary series doses were administered" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="Two JE primary series doses were administered"/>
            <a:t name="pseudocode" value="&quot;Vaccine type&quot; = &quot;JE vaccines&quot; and &quot;Type of dose&quot; = &quot;Primary series&quot;) = 2"/>
            <a:t name="code" value="Two JE primary series doses were administered-111"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="332">
               <a:s>/*
@input: Two JE primary series doses were administered
@pseudocode: Count of vaccines administered (where &quot;Vaccine type&quot; = &quot;JE vaccines&quot; and &quot;Type of dose&quot; = &quot;Primary series&quot;) = 2
@code: Two JE primary series doses were administered-111
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;Two JE primary series doses were administered&quot;:
  </a:s>
               <a:s r="333">
                  <a:s r="334">
                     <a:s>&quot;Number of JE Primary Series Doses Administered&quot;</a:s>
                  </a:s>
                  <a:s r="335"> = 2</a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="333" locator="120:3-120:54" xsi:type="Equal">
            <signature localId="336" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <signature localId="337" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <operand localId="334" locator="120:3-120:50" name="Number of JE Primary Series Doses Administered" xsi:type="ExpressionRef"/>
            <operand localId="335" locator="120:54" valueType="t:Integer" value="2" xsi:type="Literal"/>
         </expression>
      </def>
      <def localId="340" locator="129:1-130:47" name="Client's age is less than 8 months" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="Client's age is less than 8 months"/>
            <a:t name="pseudocode" value="&quot;Date of birth&quot; &lt; 8 months"/>
            <a:t name="code" value="Client's age is less than 8 months-41"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="340">
               <a:s>/*
@input: Client's age is less than 8 months
@pseudocode: Today's date − &quot;Date of birth&quot; &lt; 8 months
@code: Client's age is less than 8 months-41
@decision: IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;Client's age is less than 8 months&quot;:
  </a:s>
               <a:s r="341">
                  <a:s r="343">
                     <a:s r="342">
                        <a:s>Encounter</a:s>
                     </a:s>
                     <a:s>.</a:s>
                     <a:s r="343">
                        <a:s>&quot;Current Patient Age In Months&quot;</a:s>
                     </a:s>
                  </a:s>
                  <a:s r="344"> &lt; 8</a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="341" locator="130:3-130:47" xsi:type="Less">
            <signature localId="345" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <signature localId="346" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <operand localId="343" locator="130:3-130:43" name="Current Patient Age In Months" libraryName="Encounter" xsi:type="ExpressionRef"/>
            <operand localId="344" locator="130:47" valueType="t:Integer" value="8" xsi:type="Literal"/>
         </expression>
      </def>
      <def localId="349" locator="139:1-140:48" name="Client's age is more than or equal to 8 months" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="Client's age is more than or equal to 8 months"/>
            <a:t name="pseudocode" value="&quot;Date of birth&quot; ≥ 8 months"/>
            <a:t name="code" value="Client's age is more than or equal to 8 months-41"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="349">
               <a:s>/*
@input: Client's age is more than or equal to 8 months
@pseudocode: Today's date − &quot;Date of birth&quot; ≥ 8 months
@code: Client's age is more than or equal to 8 months-41
@decision: IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;Client's age is more than or equal to 8 months&quot;:
  </a:s>
               <a:s r="350">
                  <a:s r="352">
                     <a:s r="351">
                        <a:s>Encounter</a:s>
                     </a:s>
                     <a:s>.</a:s>
                     <a:s r="352">
                        <a:s>&quot;Current Patient Age In Months&quot;</a:s>
                     </a:s>
                  </a:s>
                  <a:s r="353"> >= 8</a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="350" locator="140:3-140:48" xsi:type="GreaterOrEqual">
            <signature localId="354" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <signature localId="355" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <operand localId="352" locator="140:3-140:43" name="Current Patient Age In Months" libraryName="Encounter" xsi:type="ExpressionRef"/>
            <operand localId="353" locator="140:48" valueType="t:Integer" value="8" xsi:type="Literal"/>
         </expression>
      </def>
      <def localId="358" locator="151:1-152:66" name="No live vaccine was administered in the last 4 weeks" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="No live vaccine was administered in the last 4 weeks"/>
            <a:t name="pseudocode" value="&quot;Date and time of vaccination&quot; (where &quot;Vaccine type&quot; = &quot;JE vaccines&quot;) ≥ 4 weeks"/>
            <a:t name="code" value="No live vaccine was administered in the last 4 weeks-101"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="358">
               <a:s>/*
@input: No live vaccine was administered in the last 4 weeks
@pseudocode: Today's date − latest &quot;Date and time of vaccination&quot; (where &quot;Vaccine type&quot; = &quot;JE vaccines&quot;) ≥ 4 weeks
@code: No live vaccine was administered in the last 4 weeks-101
@decision: IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
@decision: IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;No live vaccine was administered in the last 4 weeks&quot;:
  </a:s>
               <a:s r="360">
                  <a:s r="359">
                     <a:s>Encounter</a:s>
                  </a:s>
                  <a:s>.</a:s>
                  <a:s r="360">
                     <a:s>&quot;No live vaccine was administered in the last 4 weeks&quot;</a:s>
                  </a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="360" locator="152:3-152:66" name="No live vaccine was administered in the last 4 weeks" libraryName="Encounter" xsi:type="ExpressionRef"/>
      </def>
      <def localId="363" locator="163:1-164:63" name="Live vaccine was administered in the last 4 weeks" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="Live vaccine was administered in the last 4 weeks"/>
            <a:t name="pseudocode" value="&quot;Date and time of vaccination&quot; (where &quot;Live vaccine&quot; = TRUE) &lt; 4 weeks"/>
            <a:t name="code" value="Live vaccine was administered in the last 4 weeks-92"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="363">
               <a:s>/*
@input: Live vaccine was administered in the last 4 weeks
@pseudocode: Today's date − latest &quot;Date and time of vaccination&quot; (where &quot;Live vaccine&quot; = TRUE) &lt; 4 weeks
@code: Live vaccine was administered in the last 4 weeks-92
@decision: IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
@decision: IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;Live vaccine was administered in the last 4 weeks&quot;:
  </a:s>
               <a:s r="365">
                  <a:s r="364">
                     <a:s>Encounter</a:s>
                  </a:s>
                  <a:s>.</a:s>
                  <a:s r="365">
                     <a:s>&quot;Live vaccine was administered in the last 4 weeks&quot;</a:s>
                  </a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="365" locator="164:3-164:63" name="Live vaccine was administered in the last 4 weeks" libraryName="Encounter" xsi:type="ExpressionRef"/>
      </def>
      <def localId="368" locator="173:1-174:47" name="Client's age is less than 9 months" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="Client's age is less than 9 months"/>
            <a:t name="pseudocode" value="&quot;Date of birth&quot; &lt; 9 months"/>
            <a:t name="code" value="Client's age is less than 9 months-41"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="368">
               <a:s>/*
@input: Client's age is less than 9 months
@pseudocode: Today's date − &quot;Date of birth&quot; &lt; 9 months
@code: Client's age is less than 9 months-41
@decision: IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;Client's age is less than 9 months&quot;:
  </a:s>
               <a:s r="369">
                  <a:s r="371">
                     <a:s r="370">
                        <a:s>Encounter</a:s>
                     </a:s>
                     <a:s>.</a:s>
                     <a:s r="371">
                        <a:s>&quot;Current Patient Age In Months&quot;</a:s>
                     </a:s>
                  </a:s>
                  <a:s r="372"> &lt; 9</a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="369" locator="174:3-174:47" xsi:type="Less">
            <signature localId="373" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <signature localId="374" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <operand localId="371" locator="174:3-174:43" name="Current Patient Age In Months" libraryName="Encounter" xsi:type="ExpressionRef"/>
            <operand localId="372" locator="174:47" valueType="t:Integer" value="9" xsi:type="Literal"/>
         </expression>
      </def>
      <def localId="377" locator="183:1-184:48" name="Client's age is more than or equal to 9 months" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="Client's age is more than or equal to 9 months"/>
            <a:t name="pseudocode" value="&quot;Date of birth&quot; ≥ 9 months"/>
            <a:t name="code" value="Client's age is more than or equal to 9 months-41"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="377">
               <a:s>/*
@input: Client's age is more than or equal to 9 months
@pseudocode: Today's date − &quot;Date of birth&quot; ≥ 9 months
@code: Client's age is more than or equal to 9 months-41
@decision: IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;Client's age is more than or equal to 9 months&quot;:
  </a:s>
               <a:s r="378">
                  <a:s r="380">
                     <a:s r="379">
                        <a:s>Encounter</a:s>
                     </a:s>
                     <a:s>.</a:s>
                     <a:s r="380">
                        <a:s>&quot;Current Patient Age In Months&quot;</a:s>
                     </a:s>
                  </a:s>
                  <a:s r="381"> >= 9</a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="378" locator="184:3-184:48" xsi:type="GreaterOrEqual">
            <signature localId="382" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <signature localId="383" name="t:Integer" xsi:type="NamedTypeSpecifier"/>
            <operand localId="380" locator="184:3-184:43" name="Current Patient Age In Months" libraryName="Encounter" xsi:type="ExpressionRef"/>
            <operand localId="381" locator="184:48" valueType="t:Integer" value="9" xsi:type="Literal"/>
         </expression>
      </def>
      <def localId="386" locator="193:1-194:47" name="One JE primary series doses were administered" context="Patient" accessLevel="Public">
         <annotation xsi:type="a:Annotation">
            <a:t name="input" value="One JE primary series doses were administered"/>
            <a:t name="pseudocode" value="&quot;Vaccine type&quot; = &quot;JE vaccines&quot; and &quot;Type of dose&quot; = &quot;Primary series&quot;) = 1"/>
            <a:t name="code" value="One JE primary series doses were administered-111"/>
            <a:t name="decision" value="IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)&#xa;JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority"/>
            <a:s r="386">
               <a:s>/*
@input: One JE primary series doses were administered
@pseudocode: Count of vaccines administered (where &quot;Vaccine type&quot; = &quot;JE vaccines&quot; and &quot;Type of dose&quot; = &quot;Primary series&quot;) = 1
@code: One JE primary series doses were administered-111
@decision: IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define &quot;One JE primary series doses were administered&quot;:
  </a:s>
               <a:s r="387">
                  <a:s>&quot;One JE primary series dose was administered&quot;</a:s>
               </a:s>
            </a:s>
         </annotation>
         <expression localId="387" locator="194:3-194:47" name="One JE primary series dose was administered" xsi:type="ExpressionRef"/>
      </def>
   </statements>
</library>
