• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Get the correct time from Date object

 
Ranch Hand
Posts: 270
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I am working with Quartz Job Scheduler and get a Date object returned when rescheduling a Job. I want to show the exact time of this Date object, but it seems that something is going wrong. When I print out the time I got a totally wrong time:
Mon Dec 12 14:43:40 CET 2005

Below you see the code I use:


Can you help me please?
[ June 27, 2007: Message edited by: Jeppe Fjord ]
 
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What Date did you set in the trigger you are trying to replace ?
Please add the following line before rescheduleJob :
 
Jeppe Sommer
Ranch Hand
Posts: 270
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Satou kurinosuke:
What Date did you set in the trigger you are trying to replace ?
Please add the following line before rescheduleJob :



Alright the above System.out.println prints out the same result:
Mon Dec 12 14:43:37 CET 2005

I found out that this date is the start time (java.util.Date startTime) of my trigger. I was just convinced that scheduler.rescheduleJob, would return the time that the job was rescheduled and not the starttime being initiated.

~ Alright I got it. Thanks for your help :-)
[ June 28, 2007: Message edited by: Jeppe Fjord ]
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yep, it returns the start time
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic