New type TimestampUtc

Description

Inspired by a blog post about the new UtcDateTime and LocalDateTime types I was hoping for Kind support for Timestamps too but that was not included. The included patch introduces the new type TimestampUtcType and I have included tests for it. It is bases on TimestampType which I needed to change a little bit but have changed it without breaking existing behavior regarding returned DateTime values and their Kind value.

I have xml documented the type and the type tests.

I tried regenating the documentation via "nant doc" but that failed. Please let me know if anything is missing.

Environment

None

Attachments

3
  • 05 Sep 2013, 02:55 PM
  • 28 Jan 2011, 05:00 AM
  • 28 Jan 2011, 04:38 AM

Activity

Show:

Frédéric Delaporte October 4, 2017 at 2:20 PM

UtcDateTime does no more cut fractional seconds and can be used as a timestamp. TimestampType as itself been deprecated in favor of DateTimeType which does no more cut fractional seconds too.

Frédéric Delaporte October 4, 2017 at 2:19 PM

Replaced by NH-3919.

Alex Zaytsev August 12, 2016 at 4:40 AM

Move unresolved improvements and new features with minor and trivial priorities to 4.2.0

Richard Harlen November 8, 2013 at 4:36 PM

I got the patch to work, but I get a Null Reference Exception when using it with a nullable type. In TimestampUtcType the IsEqual() method does not check if x or y are null before comparing their Kind.

Fernando Mato Mira October 4, 2013 at 7:20 PM

I converted the original patch without modifications or any stateless additions into a pull request:

https://github.com/nhibernate/nhibernate-core/pull/227

Obsolete

Details

Assignee

Reporter

Labels

Components

Affects versions

Priority

Who's Looking?

Open Who's Looking?
Created January 28, 2011 at 4:38 AM
Updated October 5, 2017 at 1:13 AM
Resolved October 5, 2017 at 1:13 AM
Who's Looking?