On Wed, 17 Feb 2016 07:43:50 GMT, Jacob Carlborg wrote:

On Tue, 16 Feb 2016 18:24:36 GMT, John More wrote:

I need to add a method to my class and there is no way I can get the program to recognize the route to the method adduserId. It is my understanding that this should end up with a router.post("/userid",&adduserId(......)) which would mean my client would access it with a post to /userid.

Any hints will certainly be appreciated.

I think that according to the naming convention it should be "addUserId", with a capital U. The documentation [1] says:

"Note that the prefix word must be all-lowercase and is delimited by either an upper case character, a non-alphabetic character, or the end of the string."

[1]

/Jacob Carlborg

Jacob,
Thank you for your quick response.

I was able to get it working correctly but discovered some anomalies along the way; that, I am sure if pursued would lead me into the depths of the framework where a mere mortal as I should fear to tread.

The addUserId(userData ud) would not work with any form of path "/userId, /userid, /user". What did work was addUserid(userData ud) with a path of "/userid".

After finding your documentation reference I looked at the
URLRouter registerRestInterface(TImpl)(
URLRouter router,
TImpl instance,
RestInterfaceSettings settings = null
);
and in particular the settings.methodStyle where I think the default is likely to be lowerCase. Unfortunately figuring out how to set this on the call is beyond me at this point but I do have it working.

Thanks Again
John