Dukascopy
 
 
Wiki JStore Search Login

Custom enum not supported on Remote Server?
 Post subject: Custom enum not supported on Remote Server? Post rating: 0   New post Posted: Mon 27 Jan, 2014, 01:38 
User avatar

User rating: 98
Joined: Mon 23 Jul, 2012, 02:02
Posts: 656
Location: United States, Durham, NC
Hi,

I just designed a Strategy module with a public custom enum.

Is it true that this Parameter Type is not supported on the Remote Server?
That was the error message reported.

Unable to run strategy remotely : Parameter type is not supported : jforex.sayers.GrabTrader$GrabMaType

Thanks,
HyperScalper


 
 Post subject: Re: Custom enum not supported on Remote Server? Post rating: 1   New post Posted: Mon 27 Jan, 2014, 06:40 
User avatar

User rating: 96
Joined: Mon 09 Sep, 2013, 07:09
Posts: 287
Location: Ukraine, SHostka
https://www.dukascopy.com/wiki/#Strategy_parameters/Usage_of_custom_enumeration


 
 Post subject: Re: Custom enum not supported on Remote Server? Post rating: 0   New post Posted: Mon 27 Jan, 2014, 17:22 
User avatar

User rating: 98
Joined: Mon 23 Jul, 2012, 02:02
Posts: 656
Location: United States, Durham, NC
OK, it says at the very bottom that custom enums
are not available on the Remote server.

Can this be implemented please?

In the meantime, I'll just find a workaround.

My assumption all along was that any parameters
which worked in the Local Run context would also
work for the Remote Run context.

Currently, this is not true.

HyperScalper


 
 Post subject: Re: Custom enum not supported on Remote Server? Post rating: 0   New post Posted: Tue 28 Jan, 2014, 10:01 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
hyperscalper wrote:
OK, it says at the very bottom that custom enums
are not available on the Remote server.

Can this be implemented please?
It is not possible to work with client strategy own types, because there is no class definition on the remote server.


 
 Post subject: Re: Custom enum not supported on Remote Server? Post rating: 0   New post Posted: Tue 28 Jan, 2014, 13:10 
User avatar

User rating: 164
Joined: Mon 08 Oct, 2012, 10:35
Posts: 676
Location: NetherlandsNetherlands
Quote:
It is not possible to work with client strategy own types, because there is no class definition on the remote server.

Why there is such restriction, if I may ask?


 
 Post subject: Re: Custom enum not supported on Remote Server? Post rating: 0   New post Posted: Tue 28 Jan, 2014, 14:54 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
This is a system restriction. We are going to implement a combo box for a new Configurable field options values, e.g.:
@Configurable(value="mode", options = {"Bullish", "Bearish"})
public String mode = "Bullish";


 
 Post subject: Re: Custom enum not supported on Remote Server? Post rating: 0   New post Posted: Thu 30 Jan, 2014, 22:36 
User avatar

User rating: 98
Joined: Mon 23 Jul, 2012, 02:02
Posts: 656
Location: United States, Durham, NC
You guys are the experts, but my understanding is that
ALL of the class files are defined in the .jfx file, so the
custom enums are available by introspection.

Even though the IStrategy is limited and cannot do introspection,
the Remote Server launcher could certainly do appropriate
introspection, in exactly the same way as the Local Run does.

Anyway, just my 2 cents in this. I just worked around it by
using strings and validating in onStart, although that is by
no means as elegant as a custom enum.

I would suggest you keep the Remote Run as much as possible
exactly the same as Local Run from the perspective of
parameters. Now, of course, there are certain things you
cannot do on Remote which can do Locally but, as for
parameter initialization, I don't see why you can't do it
in the same way ? ...

HyperScalper


 
 Post subject: Re: Custom enum not supported on Remote Server? Post rating: 0   New post Posted: Thu 22 May, 2014, 09:35 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
See:
https://www.dukascopy.com/wiki/#Strategy_parameters/Constants_for_Remote_mode


 

Jump to:  

  © 1998-2024 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