/*******************************************************************************
** Copyright (c) 2003 MaK Technologies, Inc.
** All rights reserved.
*******************************************************************************/

//! \file lcStateFlag.h 
//! \brief Contains DtLgrStateFlagPdu

#pragma once

#include "lcPdu.h"

//! Instances of DtLgrStateFlagPdu are used to tell a remote logger that
//! it should toggle one of its internal flags
//! \ingroup loggerControlToolkit
class DT_DLL_LOGGERCONTROL DtLgrStateFlagPdu : public DtLgrControlPdu
{
public:

   //! (default) constructor
   DtLgrStateFlagPdu( DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER );

   //! constructor (constructs from network representation)
   DtLgrStateFlagPdu( const DtNetLgrControlPdu*,
      DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER, DtPduFactory* pduFactory = 0 );

   //! constructor (construct and prepare for send)
   DtLgrStateFlagPdu( const DtEntityIdentifier& sender,
      const DtEntityIdentifier& receiver, DtLgrCtrlFlagStates tglFlag,
      DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER );

   //! destructor
   virtual ~DtLgrStateFlagPdu();

   //! copy constructor
   DtLgrStateFlagPdu( const DtLgrStateFlagPdu& );

   //! assignment operator
   DtLgrStateFlagPdu& operator=( const DtLgrStateFlagPdu& );

   //! Get/set value for what to do when Logger reaches EOF.
   virtual DtLgrCtrlFlagStates flag() const;
   virtual void setFlag( DtLgrCtrlFlagStates );

   //! Return correctly casted parameters pointer; see lgrControlP.h.
   virtual DtLgrIntParams* params() const;
};

