com.amap.api.navi.view

## 类 TrafficProgressBar

- java.lang.Object
- - FrameLayout
  - - com.amap.api.navi.view.TrafficProgressBar

-     public class TrafficProgressBar
      extends FrameLayout

  实时交通信息路况光柱图view类
  Real-time traffic information road condition bar chart view class
  从以下版本开始:
    5.4.0

- - ### 方法概要

    所有方法 实例方法 具体方法
    限定符和类型 | 方法和说明
    --- | ---
    `void` | `setJamTrafficColor(int jamTrafficColor)` 设置拥堵状态的颜色 Set the color of congested status
    `void` | `setSlowTrafficColor(int slowTrafficColor)` 设置交通状况缓慢状态的颜色 Set the color of slow traffic condition status
    `void` | `setSmoothTrafficColor(int smoothTrafficColor)` 设置交通状况情况良好下的颜色 Set the color when traffic conditions are good
    `void` | `setUnknownTrafficColor(int unknownTrafficColor)` 设置未知路况状态的颜色 Set the color of unknown road condition status
    `void` | `setVeryJamTrafficColor(int veryJamTrafficColor)` 设置非常拥堵状态的颜色 Set the color of very congested status
    `void` | `update(int allLength, int retainLength, java.util.List<AMapTrafficStatus> traffics)` 更新光柱条 Update the bar chart
    `void` | `updateTmcBarTxtColor(boolean isNight)` 更新光柱图昼夜显示模式 Update the day/night display mode of the bar chart

    - ### 从类继承的方法 java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### 方法详细资料

    - #### update

          public void update(int allLength,
                             int retainLength,
                             java.util.List<AMapTrafficStatus> traffics)

      更新光柱条
      Update the bar chart
      参数:
        `allLength` - 整条路线长度
        Total route length
        `retainLength` - 剩余距离
        Remaining distance
        `traffics` - 交通状态列表
        Traffic status list

    - #### updateTmcBarTxtColor

          public void updateTmcBarTxtColor(boolean isNight)

      更新光柱图昼夜显示模式
      Update the day/night display mode of the bar chart

    - #### setUnknownTrafficColor

          public void setUnknownTrafficColor(int unknownTrafficColor)

      设置未知路况状态的颜色
      Set the color of unknown road condition status
      参数:
        `unknownTrafficColor` - 颜色代码值
        Color code value

    - #### setSmoothTrafficColor

          public void setSmoothTrafficColor(int smoothTrafficColor)

      设置交通状况情况良好下的颜色
      Set the color when traffic conditions are good
      参数:
        `smoothTrafficColor` - 颜色代码值
        Color code value

    - #### setSlowTrafficColor

          public void setSlowTrafficColor(int slowTrafficColor)

      设置交通状况缓慢状态的颜色
      Set the color of slow traffic condition status
      参数:
        `slowTrafficColor` - 颜色代码值
        Color code value

    - #### setJamTrafficColor

          public void setJamTrafficColor(int jamTrafficColor)

      设置拥堵状态的颜色
      Set the color of congested status
      参数:
        `jamTrafficColor` - 颜色代码值
        Color code value

    - #### setVeryJamTrafficColor

          public void setVeryJamTrafficColor(int veryJamTrafficColor)

      设置非常拥堵状态的颜色
      Set the color of very congested status
      参数:
        `veryJamTrafficColor` - 颜色代码值
        Color code value