forked from deephaven/deephaven-core
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'deephaven:main' into coverage-workflow-2
- Loading branch information
Showing
11 changed files
with
374 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
42 changes: 42 additions & 0 deletions
42
cpp-client/deephaven/dhclient/include/public/deephaven/client/utility/internal_types.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
/* | ||
* Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending | ||
*/ | ||
#pragma once | ||
|
||
#include <arrow/flight/types.h> | ||
|
||
namespace deephaven::client::utility { | ||
/** | ||
* For Deephaven use only | ||
*/ | ||
namespace internal { | ||
/** | ||
* This class exists only for the benefit of the unit tests. Our normal DateTime class has a | ||
* native time resolution of nanoseconds. This class allows our unit tests to upload a | ||
* DateTime having a different time unit so we can confirm that the client and server both handle | ||
* it correctly. | ||
*/ | ||
template<arrow::TimeUnit::type UNIT> | ||
struct InternalDateTime { | ||
explicit InternalDateTime(int64_t value) : value_(value) {} | ||
|
||
int64_t value_ = 0; | ||
}; | ||
|
||
/** | ||
* This class exists only for the benefit of the unit tests. Our normal LocalTime class has a | ||
* native time resolution of nanoseconds. This class allows our unit tests to upload a | ||
* LocalTime having a different time unit so we can confirm that the client and server both handle | ||
* it correctly. | ||
*/ | ||
template<arrow::TimeUnit::type UNIT> | ||
struct InternalLocalTime { | ||
// Arrow Time64 only supports micro and nano units | ||
static_assert(UNIT == arrow::TimeUnit::MICRO || UNIT == arrow::TimeUnit::NANO); | ||
|
||
explicit InternalLocalTime(int64_t value) : value_(value) {} | ||
|
||
int64_t value_ = 0; | ||
}; | ||
} // namespace internal | ||
} // namespace deephaven::client::utility |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.