Skip to content

Commit

Permalink
SP-752 Code Examples: Java
Browse files Browse the repository at this point in the history
  • Loading branch information
mwarzybok-sumoheavy committed Jan 11, 2024
1 parent c8d39d9 commit 1f8a54f
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
/*
* Copyright (c) 2019 BitPay.
* All rights reserved.
*/

package com.bitpay.sdk.util.serializer;

import com.fasterxml.jackson.core.JsonParser;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
/*
* Copyright (c) 2019 BitPay.
* All rights reserved.
*/

package com.bitpay.sdk.util.serializer;

import com.fasterxml.jackson.core.JsonGenerator;
Expand All @@ -9,13 +14,14 @@

public class ZonedDateTimeToIso8601Serializer extends JsonSerializer<ZonedDateTime> {

private static final DateTimeFormatter DATE_TIME_FORMATTER = DateTimeFormatter.ofPattern("yyyy-MM-dd'T'HH:mm:ss.SSX");
private static final DateTimeFormatter DATE_TIME_FORMATTER =
DateTimeFormatter.ofPattern("yyyy-MM-dd'T'HH:mm:ss.SSX");

/**
* This method deserialize ZonedDateTime to format yyyy-mm-ddThh:mm:ssZ.
*
* @param zonedDateTime ZonedDateTime
* @param jsonGenerator JsonGenerator
* @param zonedDateTime ZonedDateTime
* @param jsonGenerator JsonGenerator
* @param serializerProvider SerializerProvider
* @throws IOException IOException
*/
Expand Down

0 comments on commit 1f8a54f

Please sign in to comment.