I would like to concatenate a string with a text item. I’m not clear on whether I need to use the .toString or not. Can someone clarify which of the following is correct? I would like to learn more, so please point me to some documentation if possible on this. The Designer seems to think all 3 forms of the PARTITION1_STATUS.* are fine.
rule "Push Status"
when
Item PARTITION1_STATUS changed
then
var String requestToSend
requestToSend = "http://127.0.0.1:5555/request?id=" + PARTITION1_STATUS.state
requestToSend = "http://127.0.0.1:5555/request?id=" + PARTITION1_STATUS.state.toString
requestToSend = "http://127.0.0.1:5555/request?id=" + PARTITION1_STATUS.state.toString()
sendHttpGetRequest(requestToSend)
end