Static Entities in Web Service

Static Entities in Web Service


In .NET I'm used to create an enumerated and use that enumerated as a parameter of a Web Service.
Something like

public enum ConfigName{
        ValueSample = 0,
        ValueXPTO = 1,
        ValueACME = 2

And I can use it in a webservice

public void service(ConfigName name)

And if someone use my service, they use the enum to fill the parameter value.

In outsystems, if I use a Static Entity as a input parameter of a WebService, the webmethod parameter is of type int, instead of the type of the static entity, that is supposed to behave like a enumeration.

Is there anyway of doing this in outsystems?

Best regards
Paulo Correia
Outsystems Noob
Hi Paulo,

What gets written to the web service in the case of static entities is the static entity's identifier.

If you want you can have a static entity with an identifier attribute of type Text and in that case I believe that it would be the text which is transmitted.

Let us know if you were able to pull this off.

Ricardo Silva
Paulo -

If the concern is that you are getting type "int" as input and not the Identifier type, just use the "IntegetToEntityRefInteger" function to convert the int to the static entity's ID.