Giter Site home page Giter Site logo

jessyancoding / mvparms Goto Github PK

View Code? Open in Web Editor NEW
10.3K 340.0 2.4K 5.82 MB

⚔️ A common architecture for Android applications developing based on MVP, integrates many open source projects, to make your developing quicker and easier (一个整合了大量主流开源项目高度可配置化的 Android MVP 快速集成框架).

License: Apache License 2.0

Java 100.00%
mvp rxjava retrofit2 dagger2 architectural wiki-documentation android android-library android-application android-architecture

mvparms's Introduction

Hi

Life is a fucking movie. 😈 😈 😈 😈 😈 😈

人生如戏。

mvparms's People

Contributors

chinazeng avatar code4a avatar gitlqr avatar goooler avatar jessyancoding avatar kaixinhupo avatar lianhuo avatar linsneider avatar miaomiaodashi avatar passin95 avatar rockyqu avatar shisheng-1 avatar sum41forever avatar walkthehorizon avatar xiaobailong24 avatar xwc95 avatar yuruiyin avatar zhangqian666 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

mvparms's Issues

有多个BaseUrl 怎么处理

当有多个 baseUrl 时,怎么创建retrofit 好些呢? 看了架构源码,感觉不好处理。
还有个问题,没理解 Presenter 创建时,它依赖的对象是怎么创建的?希望指教下

Presenter重用问题

我现在有一个MainFragment, 里面有很多操作, 有登录, 获取消息。而登录和获取消息分别对应两个Persenter, 登录Persenter里有三个接口, 获取消息Presenter里面有两个接口。

MainFragMent用到了登录Presenter里的一个接口, 用到了获取消息Presenter里面的一个接口。

我现在的做法是把消息Presenter里的那个接口写到了登录Presenter里面, 这样MainFragment就可以使用了,感觉不好,以后接口多了的话,不好玩,

第二种方法就是和上面一样,登录的写入消息Persenter
第三种就是新建一个Presenter, 包含公用的两个接口

感觉都不好啊

请问如何优雅的处理。

又有新问题,ButterKnife 和 Dagger2 冲突,导致空指针

请问您遇到过吗?我测试了一上午了,,

只有一个TextView

@BindView(R.id.tv_hello)
Textview mTextView;

然后在 initData() 方法里设置内容 mTextView.setText("你好");`

就报 mTextView 空指针了,不用黄油刀,findViewbyId 正常。

也有说两者冲突,JakeWharton/butterknife#803

然而并。。没解决。。。

我的工程和你的项目对比了,都一样,,我的不行,你的完美运行,好尴尬,,,求破啊

源码分析有个疑问

BaseApplication中有如下方法:

`
public LinkedList mActivityList;

