/usr/include/libMUSCLE-3.7/libMUSCLE/diaglist.h is in libmuscle-3.7-dev 3.7+4565-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 | #ifndef diaglist_h
#define diaglist_h
namespace muscle {
const unsigned EMPTY = (unsigned) ~0;
const unsigned MAX_DIAGS = 1024;
struct Diag
{
unsigned m_uStartPosA;
unsigned m_uStartPosB;
unsigned m_uLength;
};
struct Rect
{
unsigned m_uStartPosA;
unsigned m_uStartPosB;
unsigned m_uLengthA;
unsigned m_uLengthB;
};
class DiagList
{
public:
DiagList()
{
m_uCount = 0;
}
~DiagList()
{
Free();
}
public:
// Creation
void Clear()
{
Free();
}
void FromPath(const PWPath &Path);
void Add(const Diag &d);
void Add(unsigned uStartPosA, unsigned uStartPosB, unsigned uLength);
void DeleteIncompatible();
// Accessors
unsigned GetCount() const
{
return m_uCount;
}
const Diag &Get(unsigned uIndex) const;
// Operations
void Sort();
void Copy(const DiagList &DL);
// Query
// returns true iff given diagonal is included in the list
// in whole or in part.
bool NonZeroIntersection(const Diag &d) const;
bool IsSorted() const;
// Diagnostics
void LogMe() const;
private:
void Free()
{
m_uCount = 0;
}
private:
unsigned m_uCount;
Diag m_Diags[MAX_DIAGS];
};
unsigned DiagOverlap(const Diag &d1, const Diag &d2);
unsigned DiagOverlapA(const Diag &d1, const Diag &d2);
unsigned DiagOverlapB(const Diag &d1, const Diag &d2);
unsigned DiagBreak(const Diag &d1, const Diag &d2);
bool DiagCompatible(const Diag &d1, const Diag &d2);
void CheckDiags(const ProfPos *PA, unsigned uLengthA, const ProfPos *PB,
unsigned uLengthB, const MSA &msaA, const MSA &msaB, const PWPath &Path);
void FindDiags(const ProfPos *PX, unsigned uLengthX, const ProfPos *PY,
unsigned uLengthY, DiagList &DL);
void FindDiagsNuc(const ProfPos *PX, unsigned uLengthX, const ProfPos *PY,
unsigned uLengthY, DiagList &DL);
void MergeDiags(DiagList &DL);
} // namespace muscle
#endif // diaglist_h
|