def _createItem(self):
    with self.xsocsH5 as h5f:
        entries = h5f.entries()
        entry = entries[0]
        scan_positions = h5f.scan_positions(entry)
        pathTpl = ((self.path + '/') + '{0}')
        with self:
            itemPath = pathTpl.format('pos_0')
            self._set_array_data(itemPath, scan_positions.pos_0)
            itemPath = pathTpl.format('pos_1')
            self._set_array_data(itemPath, scan_positions.pos_1)
            itemPath = pathTpl.format('motor_0')
            self._set_scalar_data(itemPath, scan_positions.motor_0)
            itemPath = pathTpl.format('motor_1')
            self._set_scalar_data(itemPath, scan_positions.motor_1)
            itemPath = pathTpl.format('n_0')
            self._set_scalar_data(itemPath, scan_positions.shape[0])
            itemPath = pathTpl.format('n_1')
            self._set_scalar_data(itemPath, scan_positions.shape[1])
def _createItem(self):
    with self.xsocsH5 as h5f:
        entries = h5f.entries()
        entry = entries[0]
        scan_positions = h5f.scan_positions(entry)
        pathTpl = ((self.path + '/') + '{0}')
        with self:
            itemPath = pathTpl.format('pos_0')
            self._set_array_data(itemPath, scan_positions.pos_0)
            itemPath = pathTpl.format('pos_1')
            self._set_array_data(itemPath, scan_positions.pos_1)
            itemPath = pathTpl.format('motor_0')
            self._set_scalar_data(itemPath, scan_positions.motor_0)
            itemPath = pathTpl.format('motor_1')
            self._set_scalar_data(itemPath, scan_positions.motor_1)
            itemPath = pathTpl.format('n_0')
            self._set_scalar_data(itemPath, scan_positions.shape[0])
            itemPath = pathTpl.format('n_1')
            self._set_scalar_data(itemPath, scan_positions.shape[1])