ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/branches/new_design/OOPSE-4/src/UseTheForce/ForceFieldFactory.cpp
(Generate patch)

Comparing branches/new_design/OOPSE-4/src/UseTheForce/ForceFieldFactory.cpp (file contents):
Revision 1782 by tim, Fri Nov 19 17:56:32 2004 UTC vs.
Revision 1783 by tim, Wed Nov 24 21:33:00 2004 UTC

# Line 3 | Line 3 | ForceFieldFactory::instance_ = NULL;
3   namespace oopse {
4  
5   //initialize instance of ForceFieldFactory
6 < ForceFieldFactory::instance_ = NULL;
6 > ForceFieldFactory* ForceFieldFactory::instance_ = NULL;
7  
8   bool ForceFieldFactory::registerForceField(const std::string& id, ForceFieldCreatorType creator) {
9      return creatorMap_.insert(
# Line 15 | Line 15 | ForceField* ForceFieldFactory::createForceField(const
15   }
16  
17   ForceField* ForceFieldFactory::createForceField(const std::string& id) {
18 <    typename CreatorMapType::iterator i = creatorMap_.find(id);
18 >    CreatorMapType::iterator i = creatorMap_.find(id);
19      if (i != creatorMap_.end()) {
20          //invoke functor to create object
21          return (i->second)();
# Line 26 | Line 26 | std::vector<std::string> ForceFieldFactory::getIdents(
26  
27   std::vector<std::string> ForceFieldFactory::getIdents() {
28      IdentVectorType idents;
29 <    typename CreatorMapType::iterator i;
29 >    CreatorMapType::iterator i;
30  
31      for (i = creatorMap_.begin(); i != creatorMap_.end(); ++i) {
32          idents.push_back(i->first);
# Line 36 | Line 36 | std::ostream& operator <<(std::ostream& o, ForceFieldF
36   }
37  
38   std::ostream& operator <<(std::ostream& o, ForceFieldFactory& factory) {
39 <    typename ForceFieldFactory::IdentVectorType idents;
40 <    typename ForceFieldFactory::IdentVectorIterator i;
39 >    ForceFieldFactory::IdentVectorType idents;
40 >    ForceFieldFactory::IdentVectorIterator i;
41  
42      idents = factory.getIdents();
43  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines