OpenStructure
Loading...
Searching...
No Matches
aligned_column.hh
Go to the documentation of this file.
1//------------------------------------------------------------------------------
2// This file is part of the OpenStructure project <www.openstructure.org>
3//
4// Copyright (C) 2008-2020 by the OpenStructure authors
5//
6// This library is free software; you can redistribute it and/or modify it under
7// the terms of the GNU Lesser General Public License as published by the Free
8// Software Foundation; either version 3.0 of the License, or (at your option)
9// any later version.
10// This library is distributed in the hope that it will be useful, but WITHOUT
11// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12// FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
13// details.
14//
15// You should have received a copy of the GNU Lesser General Public License
16// along with this library; if not, write to the Free Software Foundation, Inc.,
17// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18//------------------------------------------------------------------------------
19#ifndef OST_SEQ_ALIGNED_COLUMN_HH
20#define OST_SEQ_ALIGNED_COLUMN_HH
21
22/*
23 Author: Marco Biasini
24 */
27namespace ost { namespace seq {
28
32public:
33 AlignedColumn(const AlignmentHandle& aln, int index);
39 int GetIndex() const;
40
41 char operator[](int row) const;
42
46 int GetResidueIndex(int row) const;
47
51 int GetRowCount() const;
52
57private:
58 void CheckRowValidity(int row) const;
59
60 AlignmentHandle aln_;
61 int index_;
62};
63
64DLLEXPORT_OST_SEQ std::ostream& operator<<(std::ostream& os,
65 const AlignedColumn& col);
66
67}}
68
69#endif
Provides access to a column in a aligned region or a sequence alignment.
char operator[](int row) const
int GetRowCount() const
get number of rows
AlignedColumn(const AlignmentHandle &aln, int index)
int GetResidueIndex(int row) const
get residue index at row
AlignedColumn()
construct empty (invalid) aligned column
mol::ResidueView GetResidue(int row) const
get residue at row
int GetIndex() const
get index of column
representation of a multiple sequence alignemnt consisting of two or more sequences
DLLEXPORT_OST_SEQ std::ostream & operator<<(std::ostream &os, const AlignedColumn &col)
Definition base.dox:1
#define DLLEXPORT_OST_SEQ