[GME-commit] GMESRC/Paradigms/MetaGME/MetaInterpreter2004/Rep
Any.cpp, 1.17, 1.18 Any.h, 1.10, 1.11
gme-commit at list.isis.vanderbilt.edu
gme-commit at list.isis.vanderbilt.edu
Thu Mar 8 16:54:51 CST 2007
Update of /project/gme-repository/GMESRC/Paradigms/MetaGME/MetaInterpreter2004/Rep
In directory escher:/tmp/cvs-serv18116/MetaInterpreter2004/Rep
Modified Files:
Any.cpp Any.h
Log Message:
Nested libraries caused some problems
for namespace init & registry write operations.
Nested libraries will have a fake parentFolder, will be set to the main rootfolder.
CVS User: Zoltan Molnar, ISIS (zolmol)
Index: Any.cpp
===================================================================
RCS file: /project/gme-repository/GMESRC/Paradigms/MetaGME/MetaInterpreter2004/Rep/Any.cpp,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -d -r1.17 -r1.18
*** Any.cpp 22 Sep 2006 22:27:13 -0000 1.17
--- Any.cpp 8 Mar 2007 22:54:49 -0000 1.18
***************
*** 81,93 ****
else
{
! // if object is from a library its m_parentFolder variable holds the librootfolder (a readwriteable object)
! ASSERT( !m_parentFolder->isInLibrary());
! BON::Folder parent( m_parentFolder);
! while( parent && parent->isInLibrary()) {
! parent = parent->getParentFolder();
! } // the first parent which is not in the library is the LibRootFolder
!
! BON::RegistryNode rn;
! if( parent) rn = parent->getRegistry()->getChild( "Namespace");
if( rn) m_namespace = rn->getValue();
--- 81,87 ----
else
{
! // find the Namespace value from the namespace holding rootfolder
! // in case of nested libs m_libRootFolder and m_nmspRootFolder are !equal
! BON::RegistryNode rn = m_nmspRootFolder->getRegistry()->getChild( "Namespace");
if( rn) m_namespace = rn->getValue();
Index: Any.h
===================================================================
RCS file: /project/gme-repository/GMESRC/Paradigms/MetaGME/MetaInterpreter2004/Rep/Any.h,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -d -r1.10 -r1.11
*** Any.h 22 Sep 2006 22:27:13 -0000 1.10
--- Any.h 8 Mar 2007 22:54:49 -0000 1.11
***************
*** 87,91 ****
BON::Folder getParentFolder() const { return m_parentFolder; }
! void setParentFolder( const BON::Folder& folder) { m_parentFolder = folder; }
void setEquivPeers( const std::set< BON::FCO >& ps) { m_equivs = ps; }
void setDisplayedName( const std::string& dispnm) { m_userSelectedDisplayName = dispnm; }
--- 87,91 ----
BON::Folder getParentFolder() const { return m_parentFolder; }
! void setParentFolder( const BON::Folder& writableRegFolder, const BON::Folder& nmspHolderFolder) { m_parentFolder = writableRegFolder; m_nmspRootFolder = nmspHolderFolder;}
void setEquivPeers( const std::set< BON::FCO >& ps) { m_equivs = ps; }
void setDisplayedName( const std::string& dispnm) { m_userSelectedDisplayName = dispnm; }
***************
*** 112,116 ****
--- 112,123 ----
// pointer of the parent folder
+ // this must be writable because
+ // the registry write operations
+ // work through this ptr
BON::Folder m_parentFolder;
+
+ // namespace info taken from this folder
+ // typically same with m_parentFolder
+ BON::Folder m_nmspRootFolder;
// equivalent peers
More information about the GME-commit
mailing list