Jump to content









Photo

get current date and time

date time sdk

  • Please log in to reply
1 reply to this topic

#1 Domalys

Domalys

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 15 March 2016 - 09:16 AM

Hello all,

 

I need to do a filter on a time slot, in a rules using sdk.

Could you help me to get the current time easily?

 

I supposed that I need to use Grrovy language, but I didn't find a solution.

 

 

Thank  you in advance.

 



#2 Domalys

Domalys

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 15 March 2016 - 01:16 PM

Hi all,

 

Finally I got the solution.

 

This is an example to get the hour :

 

import java.util.Date;

def someDate = new Date();
long hour= someDate.getTime();
return hour;






Also tagged with one or more of these keywords: date, time, sdk

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users