Rosetta  2021.16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Types | Public Member Functions | Private Attributes | Friends | List of all members
core::id::NamedAtomID_Map< T > Class Template Reference

Map from Atom identifiers to contained values class. More...

#include <NamedAtomID_Map.hh>

Public Types

typedef std::map< std::string, T > AtomMap
 
typedef utility::vector1< AtomMapResidueMap
 
typedef T value_type
 
typedef AtomMap::mapped_type reference
 
typedef AtomMap::mapped_type const const_reference
 
typedef AtomMap::size_type size_type
 
typedef T Value
 
typedef AtomMap::mapped_type Reference
 
typedef AtomMap::mapped_type const ConstReference
 
typedef platform::Size Size
 

Public Member Functions

 NamedAtomID_Map ()
 Default constructor with no arguments (PyRosetta workaround) More...
 
 NamedAtomID_Map (Value const &default_value_a)
 Default constructor. More...
 
 NamedAtomID_Map (Size const n_res)
 Number of residues constructor. More...
 
 NamedAtomID_Map (Size const n_res, Value const &default_value_a)
 Number of residues constructor. More...
 
 ~NamedAtomID_Map ()=default
 Destructor. More...
 
void resize (Size const n_res)
 Resize to a given number of residues. More...
 
void resize (Size const, Size const )
 Resize the number of atoms of a residue and use the default fill value. More...
 
void resize (Size const, Size const, Value const &)
 Resize the number of atoms of a residue and use a specified fill value. More...
 
void fill ()
 Fill the map with the default fill value. More...
 
ConstReference get (NamedAtomID const &id) const
 Get the value for an NamedAtomID: Return default value if not present Phil changing this to be a non-resizing function. More...
 
void set (NamedAtomID const &id, Value const &value)
 Set the value for an NamedAtomID: Extend the map if necessary, filling with the default value. More...
 
void finalize ()
 Finalize after sizing all the vectors. More...
 
void shrink ()
 Shrink the vectors to remove unused capacity. More...
 
void swap (NamedAtomID_Map &s)
 swap( NamedAtomID_Map ) More...
 
void clear ()
 Clear the map. More...
 
void clear (Value const &default_value_a)
 Clear the map and set a new default value. More...
 
void update_sequence_numbering (Size const new_size, utility::vector1< Size > const &old2new)
 
Size size () const
 Size. More...
 
Size n_residue () const
 Number of residues (size) More...
 
Size n_atom (Size const i_res) const
 Number of atoms in a residue. More...
 
bool empty () const
 Empty? More...
 
Value const & default_value () const
 Default value. More...
 
void default_value (Value const &default_value_a)
 Set default value. More...
 
bool has (NamedAtomID const &id) const
 Is an element with this NamedAtomID present? More...
 
ConstReference operator[] (NamedAtomID const &id) const
 NamedAtomID_Map[ atom_id ] const. More...
 
Reference operator[] (NamedAtomID const &id)
 NamedAtomID_Map[ atom_id ]. More...
 
ConstReference operator() (NamedAtomID const &id) const
 NamedAtomID_Map( atom_id ) const. More...
 
Reference operator() (NamedAtomID const &id)
 NamedAtomID_Map( atom_id ) More...
 
ConstReference operator() (Size i_res, std::string const &atom) const
 NamedAtomID_Map( i_res, i_atom ) const. More...
 
Reference operator() (Size i_res, std::string const &atom)
 NamedAtomID_Map( i_res, i_atom ) More...
 
AtomMap const & operator[] (Size const i_res) const
 NamedAtomID_Map[ i_res ] const. More...
 
AtomMapoperator[] (Size const i_res)
 NamedAtomID_Map[ i_res ]. More...
 
AtomMap const & operator() (Size const i_res) const
 NamedAtomID_Map( i_res ) const. More...
 
AtomMapoperator() (Size const i_res)
 NamedAtomID_Map( i_res ) More...
 

Private Attributes

Value default_value_
 Default value. More...
 
ResidueMap res_map_
 Map from Atom identifiers to values. More...
 

Friends

