00001 /*============================================================================= 00002 Copyright (C) 2012 Allied Vision Technologies. All Rights Reserved. 00003 00004 Redistribution of this file, in original or modified form, without 00005 prior written consent of Allied Vision Technologies is prohibited. 00006 00007 ------------------------------------------------------------------------------- 00008 00009 File: UserLoggerDefines.h 00010 00011 Description: Definition of macros used for different logging methods. 00012 00013 ------------------------------------------------------------------------------- 00014 00015 THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED 00016 WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF TITLE, 00017 NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 00018 DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, 00019 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 00020 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 00021 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 00022 AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR 00023 TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 00024 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 00025 00026 =============================================================================*/ 00027 00028 #ifndef AVT_VMBAPI_USERLOGGERDEFINES_H 00029 #define AVT_VMBAPI_USERLOGGERDEFINES_H 00030 00031 // 00032 // To use your own logger implementation add the define USER_LOGGER to your project / compiler settings and complete this header file. 00033 // 00034 00035 // Add all your required logger implementation headers here. 00036 // HINT: #include <VimbaCPP/Include/FileLogger.h> is an example and can be safely removed. 00037 #include <VimbaCPP/Include/FileLogger.h> 00038 00039 namespace AVT { 00040 namespace VmbAPI { 00041 00042 #define LOGGER_DECL FileLogger 00043 #define LOGGER_DEF FileLogger( "VimbaCPP.log", true ) 00044 #define LOGGER_LOG( logger, loggingInfo ) if ( NULL != (logger) ) (logger)->Log( loggingInfo ); 00045 00046 00047 // These are all uses of LOGGER_DECL logger declarations 00048 typedef LOGGER_DECL* Logger; 00049 00050 }} // namespace AVT::VmbAPI 00051 00052 #endif