Issue Details (XML | Word | Printable)

Key: NUCJODATIME-11
Type: New Feature New Feature
Status: Closed Closed
Resolution: Fixed
Priority: Minor Minor
Assignee: Unassigned
Reporter: Jasper Siepkes
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
DataNucleus Types : JodaTime

Make the start and end instant of an Interval usable in a filter

Created: 18/Jun/12 10:37 PM   Updated: 06/Jul/12 09:39 AM   Resolved: 19/Jun/12 08:33 AM
Component/s: None
Affects Version/s: None
Fix Version/s: 3.1.0.m3

File Attachments: 1. Text File store_types_jodatime.patch (14 kB)
2. Text File test_jdo_jodatime.patch (5 kB)


Forum Thread URL: http://www.datanucleus.org/servlet/forum/viewthread_thread,7176


 Description  « Hide
The start and end instant of a JodaTime Interval should be usable in a filter. This way a user can find objects within specific Intervals. The syntax would look like this "intervalField.getStart() < :date".

Jasper Siepkes added a comment - 18/Jun/12 10:39 PM
Attached patch for the "store.types.jodatime" project to accommodate this. Also attached test cases patch for the "test.jdo.jodatime" project.

Jasper Siepkes made changes - 18/Jun/12 10:39 PM
Field Original Value New Value
Attachment store_types_jodatime.patch [ 11668 ]
Attachment test_jdo_jodatime.patch [ 11669 ]
Jasper Siepkes added a comment - 18/Jun/12 10:41 PM
The above patches make it possible to use "intervalField.getStart()" and "intervalField.getEnd()" in a filter. Hope I got everything right; I'm still a novice in the inner workings of DataNucleus and would appreciate feedback.

Andy Jefferson added a comment - 19/Jun/12 08:33 AM
SVN trunk has this now, thx. PS the tests are in test.jdo.general now; test.jdo.jodatime is deprecated (only used in <=3.0)

Andy Jefferson made changes - 19/Jun/12 08:33 AM
Status Open [ 1 ] Resolved [ 5 ]
Fix Version/s 3.1.0.m3 [ 11593 ]
Resolution Fixed [ 1 ]
Andy Jefferson made changes - 06/Jul/12 09:39 AM
Status Resolved [ 5 ] Closed [ 6 ]