template<typename TF >
void swap (NamedAtomID_Map< TF > &a, NamedAtomID_Map< TF > &b)
 swap( NamedAtomID_Map, NamedAtomID_Map ) More...
 
bool operator== (NamedAtomID_Map const &a, NamedAtomID_Map const &b)
 NamedAtomID_Map == NamedAtomID_Map. More...
 
bool operator!= (NamedAtomID_Map const &a, NamedAtomID_Map const &b)
 NamedAtomID_Map != NamedAtomID_Map. More...
 

Detailed Description

template<typename T>
class core::id::NamedAtomID_Map< T >

Map from Atom identifiers to contained values class.

Member Typedef Documentation

template<typename T>
typedef std::map< std::string, T > core::id::NamedAtomID_Map< T >::AtomMap
template<typename T>
typedef AtomMap::mapped_type const core::id::NamedAtomID_Map< T >::const_reference
template<typename T>
typedef AtomMap::mapped_type const core::id::NamedAtomID_Map< T >::ConstReference
template<typename T>
typedef AtomMap::mapped_type core::id::NamedAtomID_Map< T >::reference
template<typename T>
typedef AtomMap::mapped_type core::id::NamedAtomID_Map< T >::Reference
template<typename T>
typedef utility::vector1< AtomMap > core::id::NamedAtomID_Map< T >::ResidueMap
template<typename T>
typedef platform::Size core::id::NamedAtomID_Map< T >::Size
template<typename T>
typedef AtomMap::size_type core::id::NamedAtomID_Map< T >::size_type
template<typename T>
typedef T core::id::NamedAtomID_Map< T >::Value
template<typename T>
typedef T core::id::NamedAtomID_Map< T >::value_type

Constructor & Destructor Documentation

template<typename T>
core::id::NamedAtomID_Map< T >::NamedAtomID_Map ( )
inlineexplicit

Default constructor with no arguments (PyRosetta workaround)

template<typename T>
core::id::NamedAtomID_Map< T >::NamedAtomID_Map ( Value const &  default_value_a)
inlineexplicit

Default constructor.

template<typename T>
core::id::NamedAtomID_Map< T >::NamedAtomID_Map ( Size const  n_res)
inlineexplicit

Number of residues constructor.

template<typename T>
core::id::NamedAtomID_Map< T >::NamedAtomID_Map ( Size const  n_res,
Value const &  default_value_a 
)
inlineexplicit

Number of residues constructor.

template<typename T>
core::id::NamedAtomID_Map< T >::~NamedAtomID_Map ( )
inlinedefault

Destructor.

Member Function Documentation

template<typename T>
void core::id::NamedAtomID_Map< T >::clear ( )
inline

Clear the map.

template<typename T>
void core::id::NamedAtomID_Map< T >::clear ( Value const &  default_value_a)
inline

Clear the map and set a new default value.

template<typename T>
Value const& core::id::NamedAtomID_Map< T >::default_value ( ) const
inline

Default value.

template<typename T>
void core::id::NamedAtomID_Map< T >::default_value ( Value const &  default_value_a)
inline

Set default value.

template<typename T>
bool core::id::NamedAtomID_Map< T >::empty ( ) const
inline

Empty?

template<typename T>
void core::id::NamedAtomID_Map< T >::fill ( )
inline

Fill the map with the default fill value.

template<typename T>
void core::id::NamedAtomID_Map< T >::finalize ( )
inline

Finalize after sizing all the vectors.

template<typename T>
ConstReference core::id::NamedAtomID_Map< T >::get ( NamedAtomID const &  id) const
inline

Get the value for an NamedAtomID: Return default value if not present Phil changing this to be a non-resizing function.

template<typename T>
bool core::id::NamedAtomID_Map< T >::has ( NamedAtomID const &  id) const
inline

Is an element with this NamedAtomID present?

template<typename T>
Size core::id::NamedAtomID_Map< T >::n_atom ( Size const  i_res) const
inline

Number of atoms in a residue.

template<typename T>
Size core::id::NamedAtomID_Map< T >::n_residue ( ) const
inline

Number of residues (size)

