Index: src/Actions/SelectionAction/Atoms/AllAtomsOfMoleculeAction.cpp
===================================================================
--- src/Actions/SelectionAction/Atoms/AllAtomsOfMoleculeAction.cpp	(revision fc5c3aecf61bf757b27c7c4f9060569db2b116c7)
+++ src/Actions/SelectionAction/Atoms/AllAtomsOfMoleculeAction.cpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -21,4 +21,5 @@
 
 #include "Descriptors/AtomSelectionDescriptor.hpp"
+#include "Descriptors/AtomOfMoleculeSelectionDescriptor.hpp"
 #include "atom.hpp"
 #include "molecule.hpp"
@@ -43,7 +44,7 @@
   getParametersfromValueStorage();
 
-  DoLog(1) && (Log() << Verbose(1) << "Selecting all atoms of molecule " << params.mol->getName() << "." << endl);
+  DoLog(1) && (Log() << Verbose(1) << "Selecting all atoms of currently selected molecule." << endl);
   std::vector<atom *> selectedAtoms = World::getInstance().getAllAtoms(AtomsBySelection());
-  World::getInstance().selectAtomsOfMolecule(params.mol);
+  World::getInstance().selectAllAtoms(AtomsByMoleculeSelection());
   return Action::state_ptr(new SelectionAllAtomsOfMoleculeState(selectedAtoms, params));
 }
@@ -52,5 +53,5 @@
   SelectionAllAtomsOfMoleculeState *state = assert_cast<SelectionAllAtomsOfMoleculeState*>(_state.get());
 
-  World::getInstance().unselectAtomsOfMolecule(state->params.mol);
+  World::getInstance().clearAtomSelection();
   BOOST_FOREACH(atom *_atom, state->selectedAtoms)
     World::getInstance().selectAtom(_atom);
@@ -62,5 +63,5 @@
   SelectionAllAtomsOfMoleculeState *state = assert_cast<SelectionAllAtomsOfMoleculeState*>(_state.get());
 
-  World::getInstance().selectAtomsOfMolecule(state->params.mol);
+  World::getInstance().selectAllAtoms(AtomsByMoleculeSelection());
 
   return Action::state_ptr(_state);
Index: src/Actions/SelectionAction/Atoms/AllAtomsOfMoleculeAction.def
===================================================================
--- src/Actions/SelectionAction/Atoms/AllAtomsOfMoleculeAction.def	(revision fc5c3aecf61bf757b27c7c4f9060569db2b116c7)
+++ src/Actions/SelectionAction/Atoms/AllAtomsOfMoleculeAction.def	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -12,9 +12,9 @@
 // ValueStorage by the token "Z" -> first column: int, Z, "Z"
 // "undefine" if no parameters are required, use (NODEFAULT) for each (undefined) default value
-#define paramtypes (const molecule *)
-#define paramtokens ("select-molecules-atoms")
-#define paramdescriptions ("molecule to select")
+#undef paramtypes
+#undef paramtokens
+#undef paramdescriptions
 #undef paramdefaults
-#define paramreferences (mol)
+#undef paramreferences
 
 #define statetypes (std::vector<atom*>)
@@ -30,4 +30,4 @@
 
 // finally the information stored in the ActionTrait specialization
-#define DESCRIPTION "select all atoms of a molecule"
+#define DESCRIPTION "select all atoms of currently selected molecules"
 #undef SHORTFORM
Index: src/Actions/SelectionAction/Atoms/NotAllAtomsOfMoleculeAction.cpp
===================================================================
--- src/Actions/SelectionAction/Atoms/NotAllAtomsOfMoleculeAction.cpp	(revision fc5c3aecf61bf757b27c7c4f9060569db2b116c7)
+++ src/Actions/SelectionAction/Atoms/NotAllAtomsOfMoleculeAction.cpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -21,4 +21,5 @@
 
 #include "Descriptors/AtomSelectionDescriptor.hpp"
