OpenStructure
Main Page
Related Pages
Modules
Namespaces
Data Structures
Files
Examples
File List
Globals
stage
include
ost
mol
coord_group.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-2011 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_COORD_GROUP_HH
20
#define OST_COORD_GROUP_HH
21
22
/*
23
Author: Ansgar Philippsen, Marco Biasini
24
*/
25
26
#include <vector>
27
#include <boost/shared_array.hpp>
28
29
#include "
atom_handle.hh
"
30
#include "
coord_source.hh
"
31
32
namespace
ost {
namespace
mol {
33
35
class
DLLEXPORT_OST_MOL
CoordGroupHandle
{
36
public
:
38
CoordGroupHandle
();
39
41
EntityHandle
GetEntity()
const
;
42
43
//EntityGroupHandle ExtractFromTo(int start, int end, int step=1);
44
//EntityGroupHandle ExtractEvery(int step, int start=0);
45
47
uint
GetAtomCount()
const
;
48
50
uint
GetFrameCount()
const
;
51
54
void
SetFramePositions(
uint
frame,
const
std::vector<geom::Vec3>& clist);
55
57
void
CopyFrame(
uint
frame);
58
60
void
Capture();
61
62
void
CaptureInto(
int
pos);
63
65
void
Capture(
uint
frame);
66
68
void
AddFrame(
const
std::vector<geom::Vec3>& clist);
69
70
void
AddFrames(
const
CoordGroupHandle
& cg);
72
void
SetAtomPos(
uint
frame,
AtomHandle
atom,
const
geom::Vec3
& pos);
73
75
geom::Vec3
GetAtomPos(
uint
frame,
AtomHandle
atom)
const
;
76
78
bool
IsValid()
const
;
79
81
operator
bool()
const
;
82
83
AtomHandleList
GetAtomList()
const
;
84
CoordFramePtr
GetFrame(
uint
frame)
const
;
85
88
CoordGroupHandle
Filter(
const
EntityView
& selected)
const
;
89
90
CoordGroupHandle
(
CoordSourcePtr
source);
91
private
:
92
void
CheckValidity()
const
;
93
94
CoordSourcePtr
source_;
95
};
96
97
// factory method
98
// create with a reference set of atoms and zero frames
99
DLLEXPORT_OST_MOL
CoordGroupHandle
CreateCoordGroup
(
const
AtomHandleList
& atoms);
100
101
}}
// ns
102
103
#endif
Generated on Thu Jun 14 2012 18:58:01 for OpenStructure by
1.8.1.1