template<typename T>
ConstReference core::id::NamedAtomID_Map< T >::operator() ( NamedAtomID const &  id) const
inline

NamedAtomID_Map( atom_id ) const.

template<typename T>
Reference core::id::NamedAtomID_Map< T >::operator() ( NamedAtomID const &  id)
inline

NamedAtomID_Map( atom_id )

template<typename T>
ConstReference core::id::NamedAtomID_Map< T >::operator() ( Size  i_res,
std::string const &  atom 
) const
inline

NamedAtomID_Map( i_res, i_atom ) const.

template<typename T>
Reference core::id::NamedAtomID_Map< T >::operator() ( Size  i_res,
std::string const &  atom 
)
inline

NamedAtomID_Map( i_res, i_atom )

template<typename T>
AtomMap const& core::id::NamedAtomID_Map< T >::operator() ( Size const  i_res) const
inline

NamedAtomID_Map( i_res ) const.

template<typename T>
AtomMap& core::id::NamedAtomID_Map< T >::operator() ( Size const  i_res)
inline

NamedAtomID_Map( i_res )

template<typename T>
ConstReference core::id::NamedAtomID_Map< T >::operator[] ( NamedAtomID const &  id) const
inline

NamedAtomID_Map[ atom_id ] const.

template<typename T>
Reference core::id::NamedAtomID_Map< T >::operator[] ( NamedAtomID const &  id)
inline

NamedAtomID_Map[ atom_id ].

template<typename T>
AtomMap const& core::id::NamedAtomID_Map< T >::operator[] ( Size const  i_res) const
inline

NamedAtomID_Map[ i_res ] const.

template<typename T>
AtomMap& core::id::NamedAtomID_Map< T >::operator[] ( Size const  i_res)
inline

NamedAtomID_Map[ i_res ].

template<typename T>
void core::id::NamedAtomID_Map< T >::resize ( Size const  n_res)
inline

Resize to a given number of residues.

template<typename T>
void core::id::NamedAtomID_Map< T >::resize ( Size  const,
Size  const 
)
inline

Resize the number of atoms of a residue and use the default fill value.

template<typename T>
void core::id::NamedAtomID_Map< T >::resize ( Size  const,
Size  const,
Value const &   
)
inline

Resize the number of atoms of a residue and use a specified fill value.

template<typename T>
void core::id::NamedAtomID_Map< T >::set ( NamedAtomID const &  id,
Value const &  value 
)
inline

Set the value for an NamedAtomID: Extend the map if necessary, filling with the default value.

template<typename T>
void core::id::NamedAtomID_Map< T >::shrink ( )
inline

Shrink the vectors to remove unused capacity.

Referenced by core::id::NamedAtomID_Map< NamedAtomID >::finalize().

template<typename T>
Size core::id::NamedAtomID_Map< T >::size ( ) const
inline
template<typename T>
void core::id::NamedAtomID_Map< T >::swap ( NamedAtomID_Map< T > &  s)
inline
template<typename T>
void core::id::NamedAtomID_Map< T >::update_sequence_numbering ( Size const  new_size,
utility::vector1< Size > const &  old2new 
)
inline

Should move to .cc? if old2new[pos] == 0 , that position's mapping is lost if old2new[1...old_size] doesnt cover all of [1...new_size], the missed positions will have res_map_[pos].empty()

Friends And Related Function Documentation

template<typename T>
bool operator!= ( NamedAtomID_Map< T > const &  a,
NamedAtomID_Map< T > const &  b 
)
friend
template<typename T>
bool operator== ( NamedAtomID_Map< T > const &  a,
NamedAtomID_Map< T > const &  b 
)
friend
template<typename T>
template<typename TF >
void swap ( NamedAtomID_Map< TF > &  a,
NamedAtomID_Map< TF > &  b 
)
friend

swap( NamedAtomID_Map, NamedAtomID_Map )

Member Data Documentation

template<typename T>
Value core::id::NamedAtomID_Map< T >::default_value_
private
template<typename T>
ResidueMap core::id::NamedAtomID_Map< T >::res_map_
private

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