<?xml version="1.0" encoding="utf-8" ?><rss version="2.0"><channel><title><![CDATA[kerrysimon的博客]]></title><description><![CDATA[]]></description><link>https://blog.youkuaiyun.com/kerrysimon</link><language>zh-cn</language><generator>https://blog.youkuaiyun.com/</generator><copyright><![CDATA[Copyright &copy; kerrysimon]]></copyright><item><title><![CDATA[OKhttp源码流程分析笔记]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/86483945</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/86483945</guid><author>kerrysimon</author><pubDate>Mon, 14 Jan 2019 21:16:47 +0800</pubDate><description><![CDATA[okhttp主要包含构建者模式、责任链模式等。主要流程大致如下：

构建者模式构造request    okhttpclient对象   两套字段，在build方法返回赋值。

同步是调用在realCall类（实现Call接口）中的execute方法（设置拦截器链）中dispatcher的execute方法把请求添加到同步请求队列。在finally中调用dispatcher的finished方法，...]]></description><category></category></item><item><title><![CDATA[android    WindowManager]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419164</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419164</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:22:11 +0800</pubDate><description><![CDATA[项目中有一个到时锁屏的的功能，就是当到达特定时间后，程序弹出一个蒙层将界面锁住，用户不能进行其他操作  （ps：按home键和back键蒙层也还在），除非输入密码或按规定操作，才可移除蒙层。
 
 现将关键的使用代码简化贴出以供参考：

public class MainActivity extends Activity {

	private WindowManager.Layout]]></description><category></category></item><item><title><![CDATA[Android：Layout_weight属性解析]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419161</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419161</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:22:02 +0800</pubDate><description><![CDATA[Layout_weight属性只有在Linearlayout中才有效果。
该属性跟android:layout_width为wrap_content和match_parent有很大关系。
简单的说：
          以如下布局为例：
     
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/androi]]></description><category></category></item><item><title><![CDATA[Afinal的简单应用（二）]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419156</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419156</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:21:54 +0800</pubDate><description><![CDATA[上篇中叙述了Afinal的finalDB和finalActivity的用法，接下来讲FinalHttp和FinalBitmap。
 
 FinalHttp的使用方法：
        FinalHttp 对 HttpClient再次封装，最简洁的就是增加了许多回调的方法，对Get 和 Post 请求进行了简化。此外还有put,delete和download方法。另外一点就是FinalHttp]]></description><category></category></item><item><title><![CDATA[afinal的简单应用（一）]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419153</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419153</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:21:45 +0800</pubDate><description><![CDATA[Afinal简介：

Afinal 是一个android的sqlite orm 和 ioc 框架。同时封装了android中的http框架，使其更加简单易用；
使用finalBitmap，无需考虑bitmap在android中加载的时候oom的问题和快速滑动的时候图片加载位置错位等问题。
Afinal的宗旨是简洁，快速。约定大于配置的方式。尽量一行代码完成所有事情。

Afinal包含四大]]></description><category></category></item><item><title><![CDATA[android    webView与js交互]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419147</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419147</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:21:38 +0800</pubDate><description><![CDATA[android中通过WebView控件可以加载网页和本地的html文件。下面是一个简单的android与js交互Demo。
 
主类：
public class MainActivity extends Activity {
	WebView webview;
	Button btn;

	@SuppressLint({ "SetJavaScriptEnabled", "Javasc]]></description><category></category></item><item><title><![CDATA[android 按钮倒计时读秒]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419144</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419144</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:21:32 +0800</pubDate><description><![CDATA[最近项目中有涉及到android倒计时读秒功能的实现，于是上网搜了一下，各种方式都有，但是感觉要么存在bug，要么有点复杂，于是在参考了一些他人的实现方式后，自己写了一个。代码如下：public class MainActivity extends Activity {	private TimeCount timeCount;	private Button btn;	protec]]></description><category></category></item><item><title><![CDATA[广播机制方式]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419121</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419121</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:21:24 +0800</pubDate><description><![CDATA[安卓系统中广播可以分为两类：普通广播和有序广播。    普通广播是完全异步的，可以在同一时刻（逻辑上）被所有接收者接收到，消息传递的效率比较高，但缺点是：接收者不能将处理结果传递给下一个接收者，并且无法终止广播Intent的传播，就相当于普通的收音机广播；    有序广播则可以定义接受者的优先级，可以在清单文件中配置（intent-filter元素的android:priority属性）或者代]]></description><category></category></item><item><title><![CDATA[关于 android  service    和    thread]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419096</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419096</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:21:16 +0800</pubDate><description><![CDATA[在安卓系统中，service是运行在主线程中的，而thread是用来创建子线程的。二者毫无关系！ thread的运行时独立于activity的，当一个activity被销毁时，如果你没有主动停止 Thread 或者 Thread 里的 run 方法没有执行完毕的话，Thread 也会一直执行。当 Activity 被 finish 之后，你不再持有该 Thread 的引用。另一方面，你没有办法在不]]></description><category></category></item><item><title><![CDATA[handler机制]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419079</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419079</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:21:10 +0800</pubDate><description><![CDATA[andriod提供了Handler 和 Looper 来满足线程间的通信。handler是先进先出原则，而looper是用来轮询消息队列的。handler是存在于主线程中的，用来处理子线程通过message发来的数据信息，配合主线程更新UI页面。 handler有两个作用: 安排消息或Runnable 在某个主线程中某个地方执行；                    安排一个动作在不]]></description><category></category></item><item><title><![CDATA[android项目导入eclipse最后不能点击next和finish]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419061</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419061</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:21:00 +0800</pubDate><description><![CDATA[一般来说这个问题都是因为项目名称重复了，也就是说将要导入的这个项目的名称与eclipse中原本就存在的某一项目的名称重复了，注意是项目名称，如图中红色圈内所示。最简单的解决方法就是先将eclipse中原来的项目删除，但是如果改项目还有用，那么只需要将eclipse中的项目删除就好，之后还可以再导回来；若没有用了，删除时就可以把delete project content是on disk勾上，直接]]></description><category></category></item><item><title><![CDATA[ofbiz安装]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419045</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419045</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:20:54 +0800</pubDate><description><![CDATA[OFBIZ安装在官网下载ofbiz安装包。地址：http://ofbiz.apache.org/download.htmljava环境强烈推荐JDK1.6版本。虽然更高的版本也可，但是有时候需要更改一些配置文件，对新手来说很麻烦。还有ant包配置环境变量，包括：java的和 ant的之后解压ofbiz安装包。如解压到d：/OFBIZ在命令提示符窗口切换到解压ofbiz安装的文]]></description><category></category></item><item><title><![CDATA[Windows Installer程序包问题]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419031</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419031</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:20:46 +0800</pubDate><description><![CDATA[有时候当安装软件时会提示“Windows Installer 程序包有问题，此安装需要的程序不能运行。请与您的支持人员或程序包开发商联系”，去‘服务’看了Windows Installer也启动了，但就是提示错误。   这时不妨试试这个解决办法：下载安装微软提供的Windows Installer CleanUp Utility，它的主要功能是清除程序的Windows Installer配置信息]]></description><category></category></item><item><title><![CDATA[配置weblogic]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76419014</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76419014</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:20:38 +0800</pubDate><description><![CDATA[Weblogic配置文件过程中，在“配置管理服务器”处一般来说要单独取名字与adminServer区分，并且端口也要从新选择。]]></description><category></category></item><item><title><![CDATA[创建用户 授权]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76418995</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76418995</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:20:30 +0800</pubDate><description><![CDATA[MYSQL中创建新用户语句CREATE USER user01@'localhost' IDENTIFIED BY 'password1';mysql授权：user管理db全部权限GRANT ALL PRIVILEGES ON db.* TO user;]]></description><category></category></item><item><title><![CDATA[java环境配置]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76418976</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76418976</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:20:22 +0800</pubDate><description><![CDATA[java环境变量配置：classpath：.;%JAVA_HOME%\lib\dt.jar;%JAVA_HOME%\lib\tools.jar;Path：%JAVA_HOME%\bin;Java_home:C:\Program Files\Java\jdk1.8.0_25]]></description><category></category></item><item><title><![CDATA[数据导入 导出]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76418967</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76418967</guid><author>kerrysimon</author><pubDate>Mon, 31 Jul 2017 10:20:10 +0800</pubDate><description><![CDATA[数据库表的导入导出命令exp /imp的执行是在dos命令窗口执行，而不是在sqlplus窗口]]></description><category></category></item><item><title><![CDATA[Java JVM解析]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76349886</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76349886</guid><author>kerrysimon</author><pubDate>Sat, 29 Jul 2017 19:14:55 +0800</pubDate><description><![CDATA[类加载的过程：类从被加载到虚拟机内存开始，到被卸载出内存为止，生命周期是：加载、验证、准备、解析、初始化、使用和卸载。
 加载阶段：（1）通过一个类的权限定名来获取此类的二进制字节流
                 （2）将这个字节流所代表的静态存储结构转化为方法区的运行时数据结构。
                 （3）在java堆中生成一个代表这个类的class对象，作为方法区这些数]]></description><category></category></item><item><title><![CDATA[（二十二） IPC机制通讯]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76349819</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76349819</guid><author>kerrysimon</author><pubDate>Sat, 29 Jul 2017 19:06:15 +0800</pubDate><description><![CDATA[IPC是Inter-Process Communication的缩写。


多进程简介
Android对单个应用的内存做了限制，早期版本可能是16M。
通过给四大组建指定Android：process属性，开启多线程模式，无其他方法。特殊情况通过jni在native层fork一个新的进程。
进程以“：”开头的是当前进程的私有进程，其他组件不能和他跑在同一进程，全称是“：”前加包名；而进]]></description><category></category></item><item><title><![CDATA[（二十一）Android内存、性能优化]]></title><link>https://blog.youkuaiyun.com/kerrysimon/article/details/76349809</link><guid>https://blog.youkuaiyun.com/kerrysimon/article/details/76349809</guid><author>kerrysimon</author><pubDate>Sat, 29 Jul 2017 19:04:08 +0800</pubDate><description><![CDATA[性能优化的方法
布局优化：利用、以及ViewStub优化
      标签只支持以android:layout开头的属性，若设置了android:layout_*属性，则必须有android:layout_width(height)属性。也可设置   id，若布局也有id，以include指定的id为准。
      标签可以减少布局的层级。
       ViewStub继承了View，]]></description><category></category></item></channel></rss>