-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make some verification functions public in C++
We make the logical checks for XSD data types public, so that the clients can check their structures in a fine-grained manner.
- Loading branch information
Showing
6 changed files
with
227 additions
and
175 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
26 changes: 19 additions & 7 deletions
26
test_data/cpp/test_main/aas_core_meta.v3/input/snippets/verification/is_xs_date_time_UTC.hpp
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 |
---|---|---|
@@ -1,10 +1,22 @@ | ||
/// \brief Check that \p text is a `xs:dateTime` with time zone set to UTC. | ||
/// | ||
/// The `text` is assumed to match a pre-defined pattern for `xs:dateTime` with | ||
/// the time zone set to UTC. In this function, we check for days of month (e.g., | ||
/// February 29th). | ||
/// | ||
/// See: https://www.w3.org/TR/xmlschema-2/#dateTime | ||
/** | ||
* \brief Check whether the given \p year is a leap year. | ||
* | ||
* Year 1 BCE is a leap year. | ||
* | ||
* \param year to be checked | ||
* \return true if \p year is a leap year | ||
*/ | ||
bool IsLeapYear(long long year); | ||
|
||
/** | ||
* \brief Check that \p text is a `xs:dateTime` with time zone set to UTC. | ||
* | ||
* The `text` is assumed to match a pre-defined pattern for `xs:dateTime` with | ||
* the time zone set to UTC. In this function, we check for days of month (e.g., | ||
* February 29th). | ||
* | ||
* See: https://www.w3.org/TR/xmlschema-2/#dateTime | ||
*/ | ||
bool IsXsDateTimeUtc( | ||
const std::wstring& text | ||
); |
Oops, something went wrong.