2 #ifndef __USER_LOG_PARAM_H__
3 #define __USER_LOG_PARAM_H__
5 // Class that stores a particular parameter
7 // Could be a struct, but we want to sort and need to
8 // overload the < operator.
10 // Copyright 2005 by Keith Vertanen
14 #include "Parameters.h"
18 // Bit mask options that are sent in when logging parameters
21 userLogParamTrackMultiple
= 1, // Should we track multiple values of a given parameter?
22 userLogParamOutputToSimple
= 2, // Does this parameter get sent to the simple log file?
23 userLogParamTrackInTrial
= 4, // Do we also store a copy of the parameter value within a trial?
24 userLogParamForceInTrial
= 8, // Do we always log the value of this parameter when a new trial is created?
25 userLogParamShortInCycle
= 16 // In short logging, does the value get added to the end of a cycle stats line?
28 // We need to have a lookup table that maps parameters we want to track in
29 // the UserLog object and what their behavior is.
30 struct UserLogParamMask
{
37 typedef vector
<CUserLogParam
*> VECTOR_USER_LOG_PARAM_PTR
;
38 typedef vector
<CUserLogParam
*>::iterator VECTOR_USER_LOG_PARAM_PTR_ITER
;
39 typedef vector
<CUserLogParam
*>::reverse_iterator VECTOR_USER_LOG_PARAM_PTR_REV_ITER
;
46 string strName
; // Name of the parameter
47 string strValue
; // String version of the value
48 string strTimeStamp
; // Optional timestamp if we want to know when a parameter was changed
49 int options
; // The options that were used on the parameter
51 static bool ComparePtr(CUserLogParam
* pA
, CUserLogParam
* pB
);