+#include "Descriptors/AtomOfMoleculeSelectionDescriptor.hpp"
 #include "atom.hpp"
 #include "molecule.hpp"
@@ -43,7 +44,7 @@
   getParametersfromValueStorage();
 
-  DoLog(1) && (Log() << Verbose(1) << "Unselecting all atoms of molecule " << params.mol->getName() << "." << endl);
+  DoLog(1) && (Log() << Verbose(1) << "Unselecting all atoms of currently selected molecules." << endl);
   std::vector<atom *> unselectedAtoms = World::getInstance().getAllAtoms(!AtomsBySelection());
-  World::getInstance().unselectAtomsOfMolecule(params.mol);
+  World::getInstance().unselectAllAtoms(AtomsByMoleculeSelection());
   return Action::state_ptr(new SelectionNotAllAtomsOfMoleculeState(unselectedAtoms, params));
 }
@@ -52,5 +53,5 @@
   SelectionNotAllAtomsOfMoleculeState *state = assert_cast<SelectionNotAllAtomsOfMoleculeState*>(_state.get());
 
-  World::getInstance().selectAtomsOfMolecule(state->params.mol);
+  World::getInstance().selectAllAtoms(AllAtoms());
   BOOST_FOREACH(atom *_atom, state->unselectedAtoms)
     World::getInstance().unselectAtom(_atom);
@@ -60,7 +61,7 @@
 
 Action::state_ptr SelectionNotAllAtomsOfMoleculeAction::performRedo(Action::state_ptr _state){
-  SelectionNotAllAtomsOfMoleculeState *state = assert_cast<SelectionNotAllAtomsOfMoleculeState*>(_state.get());
+  //SelectionNotAllAtomsOfMoleculeState *state = assert_cast<SelectionNotAllAtomsOfMoleculeState*>(_state.get());
 
-  World::getInstance().unselectAtomsOfMolecule(state->params.mol);
+  World::getInstance().unselectAllAtoms(AtomsByMoleculeSelection());
 
   return Action::state_ptr(_state);
Index: src/Actions/SelectionAction/Atoms/NotAllAtomsOfMoleculeAction.def
===================================================================
--- src/Actions/SelectionAction/Atoms/NotAllAtomsOfMoleculeAction.def	(revision fc5c3aecf61bf757b27c7c4f9060569db2b116c7)
+++ src/Actions/SelectionAction/Atoms/NotAllAtomsOfMoleculeAction.def	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -12,9 +12,9 @@
 // ValueStorage by the token "Z" -> first column: int, Z, "Z"
 // "undefine" if no parameters are required, use (NODEFAULT) for each (undefined) default value
-#define paramtypes (const molecule*)
-#define paramtokens ("unselect-molecules-atoms")
-#define paramdescriptions ("molecule")
+#undef paramtypes
+#undef paramtokens
+#undef paramdescriptions
 #undef paramdefaults
-#define paramreferences (mol)
+#undef paramreferences
 
 #define statetypes (std::vector<atom*>)
@@ -30,4 +30,4 @@
 
 // finally the information stored in the ActionTrait specialization
-#define DESCRIPTION "unselect all atoms of a molecule"
+#define DESCRIPTION "unselect all atoms of currently selected molecules"
 #undef SHORTFORM
Index: src/Actions/SelectionAction/Molecules/MoleculeOfAtomAction.cpp
===================================================================
--- src/Actions/SelectionAction/Molecules/MoleculeOfAtomAction.cpp	(revision fc5c3aecf61bf757b27c7c4f9060569db2b116c7)
+++ src/Actions/SelectionAction/Molecules/MoleculeOfAtomAction.cpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -21,5 +21,5 @@
 
 #include "Descriptors/MoleculeDescriptor.hpp"
-#include "atom.hpp"
+#include "Descriptors/MoleculeOfAtomSelectionDescriptor.hpp"
 #include "Helpers/Log.hpp"
 #include "Helpers/Verbose.hpp"
@@ -43,6 +43,6 @@
 
   std::vector<molecule *> selectedMolecules = World::getInstance().getSelectedMolecules();
-  DoLog(1) && (Log() << Verbose(1) << "Selecting molecule to which " << params.Walker->getName() << " belongs." << endl);
-  World::getInstance().selectMoleculeOfAtom(params.Walker);
+  DoLog(1) && (Log() << Verbose(1) << "Selecting molecule to currently selected atoms." << endl);
+  World::getInstance().selectAllMolecules(MoleculesByAtomSelection());
   return Action::state_ptr(new SelectionMoleculeOfAtomState(selectedMolecules, params));
 }
