Hi all,
It seems the SFS API does not callback the userVariablesUpdate
Has you can see below the message Command .... is mine indicating which event i receive.
As you can see onUserCountChange message is received and i'm called by SFS aPI
but for userVariablesUpdate i received well but i'm not called by the SFS API
Thanks for your help.
uffer is required.
I/ ( 1213): Command ......... onUserCountChange
I/SmartFoxClient( 1213): [ RECEIVED ]: <msg t='sys'><body action='uCount' r='24' u='0' s='0'></body></msg>, (len: 67)
I/global ( 1213): Default buffer size used in BufferedReader constructor. It would be better to be explicit if an 8k-char buffer is required.
I/ ( 1213): Command ......... onUserCountChange
I/SmartFoxClient( 1213): [ RECEIVED ]: <msg t='sys'><body action='uVarsUpdate' r='24'><user id='0' /><vars><var n='state' t='s'><![CDATA[AVAILABLE]]></var></vars></body></msg>, (len: 136)
I/global ( 1213): Default buffer size used in BufferedReader constructor. It would be better to be explicit if an 8k-char buffer is required.
Java Android Version bug FOUND
Hi all, Hi Lapo,
I found the SFS Bug
in the syshandler you deal on the bad element to find the user
On the body it's better
An other thing with the current code i should have been raised with a NullPointer but i don't have it Does the errors handling is correct .
I'm used with java code so no problem for me but for unused developper they can ask for a week if the error is in their code or in the SFS
Hope this help.
Croco
public void handleUserVarsUpdate(IXMLElement xmlData)
{
IXMLElement body = xmlData.getFirstChildNamed("body");
IXMLElement user = xmlData.getFirstChildNamed("user");
....
}
public void handleUserVarsUpdate(IXMLElement xmlData)
{
IXMLElement body = xmlData.getFirstChildNamed("body");
IXMLElement user = body.getFirstChildNamed("user");
....
}
I found the SFS Bug
in the syshandler you deal on the bad element to find the user
On the body it's better
An other thing with the current code i should have been raised with a NullPointer but i don't have it Does the errors handling is correct .
I'm used with java code so no problem for me but for unused developper they can ask for a week if the error is in their code or in the SFS
Hope this help.
Croco
public void handleUserVarsUpdate(IXMLElement xmlData)
{
IXMLElement body = xmlData.getFirstChildNamed("body");
IXMLElement user = xmlData.getFirstChildNamed("user");
....
}
public void handleUserVarsUpdate(IXMLElement xmlData)
{
IXMLElement body = xmlData.getFirstChildNamed("body");
IXMLElement user = body.getFirstChildNamed("user");
....
}
It looks like you are using an older version of the API.
Please make sure to download the latest release, we have made quite a few updates and fixes recently.
http://www.smartfoxserver.com/labs/API/
Please make sure to download the latest release, we have made quite a few updates and fixes recently.
http://www.smartfoxserver.com/labs/API/
Hi croco,
in it.gotoandplay.smartfoxclient.handlers.SysHandler you have
Is this the current content of the zip file you download from the API page? If not can you check what is the SysHandler.java last modification date? Maybe you see a cached file.
in it.gotoandplay.smartfoxclient.handlers.SysHandler you have
Code: Select all
public void handleUserVarsUpdate(IXMLElement xmlData)
{
IXMLElement body = xmlData.getFirstChildNamed("body");
IXMLElement user = body.getFirstChildNamed("user");
Is this the current content of the zip file you download from the API page? If not can you check what is the SysHandler.java last modification date? Maybe you see a cached file.
Return to “Java2SE / Android Client API”
Who is online
Users browsing this forum: No registered users and 24 guests