zoukankan      html  css  js  c++  java
  • Android 源码阅读之建立3G网络流程

    彩信是通过http协议发送数据的,因此,要先建立数据通路3G

    发彩信时,会自动启动建立3G网络,不好跟代码,还是从设置中跟踪代码简单些

    com.android.phone.Settings.java
    onPreferenceTreeClick -> if (preference == mButtonDataEnabled) - ConnectivityManager.setMobileDataEnabled(true)
    frameworks/base/core/java/android/net/ConnectivityManager.java
    setMobileDataEnabled -> ConnectivityService.setMobileDataEnabled
    frameworks/base/services/java/com/android/server/ConnectivityService.java
    setMobileDataEnabled -> MyHandler.sendMessage[EVENT_SET_MOBILE_DATA] -> handleMessage EVENT_SET_MOBILE_DATA ->handleSetMobileData -> MobileDataStateTracker.reconnect()
    frameworks/base/core/java/android/net/MobileDataStateTracker.java
    reconnect -> setEnableApn -> CompositePhoneInterfaceManager.enableApnType
    ...
    frameworks/base/telephony/java/com/android/internal/telephony/DataConnectionTracker.java
    setEnabled:EVENT_ENABLE_NEW_APN -> handleMessage -> onEnableApn -> onEnableNewApn
    frameworks/base/telephony/java/com/android/internal/telephony/gsm/GsmDataConnectionTracker.java
    onEnableNewApn() -> cleanUpConnection -> DataConnection.disconnect[EVENT_DISCONNECT_DONE] -> onDisconnectDone -> trySetupData ->setupData -> DataConnection.connect EVENT_CONNECT -> CdmaDataConnection.onConnect -> phone.mCM.setupDataCall
  • 相关阅读:
    日期时间检查(格式为:YYYY-MM-DD HH:MM:SS)
    日期合法性验证(格式为:YYYY-MM-DD或YYYY/MM/DD )
    [转]Attribute在.net编程中的应用
    WCF
    [转]使用C#开发ActiveX控件
    在 IIS 中承载 WCF 服务
    [转]一个完整的Installshield安装程序实例
    反射
    特性
    迭代器
  • 原文地址:https://www.cnblogs.com/jimwind/p/2680195.html
Copyright © 2011-2022 走看看