When retrieving the header of a column, the version number of the column

wanted can now be provided.
This commit is contained in:
Celine Mercier
2015-11-10 13:30:10 +01:00
parent 8ce4f264aa
commit 410e2e02a0
4 changed files with 17 additions and 11 deletions

View File

@ -95,7 +95,7 @@ cdef class OBIDMS :
column_name = entry.stem
column_name_b = str2bytes(column_name)
dms[column_name] = {}
header = obi_column_get_header_from_name(self.pointer, column_name_b)
header = obi_column_get_header_from_name(self.pointer, column_name_b, -1)
data_type = bytes2str(name_data_type(header.data_type))
line_count = header.line_count
creation_date = bytes2str(obi_column_format_date(header.creation_date))
@ -137,7 +137,7 @@ cdef class OBIDMS :
# Get the header of the latest version of the column if
# some needed informations are not provided
if ((not data_type or not nb_elements_per_line) and not create) :
header = obi_column_get_header_from_name(self.pointer, column_name_b)
header = obi_column_get_header_from_name(self.pointer, column_name_b, version_number)
# Get the data type if not provided
if not data_type :

View File

@ -63,7 +63,8 @@ cdef extern from "obidmscolumn.h" nogil:
const_char_p column_name)
OBIDMS_column_header_p obi_column_get_header_from_name(OBIDMS_p dms,
const_char_p column_name)
const_char_p column_name,
obiversion_t version_number)
int obi_unmap_header(OBIDMS_column_header_p header)