• LayoutInflater


    将资源文件实例化为类的工具;

    inflate
    [in'fleit]
    vt., vi.
      使膨胀;打气
    to inflate a tire
    给轮胎打气
      使通货膨胀
     
    android解释:实例化,实现


    /**
    * Instantiates a layout XML file into its corresponding {@link android.view.View}
    * objects. It is never used directly. Instead, use
    * {@link android.app.Activity#getLayoutInflater()} or
    * {@link Context#getSystemService} to retrieve a standard LayoutInflater instance
    * that is already hooked up to the current context and correctly configured
    * for the device you are running on. For example:
    *
    * <pre>LayoutInflater inflater = (LayoutInflater)context.getSystemService
    * (Context.LAYOUT_INFLATER_SERVICE);</pre>
    *
    * <p>
    * To create a new LayoutInflater with an additional {@link Factory} for your
    * own views, you can use {@link #cloneInContext} to clone an existing
    * ViewFactory, and then call {@link #setFactory} on it to include your
    * Factory.
    *
    * <p>
    * For performance reasons, view inflation relies heavily on pre-processing of
    * XML files that is done at build time. Therefore, it is not currently possible
    * to use LayoutInflater with an XmlPullParser over a plain XML file at runtime;
    * it only works with an XmlPullParser returned from a compiled resource
    * (R.<em>something</em> file.)
    *
    * @see Context#getSystemService
    */
  • 相关阅读:
    wifi与wimax
    短信中心号码
    (安卓)黑盒测试技巧个人整理
    数组实现栈的结构(java)
    tikv性能参数调优
    pt-table-checksum工具MySQL主从复制数据一致性
    MySQL索引原理以及类型
    TiDB数据库 mydumper与loader导入数据
    Innodb的体系结构
    MySQL核心之双一原则
  • 原文地址:https://www.cnblogs.com/feng9exe/p/5726066.html
Copyright © 2020-2023  润新知