Description
Parse a displayed second with an explicit leap-context flag.
Astronomical day origins and leap-second notation depend on an explicit time scale and context. A numerical day fraction or second token does not itself verify UTC leap-second occurrence or convert between time standards.
Parse a displayed second with an explicit leap-context flag.
When to use this tool
Use Date: Leap Second Display Second Token when checking the stated astronomical-day or leap-second display convention.
How to use the tool and how it works
- Enter secondToken, leapContextVerified. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read result. Expand result to inspect the returned fields.
Parse a displayed second with an explicit leap-context flag. Accept two-digit 00-60; leapSecond flags 60 and accepted is true below 60 or when leapContextVerified.1
RFC 3339 distinguishes an unknown local offset from known UTC and restricts leap-second notation to appropriate actual time contexts; lexical parsing does not verify those contexts.2
| Input field | Meaning and units | Accepted input |
|---|---|---|
| secondToken | Second Token | Required. Text. Implementation limit: 8192 Unicode code points and 16384 UTF-16 code units. |
| leapContextVerified | Caller assertion that the actual time context permits a leap second; no authoritative table is consulted. | Required. Boolean. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| result | Returned object; expand its named members below. | Required. Object. |
| result.second | Second | Calculated result member: number. |
| result.leapSecond | Leap Second | Calculated result member: boolean. |
| result.accepted | Ordinary valid second, or second 60 only with verified context. | Calculated result member: boolean. |
{
"input": {
"secondToken": "60",
"leapContextVerified": false
},
"output": {
"result": {
"second": 60,
"leapSecond": true,
"accepted": false
}
}
} Limitations and assumptions
- A false accepted flag is a successful parse; actual leap-second dates or time scales are not verified.
- Outputs are nested inside result. Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
Alternative or Complementary methods
Use appropriate time-scale conversion and authoritative leap-second data for actual scientific timestamps.
References
Similar or alternative tools
- Date: Timestamp Offset Negative Zero Check
Distinguish known zero UTC offset from unknown local offset.
- Date: Timestamp Fractional Second Digit Count
Count written fractional-second digits in a restricted time token.