Dukascopy
 
 
Wiki JStore Search Login

Attention! Read the forum rules carefully before posting a topic.

    Try to find an answer in Wiki before asking a question.
    Submit programming questions in this forum only.
    Off topics are strictly forbidden.

Any topics which do not satisfy these rules will be deleted.

Getting last market open time and next market close time
 Post subject: Getting last market open time and next market close time Post rating: 0   New post Posted: Tue 27 Oct, 2015, 01:16 
User avatar

User rating: 6
Joined: Thu 19 May, 2011, 11:14
Posts: 235
Location: South Africa,
Given a long t representing the a historical date-time, how do I use the API to get the time of market open preceding t?

And how can I get the time of market close following t?


 
 Post subject: Re: Getting last market open time and next market close time Post rating: 1   New post Posted: Thu 29 Oct, 2015, 16:08 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
JForex trading hours can be found here:
https://www.dukascopy.com/swiss/english ... unts/link/

From SDK they can be obtained with these methods:
context.getDataService().getOfflineTimeDomain()
context.getDataService().getOfflineTimeDomain(int shift)


We do not provide trading hours for particular instrument.


 
 Post subject: Re: Getting last market open time and next market close time Post rating: 0   New post Posted: Fri 30 Oct, 2015, 19:39 
User avatar

User rating: 6
Joined: Thu 19 May, 2011, 11:14
Posts: 235
Location: South Africa,
Thank you. Do these methods (getOfflineTimeDomain(long from, long to), isOfflineTime(long t) etc.) block while consulting the server or does the API calculate the result on the local machine and return quickly?


 
 Post subject: Re: Getting last market open time and next market close time Post rating: 0   New post Posted: Thu 05 Nov, 2015, 09:37 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
getOfflineTimeDomain is calculated locally without using server.


 

Jump to:  

cron
  © 1998-2025 Dukascopy® Bank SA
On-line Currency forex trading with Swiss Forex Broker - ECN Forex Brokerage,
Managed Forex Accounts, introducing forex brokers, Currency Forex Data Feed and News
Currency Forex Trading Platform provided on-line by Dukascopy.com