// Path: app/src/main/java/com/github/zzwwws/rxzhihudaily/common/BaseApplication.java
// public class BaseApplication extends Application {
// 
//     private static BaseApplication instance;
// 
//     public static BaseApplication get() {
//         return instance;
//     }
// 
//     @Override
//     public void onCreate() {
//         super.onCreate();
//         instance = (BaseApplication) getApplicationContext();
// 
//         if (AppConfig.DEBUG) {
//             StrictModeUtil.startStrictMode();
//         }
//         ScreenUtil.GetInfo(instance);
//     }
// }


import android.content.Context;
import android.content.res.Resources;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.BitmapFactory.Options;
import android.graphics.Rect;
import android.graphics.drawable.BitmapDrawable;
import android.graphics.drawable.Drawable;
import android.support.v4.util.LruCache;
import android.util.DisplayMetrics;
import android.util.Xml;
import com.github.zzwwws.rxzhihudaily.common.BaseApplication;
import org.xml.sax.Attributes;
import org.xml.sax.SAXException;
import org.xml.sax.helpers.DefaultHandler;
import java.io.IOException;
import java.io.InputStream;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.regex.Pattern;
package com.github.zzwwws.rxzhihudaily.common.util;






public class EmoUtil {
    private static final String ASSET = "emoticon";

    private static final String XML = "xml";

    // max cache size
    private static final int CACHE_MAX_SIZE = 1024;

	private static Pattern pattern;

	// default entries
	private static final List<Entry> defaultEntries = new ArrayList<Entry>();
    // entries for display
    private static final List<Entry> displayEntries = new ArrayList<Entry>();
	// text to entry
	private static final Map<String, Entry> text2entry = new HashMap<String, Entry>();
    // asset bitmap cache, key: asset path
    private static LruCache<String, Bitmap> drawableCache;

	static {
// Path: app/src/main/java/com/github/zzwwws/rxzhihudaily/common/BaseApplication.java
// public class BaseApplication extends Application {
// 
//     private static BaseApplication instance;
// 
//     public static BaseApplication get() {
//         return instance;
//     }
// 
//     @Override
//     public void onCreate() {
//         super.onCreate();
//         instance = (BaseApplication) getApplicationContext();
// 
//         if (AppConfig.DEBUG) {
//             StrictModeUtil.startStrictMode();
//         }
//         ScreenUtil.GetInfo(instance);
//     }
// }


// Path: app/src/main/java/com/github/zzwwws/rxzhihudaily/common/util/EmoUtil.java
import android.content.Context;
import android.content.res.Resources;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.BitmapFactory.Options;
import android.graphics.Rect;
import android.graphics.drawable.BitmapDrawable;
import android.graphics.drawable.Drawable;
import android.support.v4.util.LruCache;
import android.util.DisplayMetrics;
import android.util.Xml;
import com.github.zzwwws.rxzhihudaily.common.BaseApplication;
import org.xml.sax.Attributes;
import org.xml.sax.SAXException;
import org.xml.sax.helpers.DefaultHandler;
import java.io.IOException;
import java.io.InputStream;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.regex.Pattern;

package com.github.zzwwws.rxzhihudaily.common.util;






public class EmoUtil {
    private static final String ASSET = "emoticon";

    private static final String XML = "xml";

    // max cache size
    private static final int CACHE_MAX_SIZE = 1024;

	private static Pattern pattern;

	// default entries
	private static final List<Entry> defaultEntries = new ArrayList<Entry>();
    // entries for display
    private static final List<Entry> displayEntries = new ArrayList<Entry>();
	// text to entry
	private static final Map<String, Entry> text2entry = new HashMap<String, Entry>();
    // asset bitmap cache, key: asset path
    private static LruCache<String, Bitmap> drawableCache;

	static {
		Context context = BaseApplication.get();