8247781: Day periods support

Reviewed-by: scolebourne, rriggs, joehw
This commit is contained in:
Naoto Sato 2020-11-16 23:12:45 +00:00
parent 0357db3581
commit bf84dac4cf
20 changed files with 1155 additions and 203 deletions

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2012, 2020, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -424,6 +424,15 @@ final class DateTimeParseContext {
currentParsed().leapSecond = true;
}
/**
* Stores the parsed day period.
*
* @param dayPeriod the parsed day period
*/
void setParsedDayPeriod(DateTimeFormatterBuilder.DayPeriod dayPeriod) {
currentParsed().dayPeriod = dayPeriod;
}
//-----------------------------------------------------------------------
/**
* Returns a string version of the context for debugging.