Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

Groovy Date Remove Or Clear Time Component

Groovy Date Remove Or Clear Time Component

When we are comparing Date instances, we usually just care about the date part and not the time Component. For more accurate comparison, it is sometimes desirable to remove the time component from a Date object. Below is an example on how to remove or clear time component from a Date instance in Groovy.



This post first appeared on Grails Cookbook, please read the originial post: here

Share the post

Groovy Date Remove Or Clear Time Component

×

Subscribe to Grails Cookbook

Get updates delivered right to your inbox!

Thank you for your subscription

×