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.

How to define historical tester`s cache for TesterMain.java?
 Post subject: How to define historical tester`s cache for TesterMain.java? Post rating: 0   New post Posted: Mon 07 Jan, 2013, 20:28 
User avatar

User rating: 164
Joined: Mon 08 Oct, 2012, 10:35
Posts: 676
Location: NetherlandsNetherlands
Dear Support,

I am using the JForex SDK in Eclipse to backtest a strategy. I am using the TesterMain.java file, with the required modifications.
I would like to know if it is possible to store the selected instrument`s cache in a defined location? By default it stores it under c:\Users\<username>\AppData\Local\JForex\.cache\.

In the JForex client it is possible to define a cache location. I would like to use the same location for both the JForex client and for the TesterMain application, so I don`t have to download and store twice.

Thanks and regards.


 
The Best Answer  Post subject: Re: How to define historical tester`s cache for TesterMain.java? Post rating: 0   New post Posted: Tue 08 Jan, 2013, 18:05 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
See:
https://www.dukascopy.com/client/javadoc/com/dukascopy/api/system/IClient.html#setCacheDirectory(java.io.File)


 
 Post subject: Re: How to define historical tester`s cache for TesterMain.java? Post rating: 0   New post Posted: Wed 09 Jan, 2013, 11:08 
User avatar

User rating: 164
Joined: Mon 08 Oct, 2012, 10:35
Posts: 676
Location: NetherlandsNetherlands
Dear Support,

Thank you!
The javadoc says:
Quote:
WARNING: JForex might delete all folder's content if folder already existed AND was not created by this method call

Is the JForex platform`s Historical Tester using this method call as well? I want to possibly avoid that the cache being deleted every time if I switch between testing a strategy in the platform and in the SDK. As the whole purpose of this would be that both the platform and the SDK using the same cahce location with the same content.


 
 Post subject: Re: How to define historical tester`s cache for TesterMain.java? Post rating: 0   New post Posted: Tue 15 Jan, 2013, 18:46 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
tcsabina wrote:
Is the JForex platform`s Historical Tester using this method call as well?
It is rather straightforward to check that it does not.


 
 Post subject: Re: How to define historical tester`s cache for TesterMain.java? Post rating: 0   New post Posted: Wed 16 Jan, 2013, 14:56 
User avatar

User rating: 164
Joined: Mon 08 Oct, 2012, 10:35
Posts: 676
Location: NetherlandsNetherlands
API Support wrote:
It is rather straightforward to check that it does not.

Is that mean that using the same directory from the client and from the SDK-API is not going to work? If the Client not using this method, I would assume that this method will clear/delete the content of the Client`s cache directory, just as the wiki states.
Or do I misunderstood something?


 
 Post subject: Re: How to define historical tester`s cache for TesterMain.java? Post rating: 0   New post Posted: Thu 17 Jan, 2013, 17:24 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
tcsabina wrote:
Is that mean that using the same directory from the client and from the SDK-API is not going to work?
They do work. In case of any doubt, you can always check that this is the case.


 

Jump to:  

  © 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