[GME-commit] GMESRC/GME/Common Common.vcproj,NONE,1.1 CommonCollection.h,1.6,1.7 CommonStl.h,1.4,1.5 CommonVersionInfo.h,1.2,1.3 Common.dsp,1.8,NONE

gme-commit at list.isis.vanderbilt.edu gme-commit at list.isis.vanderbilt.edu
Wed Jan 26 11:31:25 CST 2005


Update of /var/lib/gme/GMESRC/GME/Common
In directory braindrain:/tmp/cvs-serv19193/GME/Common

Modified Files:
	CommonCollection.h CommonStl.h CommonVersionInfo.h 
Added Files:
	Common.vcproj 
Removed Files:
	Common.dsp 
Log Message:
Checkin for VC7.1 upgrade


CVS User: zolmol

--- NEW FILE: Common.vcproj ---
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
	ProjectType="Visual C++"
	Version="7.10"
	Name="Common"
	SccProjectName=""
	SccLocalPath=""
	Keyword="MakeFileProj">
	<Platforms>
		<Platform
			Name="Win32"/>
	</Platforms>
	<Configurations>
		<Configuration
			Name="Debug|Win32"
			OutputDirectory=".\Debug"
			IntermediateDirectory=".\Debug"
			ConfigurationType="10"
			UseOfMFC="0"
			ATLMinimizesCRunTimeLibraryUsage="FALSE">
			<Tool
				Name="VCCustomBuildTool"/>
			<Tool
				Name="VCMIDLTool"
				TypeLibraryName=".\Debug/Common.tlb"
				HeaderFileName=""/>
			<Tool
				Name="VCPostBuildEventTool"/>
			<Tool
				Name="VCPreBuildEventTool"/>
		</Configuration>
		<Configuration
			Name="Release|Win32"
			OutputDirectory=".\Release"
			IntermediateDirectory=".\Release"
			ConfigurationType="10"
			UseOfMFC="0"
			ATLMinimizesCRunTimeLibraryUsage="FALSE">
			<Tool
				Name="VCCustomBuildTool"/>
			<Tool
				Name="VCMIDLTool"
				TypeLibraryName=".\Release/Common.tlb"
				HeaderFileName=""/>
			<Tool
				Name="VCPostBuildEventTool"/>
			<Tool
				Name="VCPreBuildEventTool"/>
		</Configuration>
	</Configurations>
	<References>
	</References>
	<Files>
		<Filter
			Name="Source Files"
			Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat">
			<File
				RelativePath="CommonError.cpp">
			</File>
			<File
				RelativePath="CommonMfc.cpp">
			</File>
			<File
				RelativePath="CommonSmart.cpp">
			</File>
			<File
				RelativePath="CommonStl.cpp">
			</File>
		</Filter>
		<Filter
			Name="Header Files"
			Filter="h;hpp;hxx;hm;inl">
			<File
				RelativePath="CommonCollection.h">
			</File>
			<File
				RelativePath="CommonComponent.h">
			</File>
			<File
				RelativePath="CommonError.h">
			</File>
			<File
				RelativePath="CommonMfc.h">
			</File>
			<File
				RelativePath="CommonMgaTrukk.h">
			</File>
			<File
				RelativePath="CommonSmart.h">
			</File>
			<File
				RelativePath="CommonStl.h">
			</File>
			<File
				RelativePath="CommonVersionInfo.h">
			</File>
		</Filter>
	</Files>
	<Globals>
	</Globals>
</VisualStudioProject>

Index: CommonCollection.h
===================================================================
RCS file: /var/lib/gme/GMESRC/GME/Common/CommonCollection.h,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** CommonCollection.h	13 Oct 2004 15:17:54 -0000	1.6
--- CommonCollection.h	26 Jan 2005 17:28:19 -0000	1.7
***************
*** 159,163 ****
  public:
  	typedef CCoreCollection<COLLITF, COLLTYPE, ITFTYPE, OBJTYPE> CLASS;
! 	typedef COLLTYPE::iterator ITERTYPE;
  	typedef CopyItfFromObj<ITFTYPE, OBJTYPE> FILL_COPYTYPE;
  	typedef CopyItfFromItf<ITFTYPE> GETALL_COPYTYPE;
--- 159,163 ----
  public:
  	typedef CCoreCollection<COLLITF, COLLTYPE, ITFTYPE, OBJTYPE> CLASS;
! 	typedef typename COLLTYPE::iterator ITERTYPE;
  	typedef CopyItfFromObj<ITFTYPE, OBJTYPE> FILL_COPYTYPE;
  	typedef CopyItfFromItf<ITFTYPE> GETALL_COPYTYPE;

Index: CommonStl.h
===================================================================
RCS file: /var/lib/gme/GMESRC/GME/Common/CommonStl.h,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** CommonStl.h	13 Oct 2004 15:17:54 -0000	1.4
--- CommonStl.h	26 Jan 2005 17:28:19 -0000	1.5
***************
*** 16,20 ****
  // these THROW exceptions
  
! inline void CopyTo(const std::string &s, BSTR *b) { CopyTo(s.begin(), s.length(), b); }
  inline void CopyTo(const std::string &s, VARIANT *v) { CopyTo(s.begin(), s.length(), v); }
  inline void CopyTo(const std::string &s, CComBstrObj &a) { CopyTo(s.begin(), s.length(), a); }
--- 16,28 ----
  // these THROW exceptions
  
