I have Rest API which will accept date time in URI it works fine except for UTC.
I have the following code which will format the DateTime and outputs the result, when I use CDT, EST, PDT,PST etc, but I want the date format to also accept UTC time zone along with all other. Client can send the date time in any format(UTC mostly, but also includes CDT,EST) and I need to pass it as is, it is client's choice what time zone to pass
Date now = new Date();
SimpleDateFormat inStr = new SimpleDateFormat("yyyy-MM-dd'T'HH:mmz")
This works for CDT, EST,PDT but not for UTC I want to include UTC aswell in the rest API call get the desired output.
Can some one please help me on this
Valid values are - 2018-07-11T20:30UTC , 2018-07-11T18:30CDT