环信的消息返回,是什么的格式
对于text的返回如下:msg{from:custom, to:qianhua1 body:txt:"hwhwhq"
对于voice的返回如下:
msg{from:custom, to:qianhua1 body:voice:custom20151026T104019.amr,localurl:/storage/emulated/0/Android/data/com.qianhua.bestonn3/owant#owant/qianhua1/voice/ea824f60-7b8a-11e5-b405-750b8ada4597,remoteurl:http://182.92.228.160:80/owant/owant/chatfiles/ea824f60-7b8a-11e5-b405-750b8ada4597,length:6
首先,如何解析出声音?这个是什么格式呀?
对于voice的返回如下:
msg{from:custom, to:qianhua1 body:voice:custom20151026T104019.amr,localurl:/storage/emulated/0/Android/data/com.qianhua.bestonn3/owant#owant/qianhua1/voice/ea824f60-7b8a-11e5-b405-750b8ada4597,remoteurl:http://182.92.228.160:80/owant/owant/chatfiles/ea824f60-7b8a-11e5-b405-750b8ada4597,length:6
首先,如何解析出声音?这个是什么格式呀?
没有找到相关结果
已邀请:
3 个回复
zhangnan
赞同来自: 欧拉啊旺
根据url地址下载语音文件
欧拉啊旺
我通过EMMessage的getBody().toSting获得上面的信息,localurl:是说明本地已经有了语音?
而且通过你们的EMMessage的
getStringAttribute("localurl") 来获得localurl,异常了com.easemob.exceptions.EaseMobException: attribute localurl not found,说没有找到
zhangnan