19 #ifndef OST_SEQ_ALIGNMENT_HANDLE_HH
20 #define OST_SEQ_ALIGNMENT_HANDLE_HH
31 namespace ost {
namespace seq {
36 class AlignedColumnIterator;
63 int GetPos(
int seq_index,
int residue_index)
const;
110 const String& chain_name);
164 bool IsValid()
const {
return impl_.get()!=0; }
178 void CheckValidity()
const;
Provides access to a column in a aligned region or a sequence alignment.
represents a region in a sequence alignment
representation of a multiple sequence alignemnt consisting of two or more sequences
iterator begin() const
Column iterator start-point.
void RemoveSequence(int seq_index)
remove sequence at seq_index from alignment
void AttachView(int seq_index, const mol::EntityView &view)
attach view to given sequence
AlignmentHandle Copy() const
deep-copy multi sequence alignment
int GetCount() const
get number of sequences in alignment
int FindSequenceIndex(const String &name) const
ConstSequenceList GetSequences() const
Get list of sequences (read-only)
char GetOneLetterCode(int seq_index, int pos) const
AlignedColumnIterator iterator
void SetSequenceRole(int seq_index, const String &role)
AlignmentHandle(const impl::SequenceListImplPtr &impl)
const String & GetSequenceRole(int seq_index)
void Cut(int start, int end)
cut out half-closed interval start, end
int GetPos(int seq_index, int residue_index) const
Get position in sequence with index seq_index that corresponds to the given residue index.
mol::EntityViewPair GetMatchingBackboneViews(int idx0=0, int idx1=1) const
iterator end() const
Column iterator end-point.
int GetResidueIndex(int seq_index, int pos) const
Get residue index for seq_index and alignment position.
void ShiftRegion(int start, int end, int amount, int master=-1)
shift half-closed interval by amount
mol::ResidueView GetResidue(int seq_index, int pos) const
void SetSequenceOffset(int seq_index, int offset)
Real GetCoverage(int seq_index) const
get coverage of a specifi sequence
int GetLength() const
Get length of sequences in alignment.
void AttachView(int seq_index, const mol::EntityView &view, const String &chain_name)
attach view to given sequence
void SetSequenceName(int seq_index, const String &name)
set name of sequence
AlignedColumn operator[](int index) const
get aligned column at index
ConstSequenceHandle FindSequence(const String &name) const
find sequence by name.
void AddSequence(const ConstSequenceHandle &sequence)
Add new sequence to multiple sequence alignment.
AlignedRegion MakeRegion(int start, int n, int master=-1) const
create an aligned region.
String ToString(int width=80) const
Convert multiple sequence alignment to string.
bool operator==(const AlignmentHandle &rhs) const
ConstSequenceHandle GetSequence(int seq_id) const
Get sequence with given index.
void Replace(const AlignedRegion &rhs, int start, int end)
Replace part of an alignment.
bool operator!=(const AlignmentHandle &rhs) const
int GetSequenceOffset(int seq_index)
list of immutable sequences.
pointer_it< T > end(const std::vector< T > &values)
std::pair< EntityView, EntityView > EntityViewPair
std::vector< SequenceImplPtr > SequenceList
boost::shared_ptr< SequenceListImpl > SequenceListImplPtr
std::vector< AlignmentHandle > AlignmentList
AlignmentHandle DLLEXPORT_OST_SEQ AlignmentFromSequenceList(const SequenceList &seq_list)
convert alignment from sequence list
AlignmentHandle DLLEXPORT_OST_SEQ CreateAlignment()
#define DLLEXPORT_OST_SEQ