@@ -59,7 +59,7 @@
 
 Action::state_ptr SelectionMoleculeOfAtomAction::performRedo(Action::state_ptr _state){
-  SelectionMoleculeOfAtomState *state = assert_cast<SelectionMoleculeOfAtomState*>(_state.get());
+  //SelectionMoleculeOfAtomState *state = assert_cast<SelectionMoleculeOfAtomState*>(_state.get());
 
-  World::getInstance().selectMoleculeOfAtom(state->params.Walker);
+  World::getInstance().selectAllMolecules(MoleculesByAtomSelection());
 
   return Action::state_ptr(_state);
Index: src/Actions/SelectionAction/Molecules/MoleculeOfAtomAction.def
===================================================================
--- src/Actions/SelectionAction/Molecules/MoleculeOfAtomAction.def	(revision fc5c3aecf61bf757b27c7c4f9060569db2b116c7)
+++ src/Actions/SelectionAction/Molecules/MoleculeOfAtomAction.def	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -11,9 +11,9 @@
 // ValueStorage by the token "Z" -> first column: int, Z, "Z"
 // "undefine" if no parameters are required, use (NODEFAULT) for each (undefined) default value
-#define paramtypes (const atom*)
-#define paramtokens ("select-molecule-of-atom")
-#define paramdescriptions ("one atom of desired molecule")
+#undef paramtypes
+#undef paramtokens
+#undef paramdescriptions
 #undef paramdefaults
-#define paramreferences (Walker)
+#undef paramreferences
 
 #define statetypes (std::vector<molecule*>)
@@ -25,8 +25,8 @@
 #define MENUPOSITION 11
 #define ACTIONNAME MoleculeOfAtom
-#define TOKEN "select-molecule-of-atom"
+#define TOKEN "select-atoms-molecules"
 
 
 // finally the information stored in the ActionTrait specialization
-#define DESCRIPTION "select a molecule to which a given atom belongs"
+#define DESCRIPTION "select all molecules of currently selected atoms"
 #undef SHORTFORM
Index: src/Actions/SelectionAction/Molecules/NotMoleculeOfAtomAction.cpp
===================================================================
--- src/Actions/SelectionAction/Molecules/NotMoleculeOfAtomAction.cpp	(revision fc5c3aecf61bf757b27c7c4f9060569db2b116c7)
+++ src/Actions/SelectionAction/Molecules/NotMoleculeOfAtomAction.cpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -21,5 +21,5 @@
 
 #include "Descriptors/MoleculeDescriptor.hpp"
-#include "atom.hpp"
+#include "Descriptors/MoleculeOfAtomSelectionDescriptor.hpp"
 #include "Helpers/Log.hpp"
 #include "Helpers/Verbose.hpp"
@@ -43,6 +43,6 @@
 
   std::vector<molecule *> unselectedMolecules = World::getInstance().getSelectedMolecules();
-  DoLog(1) && (Log() << Verbose(1) << "Unselecting molecule to which " << params.Walker->getName() << " belongs." << endl);
-  World::getInstance().unselectMoleculeOfAtom(params.Walker);
+  DoLog(1) && (Log() << Verbose(1) << "Unselecting molecule to currently selected atoms." << endl);
+  World::getInstance().unselectAllMolecules(MoleculesByAtomSelection());
   return Action::state_ptr(new SelectionNotMoleculeOfAtomState(unselectedMolecules, params));
 }
