aboutsummaryrefslogtreecommitdiff
path: root/csharp/src/Google.Protobuf/WellKnownTypes/TimestampPartial.cs
diff options
context:
space:
mode:
authorJon Skeet <jonskeet@google.com>2015-07-31 13:22:15 +0100
committerJon Skeet <jonskeet@google.com>2015-08-03 09:26:04 +0100
commit16e272e0c4eebb1d01a2e71ef3c555ff57a22b07 (patch)
tree5b624cf24ba05ac067dc4bfa6f10b8fe4dd967c5 /csharp/src/Google.Protobuf/WellKnownTypes/TimestampPartial.cs
parent80f89b4ecfad8783c1453f1bf36ecda1c2c9c664 (diff)
downloadprotobuf-16e272e0c4eebb1d01a2e71ef3c555ff57a22b07.tar.gz
protobuf-16e272e0c4eebb1d01a2e71ef3c555ff57a22b07.tar.bz2
protobuf-16e272e0c4eebb1d01a2e71ef3c555ff57a22b07.zip
Format JSON for Duration and Timestamp.
This is taking an approach of putting all the logic in JsonFormatter. That's helpful in terms of concealing the details of whether or not to wrap the value in quotes, but it does lack flexibility. I don't *think* we want to allow user-defined formatting of messages, so that much shouldn't be a problem.
Diffstat (limited to 'csharp/src/Google.Protobuf/WellKnownTypes/TimestampPartial.cs')
-rw-r--r--csharp/src/Google.Protobuf/WellKnownTypes/TimestampPartial.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/csharp/src/Google.Protobuf/WellKnownTypes/TimestampPartial.cs b/csharp/src/Google.Protobuf/WellKnownTypes/TimestampPartial.cs
index f682d093..1aa392c7 100644
--- a/csharp/src/Google.Protobuf/WellKnownTypes/TimestampPartial.cs
+++ b/csharp/src/Google.Protobuf/WellKnownTypes/TimestampPartial.cs
@@ -147,7 +147,7 @@ namespace Google.Protobuf.WellKnownTypes
return FromDateTime(dateTimeOffset.UtcDateTime);
}
- private static Timestamp Normalize(long seconds, int nanoseconds)
+ internal static Timestamp Normalize(long seconds, int nanoseconds)
{
int extraSeconds = nanoseconds / Duration.NanosecondsPerSecond;
seconds += extraSeconds;