文件名称:addjsym
介绍说明--下载内容均来自于网络,请自行研究使用
应用平台: Android
应用案例: 大量商品的限时抢购等。
类似于这样的倒计时,不知道大家有没有遇到过,大家又能想到哪些方案?????
1、每一秒到服务器上面去取一次数据?
2、每一秒,通过一个Handler去循环遍历,对每一条去刷新一次时间控件?
3、还是大家有其它的想法。
上述两种方案都不可取:
1、网络连接有时间差,况且数据访问量大的情况,服务器没法承受。
2、 循环遍历可行,但是要在数据量少的情况下,如果数据量过大,那么会卡屏,对系统内存的占用也较高。
本源码的方案是对Android 系统中 DigitalClock 进行一次封装。
通过继承以下方法并改变内部的实现。 -Application platform: Android
Application case: a large number of commodities, such as the rush to buy a lot of goods.
Similar to such a countdown, do not know if we have encountered, we can think of what?????????
1, every second to the server to get a data?
2, every second, through a Handler to loop traversal, every time to refresh the time control?
3, or we have other ideas.
The above two schemes are not desirable:
1, the network is connected with the time difference, moreover, the amount of data access, the server can not afford.
2, loop traversal is feasible, but in the case of a small amount of data, if the data is too large, then the card screen, the system memory occupancy is also higher.
The source of the program is to Android system in a package DigitalClock.
By inheriting the following methods and changing the internal implementation.
应用案例: 大量商品的限时抢购等。
类似于这样的倒计时,不知道大家有没有遇到过,大家又能想到哪些方案?????
1、每一秒到服务器上面去取一次数据?
2、每一秒,通过一个Handler去循环遍历,对每一条去刷新一次时间控件?
3、还是大家有其它的想法。
上述两种方案都不可取:
1、网络连接有时间差,况且数据访问量大的情况,服务器没法承受。
2、 循环遍历可行,但是要在数据量少的情况下,如果数据量过大,那么会卡屏,对系统内存的占用也较高。
本源码的方案是对Android 系统中 DigitalClock 进行一次封装。
通过继承以下方法并改变内部的实现。 -Application platform: Android
Application case: a large number of commodities, such as the rush to buy a lot of goods.
Similar to such a countdown, do not know if we have encountered, we can think of what?????????
1, every second to the server to get a data?
2, every second, through a Handler to loop traversal, every time to refresh the time control?
3, or we have other ideas.
The above two schemes are not desirable:
1, the network is connected with the time difference, moreover, the amount of data access, the server can not afford.
2, loop traversal is feasible, but in the case of a small amount of data, if the data is too large, then the card screen, the system memory occupancy is also higher.
The source of the program is to Android system in a package DigitalClock.
By inheriting the following methods and changing the internal implementation.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
bin
gen
...\com
...\...\veally
...\...\......\timesale
...\...\......\........\BuildConfig.java
...\...\......\........\R.java
libs
res
...\drawable-hdpi
...\.............\ic_launcher.png
...\.............\topbar.png
...\drawable-ldpi
...\.............\ic_launcher.png
...\drawable-mdpi
...\.............\ic_launcher.png
...\drawable-xhdpi
...\..............\ic_action_search.png
...\..............\ic_launcher.png
...\layout
...\......\activity_time_sale.xml
...\......\adapter_item.xml
...\values
...\......\dimens.xml
...\......\strings.xml
...\......\styles.xml
src
...\com
...\...\veally
...\...\......\timesale
...\...\......\........\ActivityTimeSale.java
...\...\......\........\AdapterSaleItem.java
...\...\......\........\CustomDigitalClock.java
...\...\......\........\ProductItem.java
.classpath
.project
AndroidManifest.xml
proguard-project.txt
project.properties
说明.htm
assets
......\images
......\......\mini1.jpg
......\......\mini2.jpg
......\......\mini3.jpg
......\......\mini4.jpg
......\......\mini5.jpg
......\......\mini6.jpg
......\......\mini7.jpg
......\......\mini8.jpg