final Thread thread=new Thread (
@Override
公共语音运行(}
try {
filefile=newfile(path;
//获取文件大小
long length=file.length (;
//制作保存文件数据的数据
byte[] fileData=null;
try {
is=new file inputstream (文件);
}catch(filenotfoundexceptione ) {
e .打印任务跟踪(;
}
int bytesRead=0;
将数据读入byte数组
List temp=new ArrayList (;
int len=0;
fileData=new byte[1000*1000*2];
while((len=is.read ) ) Filedata )!=-1 )
{
temp=new ArrayList (;
temp.add(bytearrayInputstream;
//上传流文件
registercontrolservice.submitvedioson (
temp.clear (;
byteArrayInputStream.close (;
subIdx;
}
if(is!=null完成后关闭输入流
is.close (;
}catch(exceptionex ) {
system.out.print(ex.tostring () ' dujq );
String a=ex ' ';
}
Handler.post(callback );
}
(;