/****************************************************************************/
/* Copyright (c) 2012 MBARI                                                 */
/* MBARI Proprietary Information. All rights reserved.                      */
/****************************************************************************/
/* Summary  :                                                               */
/* Filename : DeltaTLog.h                                              */
/* Author   :                                                               */
/* Project  :                                                               */
/* Version  : 1.0                                                           */
/* Created  : 09/17/2012                                                    */
/* Modified :                                                               */
/* Archived :                                                               */
/****************************************************************************/
/* Modification History:                                                    */
/****************************************************************************/
#ifndef _WaypointWallLog_H
#define _WaypointWallLog_H

#include "DataLogWriter.h"
#include "FloatData.h"
#include "StringData.h"

class WaypointWall;

#define WaypointWallLogName "waypointwall"

/*
CLASS 
DeltaTLog

DESCRIPTION
Logs DeltaT data through the DataLogWriter interface.

To use this class, instantiate an instance within a DeltaT object
and periodically invoke the write() method:
<pre>

  DeltaTLog *log = new DeltaTLog(this, DataLog::AsciiFormat);

  [...other stuff...]

  // Log the data
  log->write();

</pre>
AUTHOR
Henthorn
*/
class WaypointWallLog : public DataLogWriter {

public:

  ///////////////////////////////////////////////////////////////////
  // Constructor
  // [input] navigation: PSA916 object. The setFields() method
  //         accesses this object as the source of the logged data.
  // [input] fileFormat: Specifies either DataLog::AsciiFormat or 
  //         DataLog::BinaryFormat.
  WaypointWallLog(DataLog::FileFormat fileFormat, char* data_name="wp"); 

  ~WaypointWallLog();

  virtual void setFields(float currentN, float currentE,
			 float nextN, float nextE, float bearing);

protected:

  ///////////////////////////////////////////////////////////////////
  // Set values in record array elements. This virtual method is called
  // by DataLogWriter::write()
  virtual void setFields();   // Does nothing

  void init(void);

  ///////////////////////////////////////////////////////////////////
  // setFields() accesses the data to be logged from this PSA916 
  // object.

private:

  StringData *_behaviorType;
  FloatData *_currentN;
  FloatData *_currentE;
  FloatData *_nextN;
  FloatData *_nextE;
  FloatData *_bearing;
  char* _dataName;

};

#endif
