Develop Biology
The language of life
bio::molecular::Surface Class Reference

#include <Surface.h>

+ Inheritance diagram for bio::molecular::Surface:
+ Collaboration diagram for bio::molecular::Surface:

Public Member Functions

 Surface (const Surface &toCopy)
 
virtual ~Surface ()
 
template<typename T >
Bind (T toBind, BondType bondType=bond_type::Temporary())
 
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (molecular, Surface) Surface(Name name
 
template<typename T >
Manage (T varPtr)
 
template<typename T >
operator+= (T toBind)
 
virtual physical::Waves operator-- ()
 
virtual chemical::Substanceoperator-= (Name toRelease)
 
virtual physical::Waveoperator-= (physical::Wave *toRelease)
 
virtual chemical::Substanceoperator-= (StandardDimension toRelease)
 
virtual Code Reify (physical::Symmetry *symmetry)
 
virtual chemical::SubstanceRelease (Name toRelease, physical::Perspective< StandardDimension > *perspective=NULL, BondType bondType=bond_type::Temporary())
 
virtual physical::WaveRelease (physical::Wave *toRelease, BondType bondType=bond_type::Temporary())
 
virtual chemical::SubstanceRelease (StandardDimension toRelease, physical::Perspective< StandardDimension > *perspective=NULL, BondType bondType=bond_type::Temporary())
 
virtual physical::Waves ReleaseAll (BondType bondType=bond_type::Temporary())
 
virtual void SetEnvironment (Molecule *environment)
 
virtual void SetPerspective (Molecule *perspective)
 
virtual physical::SymmetrySpin () const
 
template<typename T >
Use (T varPtr)
 
- Public Member Functions inherited from bio::molecular::Class< Surface >
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (chemical, Surface) Class(Surface *object
 
- Public Member Functions inherited from bio::chemical::Class< T >
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (physical, T) Class(T *object
 
- Public Member Functions inherited from bio::physical::Class< T >
 Class (T *object, Symmetry *symmetry=NULL)
 
virtual ~Class ()
 
virtual WaveAsWave ()
 
virtual const WaveAsWave () const
 
virtual WaveClone () const
 
T * Convert (Wave *wave)
 
virtual operator T* ()
 
virtual operator Wave * ()
 
- Public Member Functions inherited from bio::physical::Wave
 Wave (Symmetry *symmetry=NULL)
 
virtual ~Wave ()
 
virtual chemical::AtomAsAtom ()
 
virtual const chemical::AtomAsAtom () const
 
virtual WaveAsWave ()
 
virtual const WaveAsWave () const
 
virtual Code Attenuate (const Wave *other)
 
virtual WaveClone () const
 
virtual WaveDemodulate ()
 
virtual const WaveDemodulate () const
 
virtual Code Disattenuate (const Wave *other)
 
virtual Properties GetProperties () const
 
virtual WaveModulate (Wave *signal)
 
virtual Waveoperator* ()
 
virtual const Waveoperator* () const
 
virtual Waveoperator* (Wave *signal)
 
virtual void operator+ (const Wave *other)
 
virtual void operator- (const Wave *other)
 
virtual void operator| (Symmetry *symmetry)
 
virtual Code Reify (Symmetry *symmetry)
 
virtual SymmetrySpin () const
 
- Public Member Functions inherited from bio::physical::Identifiable< StandardDimension >
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (physical, Identifiable< StandardDimension >) explicit Identifiable(Perspective< StandardDimension > *perspective
 
void CloneIntoName (Name name)
 
- Public Member Functions inherited from bio::physical::Observer< Perspective< StandardDimension > >
 Observer (const Observer &other)
 
 Observer (Perspective *perspective=NULL)
 
virtual ~Observer ()
 
virtual PerspectiveGetPerspective () const
 
virtual void SetPerspective (Perspective *perspective)
 
- Public Member Functions inherited from bio::physical::Class< Identifiable< StandardDimension > >
 Class (Identifiable< StandardDimension > *object, Symmetry *symmetry=NULL)
 
virtual ~Class ()
 
virtual WaveAsWave ()
 
virtual const WaveAsWave () const
 
virtual WaveClone () const
 
Identifiable< StandardDimension > * Convert (Wave *wave)
 
virtual operator Identifiable< StandardDimension > * ()
 
virtual operator Wave * ()
 
- Public Member Functions inherited from bio::log::Writer
 Writer (Engine *logEngine, Filter logFilter)
 
virtual ~Writer ()
 
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (physical, Writer) Writer()
 
void ExternalLog (Filter logFilter, Level level, const char *format,...) const
 
EngineGetLogEngine ()
 
const EngineGetLogEngine () const
 
bool HasLogEngine () const
 
virtual void SetLogEngine (Engine *logEngine)
 
- Public Member Functions inherited from bio::physical::Filterable
 Filterable (Filter filter)
 
virtual ~Filterable ()
 
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (physical, Filterable) Filterable()
 
Filter GetFilter () const
 
virtual void InitializeImplementation (ByteStreams args)
 
virtual Code Reify (Symmetry *symmetry)
 
virtual void SetFilter (Filter filter)
 
virtual SymmetrySpin () const
 
- Public Member Functions inherited from bio::physical::Class< Filterable >
 Class (Filterable *object, Symmetry *symmetry=NULL)
 
virtual ~Class ()
 
virtual WaveAsWave ()
 
virtual const WaveAsWave () const
 
virtual WaveClone () const
 
FilterableConvert (Wave *wave)
 
virtual operator Filterable * ()
 
virtual operator Wave * ()
 
- Public Member Functions inherited from bio::physical::Class< Writer >
 Class (Writer *object, Symmetry *symmetry=NULL)
 
virtual ~Class ()
 
virtual WaveAsWave ()
 
virtual const WaveAsWave () const
 
virtual WaveClone () const
 
Writer * Convert (Wave *wave)
 
virtual operator Wave * ()
 
virtual operator Writer * ()
 
- Public Member Functions inherited from bio::chemical::Atom
 Atom (const Atom &other)
 
virtual ~Atom ()
 
template<typename T >
As ()
 
template<typename T >
const T As () const
 
template<typename T >
AsBonded ()
 
template<typename T >
const T AsBonded () const
 
template<typename T >
AsBondedQuantum ()
 
template<typename T >
const T AsBondedQuantum () const
 
virtual Code Attenuate (const Wave *other)
 
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (physical, Atom) explicit Atom()
 
template<typename T >
bool BreakBond (T toDisassociate, BondType type=bond_type::Unknown())
 
virtual Code Disattenuate (const Wave *other)
 
template<typename T >
bool FormBond (T toBond, BondType type=bond_type::Unknown())
 
BondsGetAllBonds ()
 
const BondsGetAllBonds () const
 
WaveGetBonded (Valence position)
 
const WaveGetBonded (Valence position) const
 
template<typename T >
Valence GetBondPosition () const
 
Valence GetBondPosition (AtomicNumber bondedId) const
 
Valence GetBondPosition (Name typeName) const
 
template<typename T >
BondType GetBondType () const
 
BondType GetBondType (Valence position) const
 
template<typename T >
 operator T ()
 
virtual Code Reify (physical::Symmetry *symmetry)
 
virtual physical::SymmetrySpin () const
 
- Public Member Functions inherited from bio::physical::Class< Atom >
 Class (Atom *object, Symmetry *symmetry=NULL)
 
virtual ~Class ()
 
virtual WaveAsWave ()
 
virtual const WaveAsWave () const
 
virtual WaveClone () const
 
Atom * Convert (Wave *wave)
 
virtual operator Atom * ()
 
virtual operator Wave * ()
 
- Public Member Functions inherited from bio::chemical::Substance
Substance Substance (const typename UnorderedMotif< Property >::Contents *properties, const typename UnorderedMotif< State >::Contents *states)
 
virtual ~Substance ()
 
 BIO_DEFAULT_IDENTIFIABLE_CONSTRUCTORS_WITH_CTOR_COMMON (chemical, Substance, &SubstancePerspective::Instance(), filter::Chemical()) BIO_DISAMBIGUATE_ALL_CLASS_METHODS(chemical
 
virtual void Disable ()
 
virtual void Enable ()
 
virtual bool IsEnabled () const
 
- Public Member Functions inherited from bio::chemical::Structure
 Structure ()
 
virtual ~Structure ()
 
- Public Member Functions inherited from bio::chemical::UnorderedStructureInterface
 UnorderedStructureInterface ()
 
virtual ~UnorderedStructureInterface ()
 
template<typename T >
Add (const T t)
 
template<typename T >
void Clear ()
 
template<typename T >
ContainerGetAll ()
 
template<typename T >
const ContainerGetAll () const
 
template<typename T >
std::vector< T > GetAllAsVector ()
 
template<typename T >
const std::vector< T > GetAllAsVector () const
 
template<typename T >
unsigned long GetCount () const
 
template<typename T >
unsigned int GetNumMatching (const Container *other) const
 
template<typename T >
std::string GetStringFrom (std::string separator=", ")
 
template<typename T >
bool Has (T content) const
 
template<typename T >
bool HasAll (const Container *contents) const
 
template<typename T >
void Import (const std::vector< T > &other)
 
template<typename T >
void Import (const UnorderedMotif< T > *other)
 
Code ImportAll (const physical::Wave *other)
 
template<typename T >
Remove (const T t)
 
- Public Member Functions inherited from bio::ThreadSafe
 ThreadSafe ()
 
 ThreadSafe (const ThreadSafe &toCopy)
 
virtual ~ThreadSafe ()
 
void LockThread () const
 
void UnlockThread () const
 
- Public Member Functions inherited from bio::chemical::LinearStructureInterface
 LinearStructureInterface ()
 
virtual ~LinearStructureInterface ()
 
template<typename T >
Emission ForEach (ExcitationBase *excitation)
 
template<typename T >
GetById (StandardDimension id)
 
template<typename T >
const T GetById (StandardDimension id) const
 
template<typename T >
GetByName (Name name)
 
template<typename T >
const T GetByName (Name name) const
 
template<typename T >
GetOrCreateById (StandardDimension id)
 
template<typename T >
GetOrCreateByName (Name name)
 
template<typename T >
Code Insert (T toAdd, const Position position=BOTTOM, const StandardDimension optionalPositionArg=0, const bool transferSubContents=false)
 
- Public Member Functions inherited from bio::chemical::Class< Substance >
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (physical, Substance) Class(Substance *object
 
- Public Member Functions inherited from bio::chemical::UnorderedMotif< Property >
 UnorderedMotif (const Contents *contents)
 
 UnorderedMotif (const UnorderedMotif< Property > *toCopy)
 
virtual ~UnorderedMotif ()
 
virtual Property AddImplementation (const Property content)
 
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (chemical, UnorderedMotif< Property >) UnorderedMotif()
 
virtual void ClearImplementation ()
 
virtual unsigned long GetCountImplementation () const
 
virtual unsigned int GetNumMatchingImplementation (const Container *other) const
 
virtual std::string GetStringFromImplementation (std::string separator=", ")
 
virtual bool HasAllImplementation (const Container *contents) const
 
virtual bool HasImplementation (const Property content) const
 
virtual void ImportImplementation (const UnorderedMotif< Property > *other)
 
virtual Property RemoveImplementation (const Property content)
 
- Public Member Functions inherited from bio::chemical::Class< UnorderedMotif< Property > >
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (physical, UnorderedMotif< Property >) Class(UnorderedMotif< Property > *object
 
- Public Member Functions inherited from bio::chemical::AbstractMotif
 AbstractMotif ()
 
virtual ~AbstractMotif ()
 
virtual void ClearImplementation ()
 
virtual ContainerGetAllImplementation ()
 
virtual const ContainerGetAllImplementation () const
 
virtual unsigned long GetCountImplementation () const
 
virtual std::string GetStringFromImplementation (std::string separator=", ")
 
virtual void ImportImplementation (const void *other)
 
- Public Member Functions inherited from bio::chemical::UnorderedMotif< State >
 UnorderedMotif (const Contents *contents)
 
 UnorderedMotif (const UnorderedMotif< State > *toCopy)
 
virtual ~UnorderedMotif ()
 
virtual State AddImplementation (const State content)
 
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (chemical, UnorderedMotif< State >) UnorderedMotif()
 
virtual void ClearImplementation ()
 
virtual unsigned long GetCountImplementation () const
 
virtual unsigned int GetNumMatchingImplementation (const Container *other) const
 
virtual std::string GetStringFromImplementation (std::string separator=", ")
 
virtual bool HasAllImplementation (const Container *contents) const
 
virtual bool HasImplementation (const State content) const
 
virtual void ImportImplementation (const UnorderedMotif< State > *other)
 
virtual State RemoveImplementation (const State content)
 
- Public Member Functions inherited from bio::chemical::Class< UnorderedMotif< State > >
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (physical, UnorderedMotif< State >) Class(UnorderedMotif< State > *object
 
- Public Member Functions inherited from bio::chemical::LinearMotif< Molecule * >
 LinearMotif (const Contents *contents, physical::Perspective< StandardDimension > *perspective=NULL)
 
 LinearMotif (const LinearMotif< Molecule * > &toCopy)
 
 LinearMotif (physical::Perspective< StandardDimension > *perspective=NULL)
 
virtual ~LinearMotif ()
 
virtual Molecule * AddImplementation (Molecule * content)
 
virtual Code Attenuate (const physical::Wave *other)
 
 BIO_DISAMBIGUATE_REQUIRED_CLASS_METHODS (chemical, LinearMotif< Molecule * >) BIO_DISAMBIGUATE_OPTIONAL_CLASS_METHODS(physical
 
virtual void ClearImplementation ()
 
virtual Molecule * CreateImplementation (StandardDimension id)
 
virtual Code Disattenuate (const physical::Wave *other)
 
virtual Emission ForEachImplementation (ExcitationBase *excitation)
 
virtual Molecule * GetByIdImplementation (StandardDimension id)
 
virtual const Molecule * GetByIdImplementation (StandardDimension id) const
 
virtual Molecule * GetByNameImplementation (Name name)
 
virtual const Molecule * GetByNameImplementation (Name name) const
 
virtual Molecule * GetOrCreateByIdImplementation (StandardDimension id)
 
virtual Molecule * GetOrCreateByNameImplementation (Name name)
 
virtual std::string GetStringFromImplementation (std::string separator=", ")
 
physical::Perspective< StandardDimension > * GetStructuralPerspective ()
 
const physical::Perspective< StandardDimension > * GetStructuralPerspective () const
 
virtual bool HasImplementation (const Molecule * &content) const
 
virtual void ImportImplementation (const LinearMotif< Molecule * > *other)
 
virtual Code InsertImplementation (Molecule * toAdd, const Position position=BOTTOM, const StandardDimension optionalPositionArg=0, const bool transferSubContents=false)
 
- Public Member Functions inherited from bio::chemical::Elementary< LinearMotif< Molecule * > >
 Elementary ()
 
 Elementary (const Properties properties)
 
virtual ~Elementary ()
 
void RegisterProperties (const Properties properties)
 
- Public Member Functions inherited from bio::chemical::Class< LinearMotif< Molecule * > >
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (physical, LinearMotif< Molecule * >) Class(LinearMotif< Molecule * > *object
 
- Public Member Functions inherited from bio::chemical::UnorderedMotif< Molecule * >
 UnorderedMotif (const Contents *contents)
 
 UnorderedMotif (const UnorderedMotif< Molecule * > *toCopy)
 
virtual ~UnorderedMotif ()
 
virtual Molecule * AddImplementation (const Molecule * content)
 
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (chemical, UnorderedMotif< Molecule * >) UnorderedMotif()
 
virtual void ClearImplementation ()
 
virtual unsigned long GetCountImplementation () const
 
virtual unsigned int GetNumMatchingImplementation (const Container *other) const
 
virtual std::string GetStringFromImplementation (std::string separator=", ")
 
virtual bool HasAllImplementation (const Container *contents) const
 
virtual bool HasImplementation (const Molecule * content) const
 
virtual void ImportImplementation (const UnorderedMotif< Molecule * > *other)
 
virtual Molecule * RemoveImplementation (const Molecule * content)
 
- Public Member Functions inherited from bio::chemical::Class< UnorderedMotif< Molecule * > >
 BIO_DISAMBIGUATE_ALL_CLASS_METHODS (physical, UnorderedMotif< Molecule * >) Class(UnorderedMotif< Molecule * > *object
 
- Public Member Functions inherited from bio::molecular::EnvironmentDependent< Molecule >
 EnvironmentDependent (Molecule *environment=NULL)
 
virtual ~EnvironmentDependent ()
 
virtual MoleculeGetEnvironment ()
 
virtual const MoleculeGetEnvironment () const
 
virtual void SetEnvironment (Molecule *environment)
 

Public Attributes

Moleculeenvironment
 
- Public Attributes inherited from bio::molecular::Class< Surface >
physical::Perspective< StandardDimension > Filter filter
 
physical::Perspective< StandardDimension > * perspective
 
- Public Attributes inherited from bio::chemical::Class< T >
physical::Perspective< StandardDimension > Filter filter = filter::Default()
 
physical::Perspective< StandardDimension > * perspective = NULL
 
- Public Attributes inherited from bio::physical::Identifiable< StandardDimension >
Id m_id
 
- Public Attributes inherited from bio::chemical::Class< Substance >
physical::Perspective< StandardDimension > Filter filter
 
physical::Perspective< StandardDimension > * perspective
 
- Public Attributes inherited from bio::chemical::Class< UnorderedMotif< Property > >
physical::Perspective< StandardDimension > Filter filter
 
physical::Perspective< StandardDimension > * perspective
 
- Public Attributes inherited from bio::chemical::Class< UnorderedMotif< State > >
physical::Perspective< StandardDimension > Filter filter
 
physical::Perspective< StandardDimension > * perspective
 
- Public Attributes inherited from bio::chemical::LinearMotif< Molecule * >
physical::Perspective< StandardDimension > * m_perspective
 
- Public Attributes inherited from bio::chemical::Class< LinearMotif< Molecule * > >
physical::Perspective< StandardDimension > Filter filter
 
physical::Perspective< StandardDimension > * perspective
 
- Public Attributes inherited from bio::chemical::Class< UnorderedMotif< Molecule * > >
physical::Perspective< StandardDimension > Filter filter
 
physical::Perspective< StandardDimension > * perspective
 

Additional Inherited Members

- Public Types inherited from bio::physical::Identifiable< StandardDimension >
typedef StandardDimension Id
 
typedef std::vector< IdIds
 
- Public Types inherited from bio::physical::Observer< Perspective< StandardDimension > >
typedef Perspective< StandardDimension > Perspective
 
- Public Types inherited from bio::chemical::UnorderedMotif< Property >
typedef physical::Arrangement< Property > Contents
 
- Public Types inherited from bio::chemical::UnorderedMotif< State >
typedef physical::Arrangement< State > Contents
 
- Public Types inherited from bio::chemical::LinearMotif< Molecule * >
typedef physical::Line Contents
 
- Public Types inherited from bio::chemical::UnorderedMotif< Molecule * >
typedef physical::Arrangement< Molecule * > Contents
 
- Static Public Member Functions inherited from bio::physical::Wave
static Properties GetResonanceBetween (const Wave *wave, const Properties &properties)
 
static Properties GetResonanceBetween (const Wave *wave1, const Wave *wave2)
 
static Properties GetResonanceBetween (ConstWaves waves)
 
- Static Public Member Functions inherited from bio::chemical::AbstractMotif
static Properties GetClassProperties ()
 
- Static Public Member Functions inherited from bio::chemical::LinearMotif< Molecule * >
static LinearMotif< Molecule * > Properties GetClassProperties ()
 
- Static Public Attributes inherited from bio::chemical::Elementary< LinearMotif< Molecule * > >
static bool hasRegistered
 
- Protected Member Functions inherited from bio::physical::Observer< Perspective< StandardDimension > >
virtual void InitializeImplementation (ByteStreams args)
 
- Protected Member Functions inherited from bio::VirtualBase
 VirtualBase ()
 
virtual ~VirtualBase ()
 
void Initialize (ByteStream arg1)
 
void Initialize (ByteStream arg1, ByteStream arg2)
 
void Initialize (ByteStream arg1, ByteStream arg2, ByteStream arg3)
 
void Initialize (ByteStreams args)
 
virtual void InitializeImplementation (ByteStreams args)=0
 
- Protected Member Functions inherited from bio::log::Writer
virtual void InitializeImplementation (ByteStreams args)
 
void Log (Level level, const char *format,...) const
 
- Protected Member Functions inherited from bio::chemical::Atom
virtual bool BreakBondImplementation (Wave *toDisassociate, AtomicNumber id, BondType type)
 
virtual bool FormBondImplementation (Wave *toBond, AtomicNumber id, BondType type)
 
- Protected Attributes inherited from bio::physical::Class< T >
T * m_object
 
- Protected Attributes inherited from bio::physical::Wave
Wavem_signal
 
Symmetrym_symmetry
 
- Protected Attributes inherited from bio::VirtualBase
bool m_hasBeenInitialized
 
- Protected Attributes inherited from bio::physical::Class< Identifiable< StandardDimension > >
Identifiable< StandardDimension > * m_object
 
- Protected Attributes inherited from bio::physical::Filterable
Filter m_filter
 
- Protected Attributes inherited from bio::physical::Class< Filterable >
Filterablem_object
 
- Protected Attributes inherited from bio::physical::Class< Writer >
Writer * m_object
 
- Protected Attributes inherited from bio::chemical::Atom
Bonds m_bonds
 
- Protected Attributes inherited from bio::physical::Class< Atom >
Atom * m_object
 
- Protected Attributes inherited from bio::chemical::AbstractMotif
Containerm_contents
 
- Protected Attributes inherited from bio::molecular::EnvironmentDependent< Molecule >
Moleculem_environment
 

Detailed Description

Surfaces can be thought of as variables for the Biology syntax. They either hold a single, Quantum value, or are composed of a complex array of Molecules. See Molecule.h for a more detailed explanation.

Definition at line 41 of file Surface.h.

Constructor & Destructor Documentation

◆ Surface()

bio::molecular::Surface::Surface ( const Surface toCopy)

Copying a Surface generates a new set of Molecules and will Clone any Manage()d Waves from toCopy into *this. NOTE: all Use()d Waves will be lost. Since *this does not control what it Uses, it cannot (will not) duplicate it. Keep in mind that *this will delete all Managed Waves on destruction.

Parameters
toCopy

Definition at line 30 of file Surface.cpp.

34 :
35 molecular::Class< Surface >(
36 this,
37 name,
42{
43
44}
Molecule * environment
Definition: Surface.h:59
Filter Molecular()
SymmetryType Variable()

◆ ~Surface()

bio::molecular::Surface::~Surface ( )
virtual

deletes all Manage()d Bonds.

Definition at line 76 of file Surface.cpp.

77{
78 chemical::Bond* bondBuffer;
79 for (
80 SmartIterator bnd = m_bonds.End();
81 !bnd.IsAtBeginning();
82 --bnd
83 )
84 {
85 bondBuffer = bnd;
86 if (bondBuffer->GetType() == bond_type::Manage())
87 {
88 //bypass BreakBondImplementation and just do it.
89 delete bondBuffer->GetBonded();
90 bondBuffer->Break();
91 }
92 }
93}
virtual SmartIterator End() const
Definition: Container.cpp:302
bool IsAtBeginning() const
BondType Manage()

References bio::chemical::Bond::Break(), bio::Container::End(), bio::chemical::Bond::GetBonded(), bio::chemical::Bond::GetType(), bio::SmartIterator::IsAtBeginning(), bio::chemical::Atom::m_bonds, and bio::bond_type::Manage().

Member Function Documentation

◆ Bind()

template<typename T >
T bio::molecular::Surface::Bind ( toBind,
BondType  bondType = bond_type::Temporary() 
)
inline

Binding, as opposed to permanent Bonding, forms a temporary association with the given Substance. Binding forms a Temporary Bond, allowing *this to be treated as the Bound Substance.

Template Parameters
T
Parameters
toBind
bondType
Returns
the Bound type.

Definition at line 129 of file Surface.h.

132 {
133 FormBond(
134 toBind,
135 bondType
136 );
137 return toBind;
138 }
bool FormBond(T toBond, BondType type=bond_type::Unknown())
Definition: Atom.h:237

References bio::chemical::Atom::FormBond().

Referenced by bio::genetic::FetchPlasmid::Activate(), and bio::genetic::Plasmid::TranscribeFor().

◆ BIO_DISAMBIGUATE_ALL_CLASS_METHODS()

bio::molecular::Surface::BIO_DISAMBIGUATE_ALL_CLASS_METHODS ( molecular  ,
Surface   
)

Ensure virtual methods point to Class implementations.

Parameters
name

◆ Manage()

template<typename T >
T bio::molecular::Surface::Manage ( varPtr)
inline

Create a Manage()d Bond with the given var. varPtr will be deleted when *this is destroyed. See Bonds.h for more on what Manage() does.

Template Parameters
T
Parameters
varPtr
Returns

Definition at line 97 of file Surface.h.

98 {
100 varPtr,
102 }

References bio::chemical::Atom::FormBond(), and bio::bond_type::Manage().

Referenced by bio::molecular::Molecule::Define().

◆ operator+=()

template<typename T >
T bio::molecular::Surface::operator+= ( toBind)
inline

Wrapper around Bind

Parameters
toBind
Returns
result of Bind(...)

Definition at line 200 of file Surface.h.

201 {
202 return Bind< T >(toBind);
203 }

◆ operator--()

physical::Waves bio::molecular::Surface::operator-- ( )
virtual

Wrapper around ReleaseAll

Returns
all Temporarily Bound Substances.

Definition at line 242 of file Surface.cpp.

243{
244 return ReleaseAll();
245}
virtual physical::Waves ReleaseAll(BondType bondType=bond_type::Temporary())
Definition: Surface.cpp:207

References ReleaseAll().

◆ operator-=() [1/3]

chemical::Substance * bio::molecular::Surface::operator-= ( Name  toRelease)
virtual

Wrapper around Release

Parameters
toRelease
Returns
result of Release

Definition at line 232 of file Surface.cpp.

233{
234 return Release(toRelease);
235}
virtual physical::Wave * Release(physical::Wave *toRelease, BondType bondType=bond_type::Temporary())
Definition: Surface.cpp:119

References Release().

◆ operator-=() [2/3]

physical::Wave * bio::molecular::Surface::operator-= ( physical::Wave toRelease)
virtual

Wrapper around Release

Parameters
toRelease
Returns
result of Release

Definition at line 227 of file Surface.cpp.

228{
229 return Release(toRelease);
230}

References Release().

◆ operator-=() [3/3]

chemical::Substance * bio::molecular::Surface::operator-= ( StandardDimension  toRelease)
virtual

Wrapper around Release

Parameters
toRelease
Returns
result of Release

Definition at line 237 of file Surface.cpp.

238{
239 return Release(toRelease);
240}

References Release().

◆ Reify()

Code bio::molecular::Surface::Reify ( physical::Symmetry symmetry)
virtual

Required method from Wave. See that class for details. Reconstruct *this from the given Symmetry.

Parameters
symmetry

Reimplemented from bio::chemical::Atom.

Definition at line 107 of file Surface.cpp.

108{
109 //TODO...
110 return code::NotImplemented();
111}
Code NotImplemented()

References bio::code::NotImplemented().

◆ Release() [1/3]

chemical::Substance * bio::molecular::Surface::Release ( Name  toRelease,
physical::Perspective< StandardDimension > *  perspective = NULL,
BondType  bondType = bond_type::Temporary() 
)
virtual

Breaks the Temporary Bond formed by Bind. NOTE: the given Substance could be Identifiable through some unknown Perspective, so this does actual string comparison. Unless a Perspective is given, in which case numeric comparison is done on the given Name.

Parameters
toRelease
perspective
bondType
Returns
the previously bound Substance or NULL.

Definition at line 145 of file Surface.cpp.

150{
151 chemical::Substance* ret = NULL;
152 chemical::Bond* bondBuffer;
153 for (
154 SmartIterator bnd = m_bonds.End();
155 !bnd.IsAtBeginning();
156 --bnd
157 )
158 {
159 bondBuffer = bnd;
160 if (bondBuffer->GetType() == bondType)
161 {
162 ret = ChemicalCast< chemical::Substance* >(bondBuffer->GetBonded());
164 continue);
165 BIO_SANITIZE_AT_SAFETY_LEVEL_2(ret->IsName(toRelease), ,
166 continue);
167 BIO_SANITIZE_AT_SAFETY_LEVEL_2(perspective && ret->GetPerspective() != perspective,
168 continue,);
169 bondBuffer->Break();
170 break;
171 }
172 }
173 return ret;
174}
#define BIO_SANITIZE_AT_SAFETY_LEVEL_2(test, success, failure)
physical::Perspective< StandardDimension > * perspective
Definition: Class.h:56

References BIO_SANITIZE_AT_SAFETY_LEVEL_2, bio::chemical::Bond::Break(), bio::Container::End(), bio::chemical::Bond::GetBonded(), bio::physical::Observer< PERSPECTIVE >::GetPerspective(), bio::chemical::Bond::GetType(), bio::SmartIterator::IsAtBeginning(), bio::chemical::Atom::m_bonds, and bio::molecular::Class< Surface >::perspective.

◆ Release() [2/3]

physical::Wave * bio::molecular::Surface::Release ( physical::Wave toRelease,
BondType  bondType = bond_type::Temporary() 
)
virtual

Breaks the Temporary Bond formed by Bind.

Parameters
toRelease
bondType
Returns
the previously bound Substance or NULL.

Definition at line 119 of file Surface.cpp.

123{
124 physical::Wave* ret = NULL;
125 chemical::Bond* bondBuffer;
126 for (
127 SmartIterator bnd = m_bonds.End();
128 !bnd.IsAtBeginning();
129 --bnd
130 )
131 {
132 bondBuffer = bnd;
133 if (bondBuffer->GetType() == bondType)
134 {
135 ret = ChemicalCast< physical::Wave* >(bondBuffer->GetBonded());
136 BIO_SANITIZE_AT_SAFETY_LEVEL_2(!ret || ret != toRelease,
137 continue,);
138 bondBuffer->Break();
139 break;
140 }
141 }
142 return ret;
143}

References BIO_SANITIZE_AT_SAFETY_LEVEL_2, bio::chemical::Bond::Break(), bio::Container::End(), bio::chemical::Bond::GetBonded(), bio::chemical::Bond::GetType(), bio::SmartIterator::IsAtBeginning(), and bio::chemical::Atom::m_bonds.

Referenced by operator-=().

◆ Release() [3/3]

chemical::Substance * bio::molecular::Surface::Release ( StandardDimension  toRelease,
physical::Perspective< StandardDimension > *  perspective = NULL,
BondType  bondType = bond_type::Temporary() 
)
virtual

Breaks the Temporary Bond formed by Bind. NOTE: the given Substance could be Identifiable through some unknown Perspective, so this does an unreliable numeric comparison. However, if a Perspective is given, we can be certain if the id we find is correct or not.

Parameters
toRelease
perspective
bondType
Returns
the previously bound Substance or NULL.

Definition at line 176 of file Surface.cpp.

181{
182 chemical::Substance* ret = NULL;
183 chemical::Bond* bondBuffer;
184 for (
185 SmartIterator bnd = m_bonds.End();
186 !bnd.IsAtBeginning();
187 --bnd
188 )
189 {
190 bondBuffer = bnd;
191 if (bondBuffer->GetType() == bondType)
192 {
193 ret = ChemicalCast< chemical::Substance* >(bondBuffer->GetBonded());
195 continue);
196 BIO_SANITIZE_AT_SAFETY_LEVEL_2(ret->IsId(toRelease), ,
197 continue);
198 BIO_SANITIZE_AT_SAFETY_LEVEL_2(perspective && ret->GetPerspective() != perspective,
199 continue,);
200 bondBuffer->Break();
201 break;
202 }
203 }
204 return ret;
205}

References BIO_SANITIZE_AT_SAFETY_LEVEL_2, bio::chemical::Bond::Break(), bio::Container::End(), bio::chemical::Bond::GetBonded(), bio::physical::Observer< PERSPECTIVE >::GetPerspective(), bio::chemical::Bond::GetType(), bio::SmartIterator::IsAtBeginning(), bio::chemical::Atom::m_bonds, and bio::molecular::Class< Surface >::perspective.

◆ ReleaseAll()

physical::Waves bio::molecular::Surface::ReleaseAll ( BondType  bondType = bond_type::Temporary())
virtual

Releases all Temporarily Bound Substances

Returns
all Temporarily Bound Substances

Definition at line 207 of file Surface.cpp.

208{
209 physical::Waves ret;
210 chemical::Bond* bondBuffer;
211 for (
212 SmartIterator bnd = m_bonds.End();
213 !bnd.IsAtBeginning();
214 --bnd
215 )
216 {
217 bondBuffer = bnd;
218 if (bondBuffer->GetType() == bondType)
219 {
220 ret.push_back(ChemicalCast< physical::Wave* >(bondBuffer->GetBonded()));
221 bondBuffer->Break();
222 }
223 }
224 return ret;
225}
std::vector< Wave * > Waves
Definition: Wave.h:48

References bio::chemical::Bond::Break(), bio::Container::End(), bio::chemical::Bond::GetBonded(), bio::chemical::Bond::GetType(), bio::SmartIterator::IsAtBeginning(), and bio::chemical::Atom::m_bonds.

Referenced by bio::genetic::FetchPlasmid::Activate(), bio::genetic::RegisterPlasmid::Activate(), operator--(), and bio::genetic::Plasmid::TranscribeFor().

◆ SetEnvironment()

void bio::molecular::Surface::SetEnvironment ( Molecule environment)
virtual

Sets both the m_environment and m_perspective and updates m_id.

Parameters
environment

Reimplemented from bio::molecular::EnvironmentDependent< Molecule >.

Definition at line 95 of file Surface.cpp.

References environment, bio::molecular::EnvironmentDependent< Molecule >::m_environment, and bio::physical::Observer< Perspective< StandardDimension > >::SetPerspective().

Referenced by SetPerspective().

◆ SetPerspective()

void bio::molecular::Surface::SetPerspective ( Molecule perspective)
virtual

Sets both the m_environment and m_perspective and updates m_id.

Parameters
perspectivea Molecule.

Definition at line 102 of file Surface.cpp.

103{
105}
virtual void SetEnvironment(Molecule *environment)
Definition: Surface.cpp:95

References bio::molecular::Class< Surface >::perspective, and SetEnvironment().

◆ Spin()

physical::Symmetry * bio::molecular::Surface::Spin ( ) const
virtual

Required method from Wave. See that class for details.

Returns
a Symmetrical image of *this

Reimplemented from bio::chemical::Atom.

Definition at line 113 of file Surface.cpp.

114{
115 //TODO...
116 return NULL;
117}

◆ Use()

template<typename T >
T bio::molecular::Surface::Use ( varPtr)
inline

Create a Use()d Bond with the given var. These will not be deleted by *this. See Bonds.h for more on what Use() does.

Template Parameters
T
Parameters
varPtr
Returns

Definition at line 113 of file Surface.h.

114 {
115 FormBond(
116 varPtr,
118 }
BondType Use()

References bio::chemical::Atom::FormBond(), and bio::bond_type::Use().

Referenced by bio::molecular::Molecule::Use().

Member Data Documentation

◆ environment

Molecule* bio::molecular::Surface::environment
Initial value:
= NULL
)

Definition at line 59 of file Surface.h.

Referenced by SetEnvironment().


The documentation for this class was generated from the following files: