Merge branch 'Eric_new_Python_API' of

git@git.metabarcoding.org:obitools/obitools3.git into
Eric_new_Python_API

Conflicts:
	python/obitools3/obidms/_obidms.pxd
	python/obitools3/obidms/_obidms.pyx
	python/obitools3/obidms/_obidmscolumn_bool.pyx
	python/obitools3/obidms/_obidmscolumn_str.pyx
	python/obitools3/obidms/_obiseq.pxd
	python/obitools3/obidms/_obiseq.pyx
	python/obitools3/obidms/_obitaxo.pxd
	python/obitools3/obidms/_obitaxo.pyx
	python/obitools3/obidms/_obiview.pxd
	python/obitools3/obidms/_obiview.pyx
	python/obitools3/obidms/_obiview_nuc_seq.pxd
	python/obitools3/obidms/_obiview_nuc_seq.pyx
	python/obitools3/obidms/_obiview_nuc_seq_qual.pxd
	python/obitools3/obidms/_obiview_nuc_seq_qual.pyx
	python/obitools3/obidms/capi/obialign.pxd
	python/obitools3/obidms/capi/obidmscolumn.pxd
	python/obitools3/obidms/capi/obitaxonomy.pxd
	python/obitools3/obidms/capi/obiview.pxd
This commit is contained in:
Celine Mercier
2017-02-20 14:55:36 +01:00
40 changed files with 2962 additions and 17 deletions

View File

@ -865,7 +865,7 @@ OBIDMS_column_p obi_create_column(OBIDMS_p dms,
obidebug(1, "\nCan't create column because of empty column name");
return NULL;
}
if ((data_type < 1) || (data_type > 8)) // TODO check in more robust way
if ((data_type < 1) || (data_type > 8)) // TODO check in more robust way and use macro define somewhere
{
obi_set_errno(OBICOL_UNKNOWN_ERROR);
obidebug(1, "\nCan't create column because of invalid data type");
@ -891,7 +891,7 @@ OBIDMS_column_p obi_create_column(OBIDMS_p dms,
// Build the indexer name if needed
if ((data_type == OBI_STR) || (data_type == OBI_SEQ) || (data_type == OBI_QUAL))
{
if ((indexer_name == NULL) || (strcmp(indexer_name, "") == 0))
if ((indexer_name == NULL) || (*indexer_name == 0))
{
final_indexer_name = obi_build_indexer_name(column_name, version_number);
if (final_indexer_name == NULL)

View File

@ -112,18 +112,22 @@ typedef struct OBIDMS_column_header {
* creating, opening or cloning an OBIDMS column.
*/
typedef struct OBIDMS_column {
OBIDMS_p dms; /**< A pointer to the OBIDMS structure to which the column belongs.
OBIDMS_p dms; /**< A pointer to the OBIDMS structure to
* which the column belongs.
*/
OBIDMS_column_directory_p column_directory; /**< A pointer to the OBIDMS column directory structure to which the column belongs.
OBIDMS_column_directory_p column_directory; /**< A pointer to the OBIDMS column directory
* structure to which the column belongs.
*/
OBIDMS_column_header_p header; /**< A pointer to the header of the column.
*/
Obi_indexer_p indexer; /**< A pointer to the blob indexer associated with the column if there is one.
Obi_indexer_p indexer; /**< A pointer to the blob indexer associated
* with the column if there is one.
*/
void* data; /**< A `void` pointer to the beginning of the data.
*
* @warning Never use this member directly outside of the code of the
* low level functions of the OBIDMS.
* @warning Never use this member directly outside
* of the code of the low level functions
* of the OBIDMS.
*/
bool writable; /**< Indicates if the column is writable or not.
* - `true` the column is writable
@ -132,7 +136,8 @@ typedef struct OBIDMS_column {
* A column is writable only by its creator
* until it closes it.
*/
size_t counter; /**< Indicates by how many threads/programs (TODO) the column is used.
size_t counter; /**< Indicates by how many threads/programs
* (TODO) the column is used.
*/
} OBIDMS_column_t, *OBIDMS_column_p;

View File

@ -12,6 +12,7 @@
#include "obilittlebigman.h"
// TODO this function does not seem to work properly
bool obi_is_little_endian() {
union { int entier;
char caractere[4] ;