The Gaudi Framework  v33r1 (b1225454)
LibSymbolInfo.h
Go to the documentation of this file.
1 /***********************************************************************************\
2 * (c) Copyright 1998-2019 CERN for the benefit of the LHCb and ATLAS collaborations *
3 * *
4 * This software is distributed under the terms of the Apache version 2 licence, *
5 * copied verbatim in the file "LICENSE". *
6 * *
7 * In applying this licence, CERN does not waive the privileges and immunities *
8 * granted to it by virtue of its status as an Intergovernmental Organization *
9 * or submit itself to any jurisdiction. *
10 \***********************************************************************************/
11 // LibSymbolInfo.h: interface for the CLibSymbolInfo class.
12 //
14 
15 #if !defined( AFX_LIBSYMBOLINFO_H__1A7003B4_BA53_11D1_AE46_1CFB51000000__INCLUDED_ )
16 # define AFX_LIBSYMBOLINFO_H__1A7003B4_BA53_11D1_AE46_1CFB51000000__INCLUDED_
17 
18 # include <iostream>
19 # include <string>
20 
21 # include <assert.h>
22 # include <stdio.h>
23 # include <windows.h>
24 
26 public:
28  virtual ~CLibSymbolInfo();
29  BOOL DumpSymbols( LPTSTR lpszLibPathName, std::ostream& pFile );
30  std::string GetLastError() const;
31 
32 protected:
35 
36  BOOL Dump( LPTSTR lpszLibPathName, std::ostream& pFile );
37  BOOL IsRegularLibSymbol( PSTR pszSymbolName );
38  BOOL IsFiltedSymbol( std::string& pszSymbolName );
39  DWORD ConvertBigEndian( DWORD bigEndian );
40 };
41 
43 
45 public:
46  MEMORY_MAPPED_FILE( PSTR pszFileName );
47  ~MEMORY_MAPPED_FILE( void );
48 
49  PVOID GetBase( void ) { return m_pMemoryMappedFileBase; }
50  DWORD GetFileSize( void ) { return m_cbFile; }
51  BOOL IsValid( void ) { return errMMF_NoError == m_errCode; }
53 
54 private:
55  HANDLE m_hFile;
56  HANDLE m_hFileMapping; // Handle of memory mapped file
58  DWORD m_cbFile;
60 };
61 
63 
64 #endif // !defined(AFX_LIBSYMBOLINFO_H__1A7003B4_BA53_11D1_AE46_1CFB51000000__INCLUDED_)
PVOID GetBase(void)
Definition: LibSymbolInfo.h:49
std::string GetLastError() const
std::string m_strResultsString
Definition: LibSymbolInfo.h:33
MEMORY_MAPPED_FILE * PMEMORY_MAPPED_FILE
Definition: LibSymbolInfo.h:62
STL class.
DWORD GetFileSize(void)
Definition: LibSymbolInfo.h:50
BOOL Dump(LPTSTR lpszLibPathName, std::ostream &pFile)
std::string m_strErrorMsg
Definition: LibSymbolInfo.h:34
BOOL IsValid(void)
Definition: LibSymbolInfo.h:51
errMMF
Definition: LibSymbolInfo.h:42
BOOL IsFiltedSymbol(std::string &pszSymbolName)
PVOID m_pMemoryMappedFileBase
Definition: LibSymbolInfo.h:57
DWORD ConvertBigEndian(DWORD bigEndian)
MEMORY_MAPPED_FILE(PSTR pszFileName)
STL class.
BOOL DumpSymbols(LPTSTR lpszLibPathName, std::ostream &pFile)
virtual ~CLibSymbolInfo()
BOOL IsRegularLibSymbol(PSTR pszSymbolName)