- 浏览: 21684 次
- 性别:
- 来自: 北京
最新评论
文章列表
//设置节点
public class LinkNode {
private Object obj;// 节点内数据对象
private LinkNode child;// 对下一个节点的引用
private LinkNode parent;// 对下一个节点的引用
public LinkNode(Object obj) {
this.obj = obj;
}
public void setObj ...
//测试类
public class ListTest {
public static void main(String[] args) {
// 创建一个数组对象
Mylist<Integer> list = new Mylist<Integer>();
for (int i = 0; i < 10; i++) {
int s = 10*i;
list.a ...
/**
* 清除图片所有缓存
*/
public void clearImageAllCache(Context context) {
clearImageDiskCache(context);
clearImageMemoryCache(context);
String ImageExternalCatchDir=context.getExternalCacheDir()+ ExternalCacheDiskCacheFactory.DEFAULT_DISK_CACHE_DIR;
...
package bwie.zheng;
import android.support.v7.widget.RecyclerView;
import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;
import java.util.List;
/**
* Created by Zhengaihua ...
LinearLayoutManager layoutManager1 = new LinearLayoutManager(getActivity());
layoutManager1.setOrientation(OrientationHelper.VERTICAL);
recybase.setLayoutManager(layoutManager1);
baseAdapter = new BaseAdapter(lists, getActivity());
recybase.setAdapter(b ...
package com.example.day11_yinpin2;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import android.media.MediaPlayer;
import android.os.Bundle;
import android.app.Activity;
import android.view.Menu;
import android.view.View;
import android.view.View.OnClic ...
// 扫描sd卡
public void scanMusic(File file) {
File[] listFiles = file.listFiles(new FileFilter() {
@Override
public boolean accept(File pathname) {
if (pathname.isDirectory()) {
return true;
} else {
// 判断下一个文件的路径中是否包含。mp3
if (pathname.getPath().endsWith(&quo ...
package com.bwie.view;
import java.util.ArrayList;
import java.util.List;
import android.app.Activity;
import android.os.Bundle;
import android.os.Handler;
import android.support.v4.view.PagerAdapter;
import android.support.v4.view.ViewPager;
import android.support.v4.view.ViewPager.OnPa ...
package bwie.zhengaihua20161107;
import android.os.Bundle;
import android.os.Handler;
import android.os.Message;
import android.widget.ArrayAdapter;
import com.google.gson.Gson;
import java.util.ArrayList;
import java.util.List;
import baseactivity.BaseActivity;
import butterknife. ...
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<android.support.v7.widget.Recyc ...
出处:http://blog.csdn.net/guolin_blog/article/details/50727753 好像有挺久时间没更新博客了,最近我为了准备下一个系列的博客,也是花了很长的时间研读源码。很遗憾的是,下一个系列的博客我可能还要再过一段时间才能写出来,那么 ...
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="ma ...
package bwie.universaladapter;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.widget.ImageView;
import android.widget.ListView;
import android.widget.TextView;
import java.util.ArrayList;
import java.util.List;
public class MainActivity exten ...
import android.content.Context;
import android.content.res.TypedArray;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Paint;
import android.graphics.Rect;
import android.util.AttributeSet;
import android.util.TypedValue;
import android.view.View;
...
package andy.costomview;
import android.content.Context;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.LinearGradient;
import android.graphics.Paint;
import android.graphics.Path ...