# GSON
-keepattributes Signature
-keepattributes *Annotation*
-dontwarn sun.misc.**
-keep class com.google.gson.examples.android.model.** { <fields>; }
-keep class com.google.gson.examples.android.model.** { <fields>; }
-keep class * implements com.google.gson.TypeAdapterFactory
-keep class * implements com.google.gson.JsonSerializer
-keep class * implements com.google.gson.JsonDeserializer
-keepclassmembers,allowobfuscation class * {
    @com.google.gson.annotations.SerializedName <fields>;
}

# sdk
#-keep class cn.haorui.sdk.** { *; }


#---------------------------------默认保留区---------------------------------
-keep public class * extends android.app.Activity
-keep public class * extends android.app.Application
-keep public class * extends android.app.Service
-keep public class * extends android.content.BroadcastReceiver
-keep public class * extends android.content.ContentProvider
-keep public class * extends android.app.backup.BackupAgentHelper
-keep public class * extends android.preference.Preference
-keep public class * extends android.view.View
-keep public class com.android.vending.licensing.ILicensingService
-keep class android.support.** {*;}

# 保留所有的本地 native 方法不被混淆
-keepclasseswithmembernames class * {
    native <methods>;
}

# 保留在 Activity 中的方法参数是 view 的方法，
# 从而我们在 layout 里面编写 onClick 就不会被影响
-keepclassmembers class * extends android.app.Activity{
    public void *(android.view.View);
}
# 枚举类不能被混淆
-keepclassmembers enum * {
    public static **[] values();
    public static ** valueOf(java.lang.String);
}
# 保留自定义控件（继承自 View）不被混淆
-keep public class * extends android.view.View{
    *** get*();
    void set*(***);
    public <init>(android.content.Context);
    public <init>(android.content.Context, android.util.AttributeSet);
    public <init>(android.content.Context, android.util.AttributeSet, int);
}
-keepclasseswithmembers class * {
    public <init>(android.content.Context, android.util.AttributeSet);
    public <init>(android.content.Context, android.util.AttributeSet, int);
}
# 保留 Parcelable 序列化的类不被混淆
-keep class * implements android.os.Parcelable {
  *;
}
# 保留 Serializable 序列化的类不被混淆
-keep class * implements java.io.Serializable { *;}
-keepclassmembers class * implements java.io.Serializable {
    static final long serialVersionUID;
    private static final java.io.ObjectStreamField[] serialPersistentFields;
    private void writeObject(java.io.ObjectOutputStream);
    private void readObject(java.io.ObjectInputStream);
    java.lang.Object writeReplace();
    java.lang.Object readResolve();
}
# 对于 R（资源）下的所有类及其方法，都不能被混淆
-keep class **.R$* {
 *;
}
# 对于带有回调函数 onXXEvent 的，不能被混淆
-keepclassmembers class * {
    void *(**On*Event);
}

-keepclassmembers class * {
   public <init>(org.json.JSONObject);
}

-keepattributes *JavascriptInterface*

-keepclassmembers class fqcn.of.javascript.interface.for.Webview {
   public *;
}
-keepclassmembers class * extends android.webkit.WebViewClient {
    public void *(android.webkit.WebView, java.lang.String, android.graphics.Bitmap);
    public boolean *(android.webkit.WebView, java.lang.String);
}
-keepclassmembers class * extends android.webkit.WebViewClient {
    public void *(android.webkit.WebView, java.lang.String);
}

-keep class  cn.haorui.sdk.core.ad.** { *; }
-keep public class  cn.haorui.sdk.core.utils.** { *; }
-keep public class  cn.haorui.sdk.core.domain.**{ *; }
-keep public class  cn.haorui.sdk.core.loader.InteractionListener{ *; }
-keep public class  cn.haorui.sdk.core.loader.IAdLoadListener{ *; }
-keep public class  cn.haorui.sdk.core.loader.IAdLoader{ *; }
-keep public class  cn.haorui.sdk.core.loader.AdPlatformError{ *; }
-keep public class  cn.haorui.sdk.core.loader.ShareInfo{ *; }
-keep public class  cn.haorui.sdk.core.loader.ShareInteractionListener{ *; }
#-keep public class  cn.haorui.sdk.core.loader.**{ *; }
-keep public class  cn.haorui.sdk.core.view.**{ *; }
-keep public class  cn.haorui.sdk.core.AdSdk{ *; }
-keep public class  cn.haorui.sdk.core.HRConfig{ *; }

-keep public class cn.haorui.sdk.core.loader.concurrent.IOnAdStatusListener{ *; }
-keep public class cn.haorui.sdk.core.loader.concurrent.IConCurrentLoadListener{ *; }
-keep public class cn.haorui.sdk.core.loader.concurrent.ConCurrentManager{ *; }
-keep public class cn.haorui.sdk.core.domain**{ *; }
#-keep public class cn.haorui.sdk.core.loader.AdLoader$*{*;}
#-keep public class cn.haorui.sdk.core.loader.AdParallelLoader{ *; }
#-keep public class cn.haorui.sdk.platform.custom.**{ *; }
#不混淆AdConfig的内部类
-keep class cn.haorui.sdk.core.HRConfig$* {*;}
-keep class cn.haorui.sdk.adsail_ad.** { *; }
-keep class cn.haorui.sdk.platform.** { *; }
-keep class cn.haorui.sdk.activity.** { *; }
-keeppackagenames
-keep class com.tencent.mm.** { *; }

#-keep class cn.haorui.sdk.core.utils.ClickHandler{*;}
