VR-Link API Documentation for HLA Evolved
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
csvReader.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 1992-2010 VT MAK
3 ** All rights reserved.
4 *********************************************************************/
7 #pragma once
8 
9 
10 
11 #include <fstream>
12 #include <omtReader/omtReader.h>
13 #include <vlutil/vlString.h>
14 #include <vlutil/vlFilename.h>
15 
16 #ifdef DtUSE_UTILITIES_NAMESPACE
17 namespace DtUSE_UTILITIES_NAMESPACE
18 {
19 #endif
20 
24 {
25 
26 public:
27  DtCSVReader( const DtFilename & filename );
28  virtual ~DtCSVReader();
29 
31  virtual bool readLine();
32 
35  virtual DtString stringVar( int start, int end ) const;
36 
40  virtual int intVar( int pos, bool * validNum ) const;
41 
42  virtual void setSeparator(char newSeparator);
43  virtual char separator();
44 
46  virtual int numColumns() const;
47 
48  const DtString& currLine() const;
49 
50 protected:
53  std::ifstream myTS;
56 };
57 
58 inline const DtString& DtCSVReader::currLine() const
59 {
60  return myCurrLine;
61 }
62 
63 #ifdef DtUSE_UTILITIES_NAMESPACE
64 }
65 #endif
66 
This file contains the declaration of DtFilename.
Contains the DtString class declaration.
char mySeparator
Definition: csvReader.h:51
DtString myCurrLine
Definition: csvReader.h:55
Contains defines for export control for OMT Reader.
const DtString & currLine() const
Definition: csvReader.h:58
#define DT_DLL_OMTREADER
Definition: omtReader.h:27
bool myValidFile
Definition: csvReader.h:54
Instances of DtFilename are DtStrings which convert filenames to the native format.
Definition: vlFilename.h:20
Inputs data from a comma delimited file format.
Definition: csvReader.h:23
std::ifstream myTS
Definition: csvReader.h:53
Instances of DtString are used to represent strings.
Definition: vlString.h:29
DtFilename myFile
Definition: csvReader.h:52

Document ID: Generated on Tue Aug 10 00:12:31 EDT 2021 from SVN revision 232765
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)