docs: def _read_metadata(self, f):
          """Read object metadata and update object information"""
  
          raw_data_index = types.Uint32.read(f, self.endianness)
  
          log.debug("Reading metadata for object %s", self.tdms_object.path)
  
          # Object has no data in this segment
          if raw_data_index == 0xFFFFFFFF:
              log.debug("Object has no data in this segment")
              self.has_data = False
              # Leave number_values and data_size as set previously,
              # as these may be re-used by later segments.
          # Data has same structure as previously
          elif raw_data_index == 0x00000000:
              log.debug(
                  "Object has same data structure as in the previous segment")
              self.has_data = True
          elif raw_data_index == 0x00001269 or raw_data_index == 0x00001369:
              # This is a DAQmx raw data segment.
              #    0x00001269 for segment containing Format Changing scaler.
              #    0x00001369 for segment containing Digital Line scaler.
              if raw_data_index == 0x00001369:
                  # special scaling for DAQ's digital input lines?
                  log.warning("DAQmx with Digital Line scaler has not tested")
  
              # DAQmx raw data format metadata has its own class
              self.has_data = True
              self.tdms_object.has_data = True
  
              info = self._read_metadata_mx(f)
              self.dimension = info.dimension
              self.data_type = info.data_type
              # DAQmx format has special chunking
              self.data_size = info.chunk_size
              self.number_values = info.chunk_size
              # segment reading code relies on a single consistent raw
              # data width so assert that there is only one.
              assert(len(info.raw_data_widths) == 1)
              self.raw_data_width = info.raw_data_widths[0]
              # fall through and read properties
          else:
              # Assume metadata format is legacy TDMS format.
              # raw_data_index gives the length of the index information.
              self.has_data = True
              self.tdms_object.has_data = True
  
              # Read the data type
              try:
                  self.data_type = types.tds_data_types[
                      types.Uint32.read(f, self.endianness)]
              except KeyError:
                  raise KeyError("Unrecognised data type")
              if (self.tdms_object.data_type is not None and
                      self.data_type != self.tdms_object.data_type):
                  raise ValueError(
                      "Segment object doesn't have the same data "
                      "type as previous segments.")
              else:
                  self.tdms_object.data_type = self.data_type
              log.debug("Object data type: %r", self.tdms_object.data_type)
  
              if (self.tdms_object.data_type.size is None and
                      self.tdms_object.data_type != types.String):
                  raise ValueError(
                      "Unsupported data type: %r" % self.tdms_object.data_type)
  
              # Read data dimension
              self.dimension = types.Uint32.read(f, self.endianness)
              # In TDMS version 2.0, 1 is the only valid value for dimension
              if self.dimension != 1:
                  log.warning("Data dimension is not 1")
  
              # Read number of values
              self.number_values = types.Uint64.read(f, self.endianness)
  
              # Variable length data types have total size
              if self.data_type in (types.String, ):
                  self.data_size = types.Uint64.read(f, self.endianness)
              else:
                  self.data_size = (
                      self.number_values *
                      self.data_type.size * self.dimension)
  
              log.debug(
                  "Object number of values in segment: %d", self.number_values)
  
          # Read data properties
          num_properties = types.Uint32.read(f, self.endianness)
          log.debug("Reading %d properties", num_properties)
          for i in range(num_properties):
              prop_name, value = read_property(f, self.endianness)
              self.tdms_object.properties[prop_name] = value