VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
csvParser.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2017 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
7 
9 
10 #pragma once
11 
13 #include <matrix/vlVector.h>
14 
15 struct ParsedItem
16 {
17  DtGeodeticCoord myLocation;
18  std::string myName;
19 };
20 
22 {
23 
24 public:
25  DtCsvParser();
26 public:
27  ~DtCsvParser();
28 
29 public:
30 
33  virtual bool parse(istream& stream);
34 
38  virtual void createObjectList(std::string name= "");
39 
40  const std::vector<ParsedItem> & items();
41 
42 protected:
43 
44  virtual bool parseLocation(vector<string> tokens, DtGeodeticCoord & geodLoc);
45 
46 protected:
47 
50  std::vector<ParsedItem> myParsedItems;
51 };
52 
std::vector< ParsedItem > myParsedItems
We do a straight parse of each row and store here.
Definition: csvParser.h:50
DtGeodeticCoord myLocation
Definition: csvParser.h:17
This class is the base class for parsing out creation information from various textual formats...
Definition: createObjectParser.h:48
bool myIsMultipleObjects
Definition: csvParser.h:48
virtual bool parse(istream &stream)
Derived classes will set up the tokenizer and determine how extract field information for each record...
Definition: createObjectParser.h:60
voidpf stream
Definition: ioapi.h:39
#define DT_DLL_vrfutil
This file is used to determine how to build Disable inconsistent dll linkage warning Visual Studio 6...
Definition: vrfutilDefines.h:34
Class DtCsvParser parses simple csv files to get a series of points.
Definition: csvParser.h:15
std::string myName
Definition: csvParser.h:18
Definition: csvParser.h:21

Document ID: Generated on Tue Sep 24 19:28:17 EDT 2024 from SVN revision 269799
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)