Sequence alignment: if no sequence column is given and the view has the

type NUC_SEQS_VIEW, the default sequence column is aligned
This commit is contained in:
Celine Mercier
2016-11-29 16:52:41 +01:00
parent 98d0849653
commit 6f6099687d

View File

@ -51,7 +51,15 @@ int obi_align_one_column(Obiview_p seq_view, OBIDMS_column_p seq_column, const c
k = 0; k = 0;
if ((seq_column->header)->returned_data_type != OBI_SEQ) // If no sequence column is given and the view has the type NUC_SEQS_VIEW, the default sequence column is aligned
if ((seq_column == NULL) && (strcmp((seq_view->infos)->view_type, VIEW_TYPE_NUC_SEQS) == 0))
{
seq_column = obi_view_get_column(seq_view, NUC_SEQUENCE_COLUMN);
if (seq_column == NULL)
return -1;
}
// Check that the given sequence column contains nucleotide sequences
else if ((seq_column->header)->returned_data_type != OBI_SEQ)
{ {
obi_set_errno(OBI_ALIGN_ERROR); obi_set_errno(OBI_ALIGN_ERROR);
obidebug(1, "\nTrying to align a column of a different type than OBI_SEQ"); obidebug(1, "\nTrying to align a column of a different type than OBI_SEQ");