HL7® FHIR® New Zealand Base Implementation Guide
3.1.0 - Release

HL7® FHIR® New Zealand Base Implementation Guide - Downloaded Version null See the Directory of published versions

## Extension: NZ Geocode

Official URL: http://hl7.org.nz/fhir/StructureDefinition/nz-geocode | Version: 0.1.0
Active as of 2020-07-20 | Computable Name: Nz_geocode
Copyright/Legal: HL7 New Zealand© 2020+; Licensed Under Creative Commons No Rights Reserved.

New Zealand Geocode. This uses a different datum from that defined in the HL7 FHIR specification for a Geocode.

Context of Use

This extension may be used on the following element(s)

- Element ID: `Address`

Example of extension

    <extension url = http://hl7.org.nz/fhir/StructureDefinition/nz-geocode>
         <extension url= "latitude">
          <valueDecimal value="-35.99">
        </extension>
        <extension url= "longitude">
          <valueDecimal value="174.47">
        </extension>
        <extension url="datumCode">
          <valueCodeableConcept>
            <coding>
              <system value="https://standards.digital.health.nz/ns/nz-datum-code"/>
              <code value="NZGD2000"/>
              <display value="Nz official datum, used by MoH address service"/>
            </coding>
          </valueCodeableConcept>
        </extension>
    </extension>

Example instances

Patient with geocoded address

Usage info

Usages:

- Use this Extension: Common NZ Address datatype
- Examples for this Extension: Patient/patient-nz-geocode

You can also check for usages in the FHIR IG Statistics

### Formal Views of Extension Content

Description of Profiles, Differentials, Snapshots, and how the XML and JSON presentations work.

- Differential Table
- Snapshot Table
- Statistics/References
- All

This structure is derived from Extension

Name | Flags | Card. | Type | Description & Constraints Filter: Bindings Constraints Obligations
--- | --- | --- | --- | ---
Extension |  | 0..* | Extension | NZ Geocode
extension |  | 2..* | Extension | Extension
Slices for extension |  |  |  | Content/Rules for all slices
extension:latitude |  | 1..1 | Extension | Extension
extension |  | 0..0 |  | Extension
url |  | 1..1 | uri | "latitude"
value[x] |  | 0..1 | decimal | Value of extension
extension:longitude |  | 1..1 | Extension | Extension
extension |  | 0..0 |  | Extension
url |  | 1..1 | uri | "longitude"
value[x] |  | 0..1 | decimal | Value of extension
extension:datumCode |  | 0..1 | Extension | Extension
extension |  | 0..0 |  | Extension
url |  | 1..1 | uri | "datumCode"
value[x] |  | 0..1 | CodeableConcept | Value of extension Binding: Datum code (preferred)
url |  | 1..1 | uri | "http://hl7.org.nz/fhir/StructureDefinition/nz-geocode"
value[x] |  | 0..0 |  | Value of extension
Documentation for this format

Name | Flags | Card. | Type | Description & Constraints Filter: Bindings Constraints Obligations
--- | --- | --- | --- | ---
Extension |  | 0..* | Extension | NZ Geocode
id |  | 0..1 | string | Unique id for inter-element referencing
Slices for extension |  | 2..* | Extension | Extension Slice: Unordered, Open by value:url
extension:latitude |  | 1..1 | Extension | Extension
id |  | 0..1 | string | Unique id for inter-element referencing
extension |  | 0..0 |  | Extension Slice: Unordered, Open by value:url
url |  | 1..1 | uri | "latitude"
value[x] |  | 0..1 | decimal | Value of extension
extension:longitude |  | 1..1 | Extension | Extension
id |  | 0..1 | string | Unique id for inter-element referencing
extension |  | 0..0 |  | Extension Slice: Unordered, Open by value:url
url |  | 1..1 | uri | "longitude"
value[x] |  | 0..1 | decimal | Value of extension
extension:datumCode |  | 0..1 | Extension | Extension
id |  | 0..1 | string | Unique id for inter-element referencing
extension |  | 0..0 |  | Extension Slice: Unordered, Open by value:url
url |  | 1..1 | uri | "datumCode"
value[x] |  | 0..1 | CodeableConcept | Value of extension Binding: Datum code (preferred)
url |  | 1..1 | uri | "http://hl7.org.nz/fhir/StructureDefinition/nz-geocode"
Documentation for this format

