Skip to content

Commit

Permalink
helpers
Browse files Browse the repository at this point in the history
  • Loading branch information
hugopendlebury committed Feb 8, 2024
1 parent 802cb3a commit a1d0988
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
23 changes: 23 additions & 0 deletions src/gribhelpers.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
#include <arrow/api.h>
#include <cstdint>
#include <iomanip>
#include <chrono>
#include <sstream>
#include <time.h>
#include <iostream>
#include <vector>
#include "gribhelpers.hpp"

std::unordered_map<std::string, std::shared_ptr<arrow::DataType>> getConversionFieldDefinitions() {

std::unordered_map<std::string, std::shared_ptr<arrow::DataType>> fieldTypes;
fieldTypes.emplace(make_pair("parameterId", arrow::int64()));
fieldTypes.emplace(make_pair("addition_value", arrow::float64()));
fieldTypes.emplace(make_pair("subtraction_value", arrow::float64()));
fieldTypes.emplace(make_pair("multiplication_value", arrow::float64()));
fieldTypes.emplace(make_pair("division_value", arrow::float64()));
fieldTypes.emplace(make_pair("ceiling_value", arrow::float64()));

return fieldTypes;

}
1 change: 1 addition & 0 deletions src/gribhelpers.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
std::unordered_map<std::string, std::shared_ptr<arrow::DataType>> getConversionFieldDefinitions() ;

0 comments on commit a1d0988

Please sign in to comment.