/**
* 返回一个存储所有存在的activity的列表
*
* @return
*/
public LinkedList getActivityList() {
if (mActivityList == null) {
mActivityList = new LinkedList();
}
return mActivityList;
}
`

在BaseActivity中有:
//如果intent包含了此字段,并且为true说明不加入到list // 默认为false,如果不需要管理(比如不需要在退出所有activity(killAll)时,退出此activity就在intent加此字段为true) boolean isNotAdd = getIntent().getBooleanExtra(IS_NOT_ADD_ACTIVITY_LIST, false);

个人觉得要实现退出所有activity保留单个activity,做法是保存activity的实例这个做法可能会导致内存泄露,应该有更好的办法解决,希望楼主提供。

dagger2支持的最低版本

请问一下dagger2支持最低系统版本是哪个版本呢?百度都没找到呢。还有MVPArms支持api是15+的,我能不能换掉涉及到15+的第三方库呢,因为我想兼容到14+,

recylerview实现多种type

作者封装了defaultadapter,但是这可以用于item布局相同的列表,在item 布局不同的列表就没法在用defaultadapter,而现在的项目中很多都是多type的recylerview,希望作者考虑一下

关于Contract里面的 Model,和View,

Contract 里面为什么只有View和Model的接口,google 官方架构是View和Presenter.
是否应该考虑Contract内包含了 View,Model,Presenter3个接口的定义呢?

貌似少了些类

BaseApplication类下引用这个DaggerBaseComponent报错;WEApplication类下引用DaggerAppComponent报错。

gradlew assembleRelease编译不过,请教

Initializing...
Warning: AutoContentFrameLayout: can't find referenced method 'android.content.Context getContext()' in program class AutoContentFrameLayout
Warning: AutoContentFrameLayout: can't find referenced method 'boolean isInEditMode()' in program class AutoContentFrameLayout
Warning: okio.DeflaterSink: can't find referenced class org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement
Warning: okio.Okio: can't find referenced class java.nio.file.Files
Warning: okio.Okio: can't find referenced class java.nio.file.Files
Warning: okio.Okio: can't find referenced class java.nio.file.Files
Warning: okio.Okio: can't find referenced class java.nio.file.Path
Warning: okio.Okio: can't find referenced class java.nio.file.OpenOption
Warning: okio.Okio: can't find referenced class java.nio.file.Path
Warning: okio.Okio: can't find referenced class java.nio.file.OpenOption
Warning: okio.Okio: can't find referenced class org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement
Warning: okio.Okio: can't find referenced class java.nio.file.Path
Warning: okio.Okio: can't find referenced class java.nio.file.OpenOption
Warning: okio.Okio: can't find referenced class java.nio.file.Path
Warning: okio.Okio: can't find referenced class java.nio.file.OpenOption
Warning: okio.Okio: can't find referenced class org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement
Warning: retrofit2.Platform$Java8: can't find referenced class java.lang.invoke.MethodHandles$Lookup
Warning: retrofit2.Platform$Java8: can't find referenced class java.lang.invoke.MethodHandles$Lookup
Warning: retrofit2.Platform$Java8: can't find referenced class java.lang.invoke.MethodHandle
Warning: retrofit2.Platform$Java8: can't find referenced class java.lang.invoke.MethodHandle
Warning: retrofit2.Platform$Java8: can't find referenced class java.lang.invoke.MethodHandles
Warning: retrofit2.Platform$Java8: can't find referenced class java.lang.invoke.MethodHandle
Warning: retrofit2.Platform$Java8: can't find referenced class java.lang.invoke.MethodHandles$Lookup
Warning: retrofit2.Platform$Java8: can't find referenced class org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement
Warning: rx.internal.util.unsafe.BaseLinkedQueueConsumerNodeRef: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.BaseLinkedQueueConsumerNodeRef: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.BaseLinkedQueueProducerNodeRef: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.BaseLinkedQueueProducerNodeRef: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.ConcurrentCircularArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.ConcurrentCircularArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.ConcurrentCircularArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.ConcurrentCircularArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.ConcurrentCircularArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.ConcurrentCircularArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.ConcurrentCircularArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.ConcurrentSequencedCircularArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.ConcurrentSequencedCircularArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.ConcurrentSequencedCircularArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.ConcurrentSequencedCircularArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.ConcurrentSequencedCircularArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.MpmcArrayQueueConsumerField: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.MpmcArrayQueueConsumerField: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.MpmcArrayQueueProducerField: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.MpmcArrayQueueProducerField: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.MpscLinkedQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.MpscLinkedQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpmcArrayQueueConsumerField: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpmcArrayQueueConsumerField: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpmcArrayQueueProducerField: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpmcArrayQueueProducerField: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpscArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpscArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpscArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpscUnboundedArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpscUnboundedArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpscUnboundedArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpscUnboundedArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpscUnboundedArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpscUnboundedArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpscUnboundedArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.SpscUnboundedArrayQueue: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.UnsafeAccess: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.UnsafeAccess: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.UnsafeAccess: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.UnsafeAccess: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.UnsafeAccess: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.UnsafeAccess: can't find referenced class sun.misc.Unsafe
Warning: rx.internal.util.unsafe.UnsafeAccess: can't find referenced class sun.misc.Unsafe
Note: com.app.mobile.base.utils.DeviceUtils: can't find dynamically referenced class com.android.internal.R$dimen
Note: com.app.mobile.base.utils.DeviceUtils: can't find dynamically referenced class com.android.internal.R$dimen
Note: com.google.gson.internal.UnsafeAllocator: can't find dynamically referenced class sun.misc.Unsafe
Note: okhttp3.internal.platform.AndroidPlatform: can't find dynamically referenced class com.android.org.conscrypt.SSLParametersImpl
Note: okhttp3.internal.platform.AndroidPlatform: can't find dynamically referenced class org.apache.harmony.xnet.provider.jsse.SSLParametersImpl
Note: okhttp3.internal.platform.Platform: can't find dynamically referenced class sun.security.ssl.SSLContextImpl
Note: retrofit2.Platform: can't find dynamically referenced class org.robovm.apple.foundation.NSObject
Note: retrofit2.Platform$IOS$MainThreadExecutor: can't find dynamically referenced class org.robovm.apple.foundation.NSOperationQueue
Note: com.app.mobile.base.utils.DeviceUtils accesses a field 'status_bar_height' dynamically
Note: com.app.mobile.base.utils.DeviceUtils accesses a field 'status_bar_height' dynamically
Note: com.google.gson.internal.UnsafeAllocator accesses a declared field 'theUnsafe' dynamically
Note: com.zhy.autolayout.attr.MinHeightAttr accesses a field 'mMinHeight' dynamically
Note: com.zhy.autolayout.attr.MinWidthAttr accesses a field 'mMinWidth' dynamically
Note: rx.internal.util.PlatformDependent accesses a field 'SDK_INT' dynamically
Maybe this is library field 'android.os.Build$VERSION { int SDK_INT; }'
Note: there were 8 unresolved dynamic references to classes or interfaces.
You should check if you need to specify additional program jars.
(http://proguard.sourceforge.net/manual/troubleshooting.html#dynamicalclass)
Note: there were 6 accesses to class members by means of introspection.
You should consider explicitly keeping the mentioned class members
(using '-keep' or '-keepclassmembers').
(http://proguard.sourceforge.net/manual/troubleshooting.html#dynamicalclassmember)
Warning: there were 66 unresolved references to classes or interfaces.
You may need to add missing library jars or update their versions.
If your code works fine without the missing classes, you can suppress
the warnings with '-dontwarn' options.
(http://proguard.sourceforge.net/manual/troubleshooting.html#unresolvedclass)
Warning: there were 2 unresolved references to program class members.
Your input classes appear to be inconsistent.
You may need to recompile the code.
(http://proguard.sourceforge.net/manual/troubleshooting.html#unresolvedprogramclassmember)
Warning: Exception while processing task java.io.IOException: Please correct the above warnings first.
:app:transformClassesAndResourcesWithProguardForRelease FAILED

Gson解析

您好,
关于json解析,请教一个问题,形如以下格式的json应该怎么解析?元素的key是变化的。万分感谢!

{
    "127": {
        "OSID": "127",
        "name": "CentOS 6 x64",
        "arch": "x64",
        "family": "centos",
        "windows": false
    },
    "148": {
        "OSID": "148",
        "name": "Ubuntu 12.04 i386",
        "arch": "i386",
        "family": "ubuntu",
        "windows": false
    }
}

DaggerBaseComponent编译不过

是这样的,本来是直接compile 'me.jessyan:arms:1.2.4',功能什么的都可以用。功能非常强大。在使用过程中,希望将每个activity的状态栏设置为透明的。就需要修改BaseActivty中的布局和内容。所以就是直接引用的compile project(':arms')。这样引用之后,编译DaggerBaseComponent通不过。Error:(42, 9) 错误: 找不到符号
符号: 变量 DaggerBaseComponent
位置: 类 BaseApplication

ButterKnife 问题

在 Base 类里

mUnbind = ButterKnife.bind(this);

后 为什么在 子 Activity 中

@BindView(R.id.activity_main)
FrameLayout activityMain;

activityMain 会为空,很奇怪!会是什么问题

AdapterViewPager中为什么这么写?

请教一个问题AdapterViewPager中为什么这么写呢,切换不做任何保存立即销毁?我们一般都不重写这些方法。
@OverRide
public Parcelable saveState() {
return null;
}

@Override
public Object instantiateItem(ViewGroup container, int position) {
    Fragment f = (Fragment) super.instantiateItem(container, position);
    View view = f.getView();
    if (view != null)
        container.addView(view);
    return f;
}

@Override
public void destroyItem(ViewGroup container, int position, Object object) {
    View view = list.get(position).getView();
    if (view != null)
        container.removeView(view);
}

我用fragment请求网络会报错 ,请问怎么解决

AndroidRuntime: FATAL EXCEPTION: main
Process: com.niule.hdd, PID: 2129
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.niule.hdd/com.niule.hdd.MainActivity}: java.lang.ClassCastException: com.niule.hdd.mvp.ui.fragment.HomeOneFragment cannot be cast to com.jess.arms.base.BaseActivity
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2219)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2269)
at android.app.ActivityThread.access$800(ActivityThread.java:135)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5045)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.ClassCastException: com.niule.hdd.mvp.ui.fragment.HomeOneFragment cannot be cast to com.jess.arms.base.BaseActivity
at com.niule.hdd.mvp.presenter.HomeOnePresenter.getBannerList(HomeOnePresenter.java:65)
at com.niule.hdd.mvp.ui.fragment.HomeOneFragment.initData(HomeOneFragment.java:97)
at com.jess.arms.base.BaseFragment.onActivityCreated(BaseFragment.java:46)
at com.niule.hdd.mvp.ui.fragment.HomeOneFragment.onActivityCreated(HomeOneFragment.java:102)
at android.support.v4.app.Fragment.performActivityCreated(Fragment.java:2096)
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1138)
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1295)
at android.support.v4.app.BackStackRecord.run(BackStackRecord.java:801)
at android.support.v4.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1682)
at android.support.v4.app.FragmentController.execPendingActions(FragmentController.java:388)
at android.support.v4.app.FragmentActivity.onStart(FragmentActivity.java:607)
at android.support.v7.app.AppCompatActivity.onStart(AppCompatActivity.java:181)
at com.trello.rxlifecycle.components.support.RxAppCompatActivity.onStart(RxAppCompatActivity.java:50)
at android.app.Instrumentation.callActivityOnStart(Instrumentation.java:1188)
at android.app.Activity.performStart(Activity.java:5241)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2179)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2269) 
at android.app.ActivityThread.access$800(ActivityThread.java:135) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:136) 
at android.app.ActivityThread.main(ActivityThread.java:5045) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595) 
at dalvik.system.NativeStart.main(Native Method) 

源码

   public void getBannerList() {

    //请求外部存储权限用于适配android6.0的权限管理机制
    PermissionUtil.externalStorage(new PermissionUtil.RequestPermission() {
        @Override
        public void onRequestPermissionSuccess() {
            //request permission success, do something.
        }
    }, mRxPermissions, mRootView, mErrorHandler);



    mModel.getBannerList()
            .subscribeOn(Schedulers.io())
            .retryWhen(new RetryWithDelay(3, 2))//遇到错误时重试,第一个参数为重试几次,第二个参数为重试的间隔
            .doOnSubscribe(new Action0() {
                @Override
                public void call() {
                        mRootView.showLoading();
                }
            }).subscribeOn(AndroidSchedulers.mainThread())
            .observeOn(AndroidSchedulers.mainThread())
            .doAfterTerminate(new Action0() {//**这里是引发错误的地方**
                @Override
                public void call() {
                        mRootView.hideLoading();//隐藏上拉刷新的进度条
                }
            })
            .compose(((BaseActivity) mRootView).<BaseObject>bindToLifecycle())//使用RXlifecycle,使subscription和activity一起销毁
            .subscribe(new ErrorHandleSubscriber<BaseObject>(mErrorHandler) {
                @Override
                public void onNext(BaseObject baseObject) {
                    if(baseObject.isSuccess()){
                        Log.d("HomeOnePresenter", baseObject.toString());
                    }else {
                        mRootView.showMessage(baseObject.getMessage().toString());
                    }
                }
            });
}

BasePresenter<M, V extends IBaseView>, 当没有V时如何处理?

有这样一个契约, 获取服务器时间,不需要View

public interface TimeContract {
    //Model层定义接口,外部只需关心model返回的数据,无需关心内部细节,及是否使用缓存
    interface Model {
        Observable<SvrTime> getServerTime();
    }
}

当建立 TimePresenter时,继承BasePresenter没有View,如何是好?

我的处理:

  1. 加个空View
public interface TimeContract {
    interface View extends IBaseView {
    }
    //Model层定义接口,外部只需关心model返回的数据,无需关心内部细节,及是否使用缓存
    interface Model {
        Observable<SvrTime> getServerTime();
    }
}
  1. 新建一个BaseMPresenter, 然后TimePresenter继承BaseMPresenter
BasePresenter<M> 

可以看到,方法1多出无用的View, 方法2多了基类Presenter, 我还没测试方法2,请问还有没更好的方法

Retrofit 拦截器有数据,但是 response 返回 null

又踩了个坑,,

W/RequestIntercept.java: [ (RequestIntercept.java:96)#Intercept ] {
                             "GetSvrTimeResult": "20161122090413"
                         }
W/UserModel.java: [ (UserModel.java:37)#OnResponse ] 服务器时间: null

如上,拦截器收到服务器返回的json数据:

{
     "GetSvrTimeResult": "20161122090413"
}

但是,OnResponse 或Rxjava处理的 onNext 都返回 null, 是什么情况呢?

Rxjava升级了,框架要不要跟着升级

Error:Execution failed for task ':app:transformResourcesWithMergeJavaResForDebug'.

com.android.build.api.transform.TransformException: com.android.builder.packaging.DuplicateFileException: Duplicate files copied in APK META-INF/rxjava.properties
File1: C:\Users\Administrator.gradle\caches\modules-2\files-2.1\io.reactivex.rxjava2\rxjava\2.0.7\21734c0092a5d3c3ec99510e50c1ff76bdf0c65a\rxjava-2.0.7.jar
File2: C:\Users\Administrator.gradle\caches\modules-2\files-2.1\io.reactivex\rxjava\1.2.7\138872ff3173fb7bee8b1d6303d6edb57d76599\rxjava-1.2.7.jar

其它依赖库中用的最新版本的Rxjava,项目运行报错了

最新的项目更新了,包的分类

大神,您最新的项目更新了,包的分类,为什么model包里还要有aPi和entity包,问什么不和model分开来处于同一级上。
还有一个问题请教,您说过,写新项目,最好直接在开源项目里写,那您的项目更新了,像这次归类到common里去,那我不是要原来项目全部重新复制、粘贴,复制、粘贴了吗?您有什么方法可以减少这种功夫消耗?

English doc

Awesome project but could be great with an english wiki ^^

EventBus怎么用?

楼主你的arms已经引入我们项目中,但是我一直有一个疑问,就是EventBus怎么用?,它的应用场景是什么?可否解答一下?

帮助:关于文件缺失

你好作者:
我需要你的帮助,我在克隆MVPArms之后发现了一个文件的缺失,但是我不知道是怎么回事,希望能得到帮助,如下是我截的图↓
1
2
3
万分感谢

少一个类

import com.jess.arms.di.component.DaggerBaseComponent

DaggerBaseComponent缺少

Caused by: android.view.InflateException: Binary XML file line #24: Error inflating class LinearLayout 异常

MainActivity:

 public class MainActivity extends BaseActivity {
    @BindView(R.id.tv_hello)
    TextView mTextView;

    @Override
    protected void ComponentInject() {

    }

    @Override
    protected View initView() {
        return LayoutInflater.from(this).inflate(R.layout.activity_main, null, false);
    }

    @Override
    protected void initData() {

    }

}

出现异常:

Caused by: android.view.InflateException: Binary XML file line #24: Error inflating class LinearLayout
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:713)
at android.view.LayoutInflater.inflate(LayoutInflater.java:469)
at android.view.LayoutInflater.inflate(LayoutInflater.java:397)
at android.view.LayoutInflater.inflate(LayoutInflater.java:353)
at com.android.internal.policy.impl.PhoneWindow.generateLayout(PhoneWindow.java:3022)
at com.android.internal.policy.impl.PhoneWindow.installDecor(PhoneWindow.java:3085)
at com.android.internal.policy.impl.PhoneWindow.getDecorView(PhoneWindow.java:1678)
at butterknife.ButterKnife.bind(ButterKnife.java:123)
at com.inst.instcallcar.base.BaseActivity.onCreate(BaseActivity.java:91)
at android.app.Activity.performCreate(Activity.java:5231)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2159)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2245) 
at android.app.ActivityThread.access$800(ActivityThread.java:135) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:136) 
at android.app.ActivityThread.main(ActivityThread.java:5017) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595) 
at dalvik.system.NativeStart.main(Native Method) 
Caused by: java.lang.NullPointerException
at com.zhy.autolayout.config.AutoLayoutConifg.getMetaData(AutoLayoutConifg.java:98)
at com.zhy.autolayout.config.AutoLayoutConifg.init(AutoLayoutConifg.java:80)
at com.zhy.autolayout.utils.AutoLayoutHelper.initAutoLayoutConfig(AutoLayoutHelper.java:111)
at com.zhy.autolayout.utils.AutoLayoutHelper.(AutoLayoutHelper.java:103)
at com.zhy.autolayout.AutoLinearLayout.(AutoLinearLayout.java:18)
at com.inst.instcallcar.base.BaseActivity.onCreateView(BaseActivity.java:50)
at android.app.Activity.onCreateView(Activity.java:4744)
at android.support.v4.app.BaseFragmentActivityHoneycomb.onCreateView(BaseFragmentActivityHoneycomb.java:36)
at android.support.v4.app.FragmentActivity.onCreateView(FragmentActivity.java:77)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:689)
at android.view.LayoutInflater.inflate(LayoutInflater.java:469) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:397) 
at android.view.LayoutInflater.inflate(LayoutInflater.java:353) 
at com.android.internal.policy.impl.PhoneWindow.generateLayout(PhoneWindow.java:3022) 
at com.android.internal.policy.impl.PhoneWindow.installDecor(PhoneWindow.java:3085) 
at com.android.internal.policy.impl.PhoneWindow.getDecorView(PhoneWindow.java:1678) 
at butterknife.ButterKnife.bind(ButterKnife.java:123) 
at com.inst.instcallcar.base.BaseActivity.onCreate(BaseActivity.java:91) 
at android.app.Activity.performCreate(Activity.java:5231) 
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087) 
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2159) 
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2245) 
at android.app.ActivityThread.access$800(ActivityThread.java:135) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196) 
at android.os.Handler.dispatchMessage(Handler.java:102) 
at android.os.Looper.loop(Looper.java:136) 
at android.app.ActivityThread.main(ActivityThread.java:5017) 
at java.lang.reflect.Method.invokeNative(Native Method) 
at java.lang.reflect.Method.invoke(Method.java:515) 
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595) 
at dalvik.system.NativeStart.main(Native Method) 

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.