This structure is derived from Extension

Summary

Complex Extension: New Zealand Geocode. This uses a different datum from that defined in the HL7 FHIR specification for a Geocode.

- latitude: decimal: The latitude of the geocode
- longitude: decimal: The longitude of the geocode
- datumCode: CodeableConcept: The datum used for the lat/long

Differential View

This structure is derived from Extension

Name | Flags | Card. | Type | Description & Constraints Filter: Bindings Constraints Obligations
--- | --- | --- | --- | ---
Extension |  | 0..* | Extension | NZ Geocode
extension |  | 2..* | Extension | Extension
Slices for extension |  |  |  | Content/Rules for all slices
extension:latitude |  | 1..1 | Extension | Extension
extension |  | 0..0 |  | Extension
url |  | 1..1 | uri | "latitude"
value[x] |  | 0..1 | decimal | Value of extension
extension:longitude |  | 1..1 | Extension | Extension
extension |  | 0..0 |  | Extension
url |  | 1..1 | uri | "longitude"
value[x] |  | 0..1 | decimal | Value of extension
extension:datumCode |  | 0..1 | Extension | Extension
extension |  | 0..0 |  | Extension
url |  | 1..1 | uri | "datumCode"
value[x] |  | 0..1 | CodeableConcept | Value of extension Binding: Datum code (preferred)
url |  | 1..1 | uri | "http://hl7.org.nz/fhir/StructureDefinition/nz-geocode"
value[x] |  | 0..0 |  | Value of extension
Documentation for this format

Snapshot View

Name | Flags | Card. | Type | Description & Constraints Filter: Bindings Constraints Obligations
--- | --- | --- | --- | ---
Extension |  | 0..* | Extension | NZ Geocode
id |  | 0..1 | string | Unique id for inter-element referencing
Slices for extension |  | 2..* | Extension | Extension Slice: Unordered, Open by value:url
extension:latitude |  | 1..1 | Extension | Extension
id |  | 0..1 | string | Unique id for inter-element referencing
extension |  | 0..0 |  | Extension Slice: Unordered, Open by value:url
url |  | 1..1 | uri | "latitude"
value[x] |  | 0..1 | decimal | Value of extension
extension:longitude |  | 1..1 | Extension | Extension
id |  | 0..1 | string | Unique id for inter-element referencing
extension |  | 0..0 |  | Extension Slice: Unordered, Open by value:url
url |  | 1..1 | uri | "longitude"
value[x] |  | 0..1 | decimal | Value of extension
extension:datumCode |  | 0..1 | Extension | Extension
id |  | 0..1 | string | Unique id for inter-element referencing
extension |  | 0..0 |  | Extension Slice: Unordered, Open by value:url
url |  | 1..1 | uri | "datumCode"
value[x] |  | 0..1 | CodeableConcept | Value of extension Binding: Datum code (preferred)
url |  | 1..1 | uri | "http://hl7.org.nz/fhir/StructureDefinition/nz-geocode"
Documentation for this format

This structure is derived from Extension

Summary

Complex Extension: New Zealand Geocode. This uses a different datum from that defined in the HL7 FHIR specification for a Geocode.

- latitude: decimal: The latitude of the geocode
- longitude: decimal: The longitude of the geocode
- datumCode: CodeableConcept: The datum used for the lat/long

Other representations of profile: CSV, Excel, Schematron

#### Terminology Bindings

Path | Status | Usage | ValueSet | Version | Source
Extension.extension:datumCode.​value[x] | Base | preferred | Datum code | 📦1.0.0 | This IG

#### Constraints

Id | Grade | Path(s) | Description | Expression
ele-1 | error | **ALL** elements | All FHIR elements must have a @value or children | `hasValue() or (children().count() > id.count())`
ext-1 | error | **ALL** extensions | Must have either extensions or value[x], not both | `extension.exists() != value.exists()`