JZTXT
  • 首页
  • Ai
  • Java
  • Python
  • Android
  • Mysql
  • JavaScript
  • Html
  • CSS

swift 致命错误:Double值无法转换为Int,因为它是无限或NaN

发布时间 2023-09-04 16:27:58作者: 懂事长qingzZ

 

let time = TimeInterval(asset.duration.seconds)
                    if (time.isNaN || time.isInfinite){
                        print("无效文件  time.recordDuration.isNaN ||  time.recordDuration.isInfinite    ssssssss")
                        self.isInvalid = true
                    }

 

参考:

https://www.jianshu.com/p/ac50c3466cd1

https://qa.1r1g.com/sf/ask/2940004301/

 

    本栏目推荐文章
  • vscode错误:Unable to connect to VS Code server: Error in request.
  • 数据库 - 已成功与服务器建立连接,但在登录过程中发生错误。(提供程序:SSL提供程序,错误:0-证书链是由不受信任的颁发机构颁发的。)”asp.net core:8.0
  • Oracle 19c 升级错误【verify_queryable_inventory returned ORA-20001: Latest xml inventory is not loaded into table】
  • C# 面试题 如何优雅的检测一个double decimal是否含有小数部分 是否为小数
  • c++编译OpenSceneGraph-3.4 出现 error: narrowing conversion of ‘-1’ from ‘int’ to ‘char’ inside { } [-Wnarrowing]
  • C语言中这几种数组,弄明白了吗?int(*pai[2])[5],int *aapi[2][2], int **p[2], int *numT[5], int(*num2)[5]
  • 从错误中学习: 了解Go编程的6个坏习惯
  • iMessage群发,iMessage群发软件开发(常见代码错误与解决方案篇)
  • js 判断NaN
  • C语言int * (* (*fp1) (int) ) [10]声明是啥意思呢?
版权声明:本网站为非赢利性站点,本网站所有内容均来源于互联网相关站点自动搜索采集信息,相关链接已经注明来源。
联系我们