VTK  9.7.20260711
vtkAtom.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
11
12#ifndef vtkAtom_h
13#define vtkAtom_h
14
15#include "vtkCommonDataModelModule.h" // For export macro
16#include "vtkObject.h" // For macros, defines, etc
17#include "vtkVector.h" // For vtkVector3d, vtkVector3f
18
19VTK_ABI_NAMESPACE_BEGIN
20class vtkMolecule;
21
22class VTKCOMMONDATAMODEL_EXPORT vtkAtom
23{
24public:
25 void PrintSelf(ostream& os, vtkIndent indent);
26
30 vtkIdType GetId() const;
31
36
38
41 unsigned short GetAtomicNumber() const;
42 void SetAtomicNumber(unsigned short atomicNum);
44
46
49 void GetPosition(float pos[3]) const;
50 void GetPosition(double pos[3]) const;
51 void SetPosition(const float pos[3]);
52 void SetPosition(float x, float y, float z);
54 void SetPosition(const vtkVector3f& pos);
56
57protected:
58 friend class vtkMolecule;
59
61
64};
65
67{
68 return this->Id;
69}
70
72{
73 return this->Molecule;
74}
75
76VTK_ABI_NAMESPACE_END
77#endif
78// VTK-HeaderTest-Exclude: vtkAtom.h
vtkMolecule * GetMolecule()
Return the parent molecule of this atom.
Definition vtkAtom.h:71
void GetPosition(double pos[3]) const
Get/Set the position of this atom.
vtkIdType Id
Definition vtkAtom.h:63
vtkAtom(vtkMolecule *parent, vtkIdType id)
void SetPosition(float x, float y, float z)
Get/Set the position of this atom.
void PrintSelf(ostream &os, vtkIndent indent)
void GetPosition(float pos[3]) const
Get/Set the position of this atom.
friend class vtkMolecule
Definition vtkAtom.h:58
vtkMolecule * Molecule
Definition vtkAtom.h:62
unsigned short GetAtomicNumber() const
Get/Set the atomic number of this atom.
void SetPosition(const vtkVector3f &pos)
Get/Set the position of this atom.
void SetPosition(const float pos[3])
Get/Set the position of this atom.
void SetAtomicNumber(unsigned short atomicNum)
Get/Set the atomic number of this atom.
vtkVector3f GetPosition() const
Get/Set the position of this atom.
vtkIdType GetId() const
Return the Id used to identify this atom in the parent molecule.
Definition vtkAtom.h:66
a simple class to control print indentation
Definition vtkIndent.h:108
class describing a molecule
Definition vtkMolecule.h:84
int vtkIdType
Definition vtkType.h:363