TelephonyManager 检测拨出呼叫时的语音邮件

发布于 2024-09-19 22:33:37 字数 179 浏览 2 评论 0原文

再次感谢我在这里收到的所有帮助!

我编写了一个侦听器来检测呼叫何时结束。 此外,我想检测收件人是否接听或我是否最终到达邮箱。

然而,我只是不知道如何做到这一点,并且在互联网上找不到任何内容(可能是搜索错误的术语,就像大多数时候的情况一样)。

非常感谢您的帮助。

再次感谢! 铬0n

thanks again for all the help I have received here!

I have written a Listener that detects when a call has ended.
Furthermore I want to detect wheter the receiver picked up or I ended up on the mailbox.

However, I just can't figure out how to it and can't find anything on the internet (probably searching for the wrong term, as is the case most of the time).

Help would be much appreciated.

Thanks again!
Chr0n

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

一张白纸 2024-09-26 22:33:37
  • 可以检测通话何时结束:使用 PhoneStateListener。 CALL_STATE_IDLE 状态意味着挂断。
  • 接听/挂断电话:不可能。

最接近的方法是查看通话记录并从通话持续时间中找出答案。通话时长为零意味着另一端没有拿起电话。但这不是实时的,而是事后发生的。此外,它不会告诉你这个人是否去了语音信箱;如果他挂了怎么办...

我希望这会有所帮助...

  • Detect when a call has ended is possible: Use PhoneStateListener. A CALL_STATE_IDLE state means hang up.
  • Picked up/dropped call: not possible.

The closest thing would be to look at the call log and figure it out from the call duration. A call duration of zero means the other end didn't pick up the phone. But this is not real time, it's after the fact. Moreover it won't tell you if the person went to voicemail; what if he hung up...

I hope this helps a little bit...

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文