Make a try at adding MSVC import/export logic for cllazyfile
This commit is contained in:
parent
06b58ac54b
commit
c230b76c48
7 changed files with 30 additions and 9 deletions
|
|
@ -92,4 +92,17 @@
|
|||
# endif
|
||||
#endif
|
||||
|
||||
/* Import/Export flags for lazyfile. */
|
||||
#ifndef SCL_LAZYFILE_EXPORT
|
||||
# if defined(SCL_LAZYFILE_DLL_EXPORTS) && defined(SCL_LAZYFILE_DLL_IMPORTS)
|
||||
# error "Only SCL_LAZYFILE_DLL_EXPORTS or SCL_LAZYFILE_DLL_IMPORTS can be defined, not both."
|
||||
# elif defined(SCL_LAZYFILE_DLL_EXPORTS)
|
||||
# define SCL_LAZYFILE_EXPORT __declspec(dllexport)
|
||||
# elif defined(SCL_LAZYFILE_DLL_IMPORTS)
|
||||
# define SCL_LAZYFILE_EXPORT __declspec(dllimport)
|
||||
# else
|
||||
# define SCL_LAZYFILE_EXPORT
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#endif /* SCL_EXPORT_H */
|
||||
|
|
|
|||
|
|
@ -10,9 +10,10 @@
|
|||
#include "lazyTypes.h"
|
||||
#include "scl_memmgr.h"
|
||||
|
||||
#include "scl_export.h"
|
||||
|
||||
///differs from the lazyDataSectionReader in that all instances are always loaded
|
||||
class headerSectionReader: public sectionReader {
|
||||
class SCL_LAZYFILE_EXPORT headerSectionReader: public sectionReader {
|
||||
protected:
|
||||
instancesLoaded_t * _headerInstances;
|
||||
|
||||
|
|
@ -33,4 +34,4 @@ class headerSectionReader: public sectionReader {
|
|||
}
|
||||
};
|
||||
|
||||
#endif //HEADERSECTIONREADER_H
|
||||
#endif //HEADERSECTIONREADER_H
|
||||
|
|
|
|||
|
|
@ -7,6 +7,8 @@
|
|||
#include "lazyTypes.h"
|
||||
#include "scl_memmgr.h"
|
||||
|
||||
#include "scl_export.h"
|
||||
|
||||
/** base class for data section readers
|
||||
* \sa lazyP21DataSectionReader
|
||||
* \sa lazyP28DataSectionReader
|
||||
|
|
@ -25,4 +27,4 @@ class lazyDataSectionReader: public sectionReader {
|
|||
}
|
||||
};
|
||||
|
||||
#endif //LAZYDATASECTIONREADER_H
|
||||
#endif //LAZYDATASECTIONREADER_H
|
||||
|
|
|
|||
|
|
@ -5,6 +5,8 @@
|
|||
#include <string>
|
||||
#include <cstdlib>
|
||||
|
||||
#include "scl_export.h"
|
||||
|
||||
// PART 21
|
||||
#include "lazyP21DataSectionReader.h"
|
||||
#include "p21HeaderSectionReader.h"
|
||||
|
|
@ -22,7 +24,7 @@ class headerSectionReader;
|
|||
|
||||
///read an exchange file of any supported type (currently only p21)
|
||||
///for use only from within lazyInstMgr
|
||||
class lazyFileReader {
|
||||
class SCL_LAZYFILE_EXPORT lazyFileReader {
|
||||
protected:
|
||||
std::string _fileName;
|
||||
lazyInstMgr * _parent;
|
||||
|
|
|
|||
|
|
@ -4,8 +4,9 @@
|
|||
#include "lazyDataSectionReader.h"
|
||||
#include "lazyFileReader.h"
|
||||
#include "scl_memmgr.h"
|
||||
#include "scl_export.h"
|
||||
|
||||
class lazyP21DataSectionReader: public lazyDataSectionReader {
|
||||
class SCL_LAZYFILE_EXPORT lazyP21DataSectionReader: public lazyDataSectionReader {
|
||||
protected:
|
||||
public:
|
||||
lazyP21DataSectionReader( lazyFileReader * parent, std::ifstream & file, std::streampos start, sectionID sid );
|
||||
|
|
@ -21,4 +22,4 @@ class lazyP21DataSectionReader: public lazyDataSectionReader {
|
|||
|
||||
};
|
||||
|
||||
#endif //LAZYP21DATASECTIONREADER_H
|
||||
#endif //LAZYP21DATASECTIONREADER_H
|
||||
|
|
|
|||
|
|
@ -3,8 +3,9 @@
|
|||
|
||||
#include "headerSectionReader.h"
|
||||
#include "scl_memmgr.h"
|
||||
#include "scl_export.h"
|
||||
|
||||
class p21HeaderSectionReader: public headerSectionReader {
|
||||
class SCL_LAZYFILE_EXPORT p21HeaderSectionReader: public headerSectionReader {
|
||||
public:
|
||||
p21HeaderSectionReader( lazyFileReader * parent, std::ifstream & file, std::streampos start, sectionID sid );
|
||||
void findSectionStart();
|
||||
|
|
@ -15,4 +16,4 @@ class p21HeaderSectionReader: public headerSectionReader {
|
|||
const namedLazyInstance nextInstance();
|
||||
};
|
||||
|
||||
#endif //P21HEADERSECTIONREADER_H
|
||||
#endif //P21HEADERSECTIONREADER_H
|
||||
|
|
|
|||
|
|
@ -5,13 +5,14 @@
|
|||
#include <set>
|
||||
#include "lazyTypes.h"
|
||||
#include "scl_memmgr.h"
|
||||
#include "scl_export.h"
|
||||
|
||||
class SDAI_Application_instance;
|
||||
class lazyFileReader;
|
||||
class ErrorDescriptor;
|
||||
class Registry;
|
||||
|
||||
class sectionReader {
|
||||
class SCL_LAZYFILE_EXPORT sectionReader {
|
||||
protected:
|
||||
//protected data members
|
||||
lazyFileReader * _lazyFile;
|
||||
|
|
|
|||
Loading…
Reference in a new issue