DisplayTextDateFormatSupport
Overview
DisplayTextDateFormatSupport is a class in Aspose.Cells FOSS for C++.
Internal helper methods for formatting date/time display text.
This class provides 9 methods for working with DisplayTextDateFormatSupport objects in C++ programs.
Available methods include: ContainsElapsedTimeToken, CountRepeated, DisplayTextDateFormatSupport, FindNeighborToken, FormatDateTimeValue, FormatElapsedTimeValue, IsElapsedToken, IsMinuteContext, MatchesToken.
All public members are accessible to any C++ application after installing the Aspose.Cells FOSS for C++ package.
Methods
| Signature | Description |
|---|---|
DisplayTextDateFormatSupport() | Calls DisplayTextDateFormatSupport on this DisplayTextDateFormatSupport instance. |
FormatDateTimeValue(value: DateTime, formatCode: std::string_view, culture: std::locale) → std::string | Formats a DateTime value according to the given format code and locale. |
FormatElapsedTimeValue(time: std::chrono::duration<double>, formatCode: std::string_view, culture: std::locale) → std::string | Formats a TimeSpan value according to the given format code and locale. |
IsElapsedToken(token: std::string_view) → bool | Returns true if the token (case-insensitive) is an elapsed-time token such as h, hh, m, mm, s, or ss. |
ContainsElapsedTimeToken(formatCode: std::string_view) → bool | Scans for bracketed elapsed-time tokens in the format code. |
MatchesToken(formatCode: std::string_view, startIndex: int, token: std::string_view) → bool | Tests whether the substring starting at startIndex matches token (case-insensitive). |
CountRepeated(formatCode: std::string_view, startIndex: int, token: char) → int | Counts consecutive occurrences of the character at startIndex. |
IsMinuteContext(formatCode: std::string_view, startIndex: int, count: int) → bool | Determines whether an ’m’/‘M’ sequence at the given position is in a minute context (rather than a month context). |
FindNeighborToken(formatCode: std::string_view, startIndex: int, direction: int) → char | Finds the nearest non-whitespace, non-escape token character in the given direction from startIndex. Returns ‘\0’ if none is found. |