1
/* $Id: hspfilter_queue.h,v 1.1 2009/06/01 13:54:56 maning Exp $
2
* ===========================================================================
5
* National Center for Biotechnology Information
7
* This software/database is a "United States Government Work" under the
8
* terms of the United States Copyright Act. It was written as part of
9
* the author's official duties as a United States Government employee and
10
* thus cannot be copyrighted. This software/database is freely available
11
* to the public for use. The National Library of Medicine and the U.S.
12
* Government have not placed any restriction on its use or reproduction.
14
* Although all reasonable efforts have been taken to ensure the accuracy
15
* and reliability of the software and data, the NLM and the U.S.
16
* Government do not and cannot warrant the performance or results that
17
* may be obtained by using this software or data. The NLM and the U.S.
18
* Government disclaim all warranties, express or implied, including
19
* warranties of performance, merchantability or fitness for any particular
22
* Please cite the author in any work or product based on this material.
24
* ===========================================================================
30
/** @file hspfilter_queue.h
31
* Implementation of HSPWriter in queue mode.
34
#ifndef ALGO_BLAST_CORE__HSPFILTER_QUEUE__H
35
#define ALGO_BLAST_CORE__HSPFILTER_QUEUE__H
37
#include <algo/blast/core/ncbi_std.h>
38
#include <algo/blast/core/blast_program.h>
39
#include <algo/blast/core/blast_options.h>
40
#include <algo/blast/core/blast_hspfilter.h>
41
#include <algo/blast/core/blast_hits.h>
42
#include <connect/ncbi_core.h>
48
/** Probably need no options */
49
typedef struct BlastHSPQueueParams {
50
EBlastProgramType program;/**< program type */
51
} BlastHSPQueueParams;
53
/** Sets up parameter set for use by queue.
54
* @param program Blast program type.[in]
55
* @param hit_options field hitlist_size and hsp_num_max needed, a pointer to
56
* this structure will be stored on resulting structure.[in]
57
* @param ext_options field compositionBasedStats needed here. [in]
58
* @param scoring_options gapped_calculation needed here. [in]
59
* @return the pointer to the allocated parameter
63
BlastHSPQueueParamsNew();
65
/** Deallocates the BlastHSPQueueParams structure passed in
66
* @param params structure to deallocate [in]
71
BlastHSPQueueParamsFree(BlastHSPQueueParams* params);
73
/** WriterInfo to create a default writer: the collecter
74
* @param params The queue parameters.
75
* @return pointer to WriterInfo
79
BlastHSPQueueInfoNew(BlastHSPQueueParams* params);
82
/** Read one HSP list from a queue of HSP lists. If the queue is empty, this
83
* function waits for more results to be written, unless results queue is
84
* already closed for writing.
85
* @param hsp_stream HSP list stream to read from [in]
86
* @param hsp_list_out The read HSP list. NULL, if there is nothing left
87
* in the queue to read.
88
* @return Status: success, error or end of reading.
92
BlastHSPQueueRead(void* data, BlastHSPList** hsp_list_out);
98
#endif /* !ALGO_BLAST_CORE__HSPFILTER_QUEUE__H */