00001 // -*- C++ -*- 00002 00003 //============================================================================= 00004 /** 00005 * @file OS_Log_Msg_Attributes.h 00006 * 00007 * $Id: OS_Log_Msg_Attributes.h 80826 2008-03-04 14:51:23Z wotte $ 00008 * 00009 * @author Carlos O'Ryan 00010 */ 00011 //============================================================================= 00012 00013 #include /**/ "ace/config-all.h" 00014 00015 #ifndef ACE_OS_LOG_MSG_ATTRIBUTES_H 00016 #define ACE_OS_LOG_MSG_ATTRIBUTES_H 00017 #include /**/ "ace/pre.h" 00018 00019 #if !defined (ACE_LACKS_PRAGMA_ONCE) 00020 # pragma once 00021 #endif /* ACE_LACKS_PRAGMA_ONCE */ 00022 00023 #include /**/ "ace/ACE_export.h" 00024 #include "ace/os_include/os_stdio.h" 00025 #include "ace/iosfwd.h" 00026 00027 ACE_BEGIN_VERSIONED_NAMESPACE_DECL 00028 00029 /** 00030 * @class ACE_OS_Log_Msg_Attributes 00031 * 00032 * @brief The attributes required by ACE_Log_Msg. 00033 * 00034 * When a new thread is created the TSS resources for the Log_Msg 00035 * class in the new thread may be inherited by the creator thread. 00036 * The base_attributes are encapsulated in this class to simplify their 00037 * manipulation and destruction. 00038 * @par 00039 * The contents of the class must be made available to the OS layer, 00040 * because they are part of the thread descriptor. 00041 */ 00042 class ACE_Export ACE_OS_Log_Msg_Attributes 00043 { 00044 public: 00045 /// Constructor 00046 ACE_OS_Log_Msg_Attributes (void); 00047 00048 protected: 00049 friend class ACE_Log_Msg; 00050 00051 /// Ostream where the new TSS Log_Msg will use. 00052 ACE_OSTREAM_TYPE *ostream_; 00053 00054 /// Priority_mask to be used in new TSS Log_Msg. 00055 unsigned long priority_mask_; 00056 00057 /// Are we allowing tracing in this thread? 00058 int tracing_enabled_; 00059 00060 /// Indicates whether we should restart system calls that are 00061 /// interrupted. 00062 int restart_; 00063 00064 /// Depth of the nesting for printing traces. 00065 int trace_depth_; 00066 00067 # if defined (ACE_HAS_WIN32_STRUCTURAL_EXCEPTIONS) 00068 /// Structured exception handling Callbacks, only used under Win32 00069 ACE_SEH_EXCEPT_HANDLER seh_except_selector_; 00070 ACE_SEH_EXCEPT_HANDLER seh_except_handler_; 00071 # endif /* ACE_HAS_WIN32_STRUCTURAL_EXCEPTIONS */ 00072 00073 private: 00074 // Prevent copying 00075 ACE_OS_Log_Msg_Attributes (const ACE_OS_Log_Msg_Attributes &); 00076 ACE_OS_Log_Msg_Attributes &operator= (const ACE_OS_Log_Msg_Attributes &); 00077 }; 00078 00079 ACE_END_VERSIONED_NAMESPACE_DECL 00080 00081 # if defined (ACE_HAS_INLINED_OSCALLS) 00082 # if defined (ACE_INLINE) 00083 # undef ACE_INLINE 00084 # endif /* ACE_INLINE */ 00085 # define ACE_INLINE inline 00086 # include "ace/OS_Log_Msg_Attributes.inl" 00087 # endif /* ACE_HAS_INLINED_OSCALLS */ 00088 00089 #include /**/ "ace/post.h" 00090 #endif /* ACE_OS_LOG_MSG_ATTRIBUTES_H */