HL7v2.Type.CSU (HL7v2 v3.10.1)

Copy Markdown View Source

Channel Sensitivity and Units (CSU) -- HL7v2 composite data type.

Defines the sensitivity and units of measurement for a waveform channel. Used in CD (Channel Definition).

7 components:

  1. Channel Sensitivity (NM)
  2. Unit of Measure Identifier (ST)
  3. Unit of Measure Description (ST)
  4. Unit of Measure Coding System (ID) -- Table 0396
  5. Alternate Unit of Measure Identifier (ST)
  6. Alternate Unit of Measure Text (ST)
  7. Alternate Unit of Measure Coding System (ID) -- Table 0396

Summary

Functions

Encodes a CSU to a list of component strings.

Parses a CSU from a list of components.

Types

t()

@type t() :: %HL7v2.Type.CSU{
  alternate_unit_of_measure_coding_system: binary() | nil,
  alternate_unit_of_measure_identifier: binary() | nil,
  alternate_unit_of_measure_text: binary() | nil,
  channel_sensitivity: binary() | nil,
  unit_of_measure_coding_system: binary() | nil,
  unit_of_measure_description: binary() | nil,
  unit_of_measure_identifier: binary() | nil
}

Functions

encode(csu)

@spec encode(t() | nil) :: list()

Encodes a CSU to a list of component strings.

Examples

iex> HL7v2.Type.CSU.encode(%HL7v2.Type.CSU{channel_sensitivity: "0.1", unit_of_measure_identifier: "mV"})
["0.1", "mV"]

iex> HL7v2.Type.CSU.encode(nil)
[]

parse(components)

@spec parse(list()) :: t()

Parses a CSU from a list of components.

Examples

iex> HL7v2.Type.CSU.parse(["0.1", "mV", "millivolts", "UCUM"])
%HL7v2.Type.CSU{channel_sensitivity: "0.1", unit_of_measure_identifier: "mV", unit_of_measure_description: "millivolts", unit_of_measure_coding_system: "UCUM"}

iex> HL7v2.Type.CSU.parse([])
%HL7v2.Type.CSU{}