@@ -59,7 +59,7 @@
 
 Action::state_ptr SelectionNotMoleculeOfAtomAction::performRedo(Action::state_ptr _state){
-  SelectionNotMoleculeOfAtomState *state = assert_cast<SelectionNotMoleculeOfAtomState*>(_state.get());
+  //SelectionNotMoleculeOfAtomState *state = assert_cast<SelectionNotMoleculeOfAtomState*>(_state.get());
 
-  World::getInstance().unselectMoleculeOfAtom(state->params.Walker);
+  World::getInstance().unselectAllMolecules(MoleculesByAtomSelection());
 
   return Action::state_ptr(_state);
Index: src/Actions/SelectionAction/Molecules/NotMoleculeOfAtomAction.def
===================================================================
--- src/Actions/SelectionAction/Molecules/NotMoleculeOfAtomAction.def	(revision fc5c3aecf61bf757b27c7c4f9060569db2b116c7)
+++ src/Actions/SelectionAction/Molecules/NotMoleculeOfAtomAction.def	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -11,9 +11,9 @@
 // ValueStorage by the token "Z" -> first column: int, Z, "Z"
 // "undefine" if no parameters are required, use (NODEFAULT) for each (undefined) default value
-#define paramtypes (const atom*)
-#define paramtokens ("unselect-molecule-of-atom")
-#define paramdescriptions ("one atom of desired molecule")
+#undef paramtypes
+#undef paramtokens
+#undef paramdescriptions
 #undef paramdefaults
-#define paramreferences (Walker)
+#undef paramreferences
 
 #define statetypes (std::vector<molecule*>)
@@ -25,8 +25,8 @@
 #define MENUPOSITION 21
 #define ACTIONNAME NotMoleculeOfAtom
-#define TOKEN "unselect-molecule-of-atom"
+#define TOKEN "unselect-atoms-molecules"
 
 
 // finally the information stored in the ActionTrait specialization
-#define DESCRIPTION "unselect a molecule to which a given atom belongs"
+#define DESCRIPTION "unselect all molecules of currently selected atoms"
 #undef SHORTFORM
Index: src/Descriptors/AtomOfMoleculeSelectionDescriptor.cpp
===================================================================
--- src/Descriptors/AtomOfMoleculeSelectionDescriptor.cpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
+++ src/Descriptors/AtomOfMoleculeSelectionDescriptor.cpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -0,0 +1,64 @@
+/*
+ * Project: MoleCuilder
+ * Description: creates and alters molecular systems
+ * Copyright (C)  2010 University of Bonn. All rights reserved.
+ * Please see the LICENSE file or "Copyright notice" in builder.cpp for details.
+ */
+
+/*
+ * AtomOfMoleculeSelectionDescriptor.cpp
+ *
+ *  Created on: Dec 11, 2010
+ *      Author: heber
+ */
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include "Helpers/MemDebug.hpp"
+
+#include "Descriptors/AtomOfMoleculeSelectionDescriptor.hpp"
+#include "Descriptors/AtomOfMoleculeSelectionDescriptor_impl.hpp"
+
+#include "molecule.hpp"
+
+#include "Helpers/helpers.hpp"
+
+AtomOfMoleculeSelectionDescriptor_impl::AtomOfMoleculeSelectionDescriptor_impl(){}
+
+AtomOfMoleculeSelectionDescriptor_impl::~AtomOfMoleculeSelectionDescriptor_impl(){}
+
+bool AtomOfMoleculeSelectionDescriptor_impl::predicate(std::pair<atomId_t,atom*> atom){
+  return World::getInstance().isSelected(atom.second->getMolecule());
+}
+
+atom* AtomOfMoleculeSelectionDescriptor_impl::find(){
+  World &instance = World::getInstance();
+  for (World::MoleculeSelectionIterator iter = instance.beginMoleculeSelection();
+      iter != instance.endMoleculeSelection();
+      ++iter) {
+    if (iter->second->begin() != iter->second->end())
+      return *(iter->second->begin());
+  }
+  return 0;
+}
+
+std::vector<atom*> AtomOfMoleculeSelectionDescriptor_impl::findAll(){
+  std::vector<atom*> res;
+  World &instance = World::getInstance();
+  for (World::MoleculeSelectionIterator iter = instance.beginMoleculeSelection();
+      iter != instance.endMoleculeSelection();
+      ++iter) {
+    transform(iter->second->begin(),
+              iter->second->end(),
+              back_inserter(res),
+              _take<atom*,molecule::atomSet::value_type>::get);
+  }
+  return res;
+}
+
+AtomDescriptor AtomsByMoleculeSelection(){
+  return AtomDescriptor(AtomDescriptor::impl_ptr(new AtomOfMoleculeSelectionDescriptor_impl()));
+}
Index: src/Descriptors/AtomOfMoleculeSelectionDescriptor.hpp
===================================================================
--- src/Descriptors/AtomOfMoleculeSelectionDescriptor.hpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
+++ src/Descriptors/AtomOfMoleculeSelectionDescriptor.hpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -0,0 +1,15 @@
+/*
+ * AtomOfMoleculeSelectionDescriptor.hpp
+ *
+ *  Created on: Dec 11, 2010
+ *      Author: heber
+ */
+
+#ifndef ATOMOFMOLECULESELECTIONDESCRIPTOR_HPP_
+#define ATOMOFMOLECULESELECTIONDESCRIPTOR_HPP_
+
+#include "Descriptors/AtomDescriptor.hpp"
+
+AtomDescriptor AtomsByMoleculeSelection();
+
+#endif /* ATOMOFMOLECULESELECTIONDESCRIPTOR_HPP_ */
Index: src/Descriptors/AtomOfMoleculeSelectionDescriptor_impl.hpp
===================================================================
--- src/Descriptors/AtomOfMoleculeSelectionDescriptor_impl.hpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
+++ src/Descriptors/AtomOfMoleculeSelectionDescriptor_impl.hpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -0,0 +1,24 @@
+/*
+ * AtomOfMoleculeSelectionDescriptor_impl.hpp
+ *
+ *  Created on: Dec 11, 2010
+ *      Author: heber
+ */
+
+#ifndef ATOMOFMOLECULESELECTIONDESCRIPTOR_IMPL_HPP_
+#define ATOMOFMOLECULESELECTIONDESCRIPTOR_IMPL_HPP_
+
+#include "Descriptors/AtomDescriptor_impl.hpp"
+
+class AtomOfMoleculeSelectionDescriptor_impl : public AtomDescriptor_impl{
+public:
+  AtomOfMoleculeSelectionDescriptor_impl();
+  virtual ~AtomOfMoleculeSelectionDescriptor_impl();
+  bool predicate(std::pair<atomId_t,atom*> atom);
+protected:
+  // need to overide more than the standard methods to make this fast
+  virtual atom* find();
+  virtual std::vector<atom*> findAll();
+};
+
+#endif /* ATOMOFMOLECULESELECTIONDESCRIPTOR_IMPL_HPP_ */
Index: src/Descriptors/MoleculeOfAtomSelectionDescriptor.cpp
===================================================================
--- src/Descriptors/MoleculeOfAtomSelectionDescriptor.cpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
+++ src/Descriptors/MoleculeOfAtomSelectionDescriptor.cpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -0,0 +1,74 @@
+/*
+ * Project: MoleCuilder
+ * Description: creates and alters molecular systems
+ * Copyright (C)  2010 University of Bonn. All rights reserved.
+ * Please see the LICENSE file or "Copyright notice" in builder.cpp for details.
+ */
+
+/*
+ * MoleculeOfAtomSelectionDescriptor.cpp
+ *
+ *  Created on: Dec 11, 2010
+ *      Author: heber
+ */
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include "Helpers/MemDebug.hpp"
+
+#include "Descriptors/MoleculeOfAtomSelectionDescriptor.hpp"
+#include "Descriptors/MoleculeOfAtomSelectionDescriptor_impl.hpp"
+
+#include "Helpers/helpers.hpp"
+
+#include "molecule.hpp"
+#include "World.hpp"
+
+MoleculeOfAtomSelectionDescriptor_impl::MoleculeOfAtomSelectionDescriptor_impl(){}
+
+MoleculeOfAtomSelectionDescriptor_impl::~MoleculeOfAtomSelectionDescriptor_impl(){}
+
+bool MoleculeOfAtomSelectionDescriptor_impl::predicate(std::pair<moleculeId_t,molecule*> molecule){
+  for (molecule::const_iterator iter = molecule.second->begin();
+      iter != molecule.second->end();
+      ++iter) {
+    if (World::getInstance().isSelected(*iter))
+      return true;
+  }
+  return false;
+}
+
+molecule* MoleculeOfAtomSelectionDescriptor_impl::find(){
+  World &instance = World::getInstance();
+  for (World::AtomSelectionIterator iter = instance.beginAtomSelection();
+      iter != instance.endAtomSelection();
+      ++iter) {
+    if (iter->second->getMolecule() != NULL)
+      return iter->second->getMolecule();
+  }
+  return 0;
+}
+
+std::vector<molecule*> MoleculeOfAtomSelectionDescriptor_impl::findAll(){
+  std::vector<molecule*> res;
+  std::set<molecule*> temp;
+  std::pair< std::set<molecule*>::iterator, bool> inserter;
+  World &instance = World::getInstance();
+  for (World::AtomSelectionIterator iter = instance.beginAtomSelection();
+      iter != instance.endAtomSelection();
+      ++iter) {
+    if (iter->second->getMolecule() != NULL) {
+      inserter = temp.insert( iter->second->getMolecule() );
+      if (inserter.second)
+        res.push_back(iter->second->getMolecule());
+    }
+  }
+  return res;
+}
+
+MoleculeDescriptor MoleculesByAtomSelection(){
+  return MoleculeDescriptor(MoleculeDescriptor::impl_ptr(new MoleculeOfAtomSelectionDescriptor_impl()));
+}
Index: src/Descriptors/MoleculeOfAtomSelectionDescriptor.hpp
===================================================================
--- src/Descriptors/MoleculeOfAtomSelectionDescriptor.hpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
+++ src/Descriptors/MoleculeOfAtomSelectionDescriptor.hpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -0,0 +1,15 @@
+/*
+ * MoleculeOfAtomSelectionDescriptor.hpp
+ *
+ *  Created on: Dec 11, 2010
+ *      Author: heber
+ */
+
+#ifndef MOLECULEOFATOMSELECTIONDESCRIPTOR_HPP_
+#define MOLECULEOFATOMSELECTIONDESCRIPTOR_HPP_
+
+#include "Descriptors/MoleculeDescriptor.hpp"
+
+MoleculeDescriptor MoleculesByAtomSelection();
+
+#endif /* MOLECULEOFATOMSELECTIONDESCRIPTOR_HPP_ */
Index: src/Descriptors/MoleculeOfAtomSelectionDescriptor_impl.hpp
===================================================================
--- src/Descriptors/MoleculeOfAtomSelectionDescriptor_impl.hpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
+++ src/Descriptors/MoleculeOfAtomSelectionDescriptor_impl.hpp	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -0,0 +1,24 @@
+/*
+ * MoleculeOfAtomSelectionDescriptor_impl.hpp
+ *
+ *  Created on: Jul 16, 2010
+ *      Author: crueger
+ */
+
+#ifndef MOLECULEOFATOMSELECTIONDESCRIPTOR_IMPL_HPP_
+#define MOLECULEOFATOMSELECTIONDESCRIPTOR_IMPL_HPP_
+
+#include "Descriptors/MoleculeDescriptor_impl.hpp"
+
+class MoleculeOfAtomSelectionDescriptor_impl : public MoleculeDescriptor_impl{
+public:
+  MoleculeOfAtomSelectionDescriptor_impl();
+  virtual ~MoleculeOfAtomSelectionDescriptor_impl();
+  bool predicate(std::pair<moleculeId_t,molecule*> molecule);
+protected:
+  // need to overide more than the standard methods to make this fast
+  virtual molecule* find();
+  virtual std::vector<molecule*> findAll();
+};
+
+#endif /* MOLECULEOFATOMSELECTIONDESCRIPTOR_IMPL_HPP_ */
Index: src/Makefile.am
===================================================================
--- src/Makefile.am	(revision fc5c3aecf61bf757b27c7c4f9060569db2b116c7)
+++ src/Makefile.am	(revision c42e60ed725925e7ac0c237a354103f0a7089314)
@@ -84,6 +84,8 @@
 
   
-DESCRIPTORSOURCE = Descriptors/AtomDescriptor.cpp \
+DESCRIPTORSOURCE = \
+	Descriptors/AtomDescriptor.cpp \
   Descriptors/AtomIdDescriptor.cpp \
+  Descriptors/AtomOfMoleculeSelectionDescriptor.cpp \
   Descriptors/AtomSelectionDescriptor.cpp \
   Descriptors/AtomShapeDescriptor.cpp \
@@ -93,4 +95,5 @@
   Descriptors/MoleculeIdDescriptor.cpp \
   Descriptors/MoleculeNameDescriptor.cpp \
+  Descriptors/MoleculeOfAtomSelectionDescriptor.cpp \
   Descriptors/MoleculeOrderDescriptor.cpp \
   Descriptors/MoleculePtrDescriptor.cpp \
@@ -98,6 +101,8 @@
 				   
 
-DESCRIPTORHEADER = Descriptors/AtomDescriptor.hpp \
+DESCRIPTORHEADER = \
+	Descriptors/AtomDescriptor.hpp \
   Descriptors/AtomIdDescriptor.hpp \
+  Descriptors/AtomOfMoleculeSelectionDescriptor.hpp \
   Descriptors/AtomSelectionDescriptor.hpp \
   Descriptors/AtomShapeDescriptor.hpp \
@@ -107,7 +112,24 @@
   Descriptors/MoleculeIdDescriptor.hpp \
   Descriptors/MoleculeNameDescriptor.hpp \
+  Descriptors/MoleculeOfAtomSelectionDescriptor.hpp \
   Descriptors/MoleculeOrderDescriptor.hpp \
   Descriptors/MoleculePtrDescriptor.hpp \
-  Descriptors/MoleculeSelectionDescriptor.cpp
+  Descriptors/MoleculeSelectionDescriptor.hpp
+  
+DESCRIPTORIMPLHEADER = \
+	Descriptors/AtomDescriptor_impl.hpp \
+  Descriptors/AtomIdDescriptor_impl.hpp \
+  Descriptors/AtomOfMoleculeSelectionDescriptor_impl.hpp \
+  Descriptors/AtomSelectionDescriptor_impl.hpp \
+  Descriptors/AtomShapeDescriptor_impl.hpp \
+  Descriptors/AtomTypeDescriptor_impl.hpp \
+  Descriptors/MoleculeDescriptor_impl.hpp \
+  Descriptors/MoleculeFormulaDescriptor_impl.hpp \
+  Descriptors/MoleculeIdDescriptor_impl.hpp \
+  Descriptors/MoleculeNameDescriptor_impl.hpp \
+  Descriptors/MoleculeOfAtomSelectionDescriptor_impl.hpp \
+  Descriptors/MoleculeOrderDescriptor_impl.hpp \
+  Descriptors/MoleculePtrDescriptor_impl.hpp \
+  Descriptors/MoleculeSelectionDescriptor_impl.hpp
   
 THERMOSTATSOURCE = \
@@ -193,4 +215,5 @@
   ${SHAPEHEADER} \
   ${DESCRIPTORHEADER} \
+  ${DESCRIPTORIMPLHEADER} \
   ${THERMOSTATHEADER} \
   ${TESSELATIONHEADER} \
