I'm attempting to pass a string as a config parameter to a custom XDC object, and am having difficulties in the xs script in copying that string to my instance struct. Below is a snippet of what I am attempting.
xdc module:
instance:
config String MessageQName;
internal:
struct Instance_State
{
char MessageQName[20];
}
In the xs script I have attempted:
function instance$static$init(obj, params)
{
obj.MessageQName = new String(params.MessageQName);
or
obj.MessageQName = params.MessageQName;
}
There is something fundamental I am missing here.
Thanks