! /* needed for MS STL
! inline void CopyTo(const std::string::const_iterator i, int l, BSTR * b){}
! inline void CopyTo(const std::string::const_iterator i, int l, VARIANT *v){}
! inline void CopyTo(const std::string::const_iterator i, int l, CComBstrObj &a){}
! inline void CopyTo(const std::string::const_iterator i, int l, CComVariant &a){}
! inline void CopyTo(BSTR b, std::string::iterator i, int l) {}
! inline void CopyTo(VARIANT &v, std::string::iterator i, int l) {}
! */
! inline void CopyTo(const std::string &s, BSTR *b) { CopyTo( s.begin(), s.length(), b); }
  inline void CopyTo(const std::string &s, VARIANT *v) { CopyTo(s.begin(), s.length(), v); }
  inline void CopyTo(const std::string &s, CComBstrObj &a) { CopyTo(s.begin(), s.length(), a); }
***************
*** 130,134 ****
  
  template<class CONTAINER>
! inline bool IsValidIterator(const CONTAINER &container, CONTAINER::const_iterator i)
  {
  	CONTAINER::const_iterator b = container.begin();
--- 138,142 ----
  
  template<class CONTAINER>
! inline bool IsValidIterator(const CONTAINER &container, typename CONTAINER::const_iterator i)
  {
  	CONTAINER::const_iterator b = container.begin();
***************
*** 158,162 ****
  		++i;
  
! 	ASSERT( ( (int) container.size() < limit ? (int) container.size() : limit) == (limit - counter) );//zolmol!
  	return limit - counter;
  }
--- 166,170 ----
  		++i;
  
! 	ASSERT( ( (int) container.size() < limit ? (int) container.size() : limit) == (limit - counter) );
  	return limit - counter;
  }
***************
*** 170,174 ****
  
  template<class ELEM>
! void CopyTo(TYPENAME_ELEM2COLL(ELEM) *p, std::vector< CComObjPtr<ELEM> > &q)
  {
  	ASSERT( p != NULL );
--- 178,182 ----
  
  template<class ELEM>
! void CopyTo( TYPENAME_ELEM2COLL(ELEM) *p, std::vector< CComObjPtr<ELEM> > &q)
  {
  	ASSERT( p != NULL );
***************
*** 187,190 ****
--- 195,207 ----
  
  template<class ELEM>
+ class PutOutCollObj; // forward declaration for the template class 
+ 
+ 
+ // this template function will be befriended with the PutOutCollObj class, in VS.NET 2003 sucha friend needs to be declared before the class declaration
+ template<class ELEM>
+ PutOutCollObj<ELEM> PutOut( std::vector< CComObjPtr<ELEM> > & coll_vector);
+ 
+ 
+ template<class ELEM>
  class PutOutCollObj
  {
***************
*** 192,196 ****
  	typedef ELEM elem_interface;
  	typedef TYPENAME_ELEM2COLL(ELEM) coll_interface;
! 
  	typedef std::vector< CComObjPtr<elem_interface> > vector_type;
  
--- 209,213 ----
  	typedef ELEM elem_interface;
  	typedef TYPENAME_ELEM2COLL(ELEM) coll_interface;
! 	
  	typedef std::vector< CComObjPtr<elem_interface> > vector_type;
  
***************
*** 205,213 ****
  			CopyTo(coll_ptr, coll_vector);
  	}
! 
  private:
  	PutOutCollObj(vector_type &v) : coll_vector(v) { }
  
! 	friend PutOutCollObj<ELEM> PutOut(std::vector< CComObjPtr<ELEM> > &coll_vector);
  
  	// to prevent misuse
--- 222,230 ----
  			CopyTo(coll_ptr, coll_vector);
  	}
! 	
  private:
  	PutOutCollObj(vector_type &v) : coll_vector(v) { }
  
! 	friend PutOutCollObj<ELEM> PutOut<ELEM>( std::vector< CComObjPtr<ELEM> > &coll_vector);
  
  	// to prevent misuse
***************
*** 220,227 ****
  };
  
  template<class ELEM>
! PutOutCollObj<ELEM> PutOut(std::vector< CComObjPtr<ELEM> > &coll_vector)
  {
! 	return PutOutCollObj<ELEM>(coll_vector);
  }
  
--- 237,245 ----
  };
  
+ // this template function (friend of PutOutCollObj) needs to be forward declared!
  template<class ELEM>
! PutOutCollObj<ELEM> PutOut( std::vector< CComObjPtr<ELEM> > & coll_vector)
  {
! 	return PutOutCollObj<ELEM>( coll_vector);
  }
  

Index: CommonVersionInfo.h
===================================================================
RCS file: /var/lib/gme/GMESRC/GME/Common/CommonVersionInfo.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** CommonVersionInfo.h	26 Jul 2001 18:18:00 -0000	1.2
--- CommonVersionInfo.h	26 Jan 2005 17:28:19 -0000	1.3
***************
*** 8,11 ****
--- 8,12 ----
  	    BEGIN_INTERFACE
  		STDMETHOD(get_version(MgaInterfaceVersion *pVal)) {
+ 			//AFX_MANAGE_STATE( AfxGetStaticModuleState());//z
  			if(!pVal) return E_POINTER;
  			*pVal = MgaInterfaceVersion_Current;

--- Common.dsp DELETED ---



More information about the GME-commit mailing list