Note that
"getListenPort()" returns an int. Is that a problem?
yes, that's a problem. Python needs strings for concatenation
apparently. you can use the .toString() methon on the int to convert it
to a string ;)
a=1
s='hello'
print s+a
TypeError: __add__ nor __radd__ defined for these operands
Fredrik Lundh wrote:
> [EMAIL PROTECTED] wrote:
>
>
>>I'm using Jython (actually WebLogic WLST), and trying to do something
>>really simple. I want to create a string from two function calls and a
>>literal, like:
>>
>> serverport = server.getListenAddress() + ':' + server.getListenPort()
>>
>>
[EMAIL PROTECTED] wrote:
> I'm using Jython (actually WebLogic WLST), and trying to do something
> really simple. I want to create a string from two function calls and a
> literal, like:
>
> serverport = server.getListenAddress() + ':' + server.getListenPort()
>
> This complains:
>
> TypeError:
I'm using Jython (actually WebLogic WLST), and trying to do something
really simple. I want to create a string from two function calls and a
literal, like:
serverport = server.getListenAddress() + ':' + server.getListenPort()
This complains:
TypeError: __add__ nor __radd__ defined for these o