# Path: abstar/utils/cigar.py
# def make_cigar(germline_segment):
#     cigar = ''
#     if germline_segment.query_start > 0:
#         cigar += '{}S'.format(germline_segment.query_start)
#     if germline_segment.germline_start > 0:
#         cigar += '{}N'.format(germline_segment.germline_start)
#     cigar += make_alignment_cigar(germline_segment.realignment.aligned_query,
#                                   germline_segment.realignment.aligned_target)
#     return cigar


import collections
import json
import os
import traceback
import uuid
from abutils.utils import log
from .cigar import make_cigar
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
# BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#


from __future__ import absolute_import, division, print_function, unicode_literals





PARQUET_INCOMPATIBLE = ['json', ]
OUTPUT_SEPARATORS = {'airr': '\t',
                     'imgt': ',',
                     'tabular': ','}
OUTPUT_EXTENSIONS = {'airr': '.txt',
                     'json': '.json',
                     'imgt': '.csv',
                     'tabular': '.csv'}



def get_abstar_results(antibodies, pretty=False, padding=True, raw=False, keys=None):
    return [AbstarResult(ab, pretty, padding, raw, keys) for ab in antibodies]



# Path: abstar/utils/cigar.py
# def make_cigar(germline_segment):
#     cigar = ''
#     if germline_segment.query_start > 0:
#         cigar += '{}S'.format(germline_segment.query_start)
#     if germline_segment.germline_start > 0:
#         cigar += '{}N'.format(germline_segment.germline_start)
#     cigar += make_alignment_cigar(germline_segment.realignment.aligned_query,
#                                   germline_segment.realignment.aligned_target)
#     return cigar


# Path: abstar/utils/output.py
import collections
import json
import os
import traceback
import uuid
from abutils.utils import log
from .cigar import make_cigar

#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
# BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#


from __future__ import absolute_import, division, print_function, unicode_literals





PARQUET_INCOMPATIBLE = ['json', ]
OUTPUT_SEPARATORS = {'airr': '\t',
                     'imgt': ',',
                     'tabular': ','}
OUTPUT_EXTENSIONS = {'airr': '.txt',
                     'json': '.json',
                     'imgt': '.csv',
                     'tabular': '.csv'}



def get_abstar_results(antibodies, pretty=False, padding=True, raw=False, keys=None):
    return [AbstarResult(ab, pretty, padding, raw, keys) for ab in antibodies]



def get_abstar_result(ab, pretty=False, padding=True, raw=False, keys=None):