Comments (13)
以下是相关代码
abstract class LoginIMvpView extends IMvpView{
LoginProvider get provider;
}
class LoginPresenter extends BasePagePresenter{
////.....
}
from flutter_deer.
LoginIView 和 LoginIMvpView 是什么关系
from flutter_deer.
LoginIView 和 LoginIMvpView 是什么关系
我现在把LoginIView名字改为LoginIMvpView了,上面贴的代码是在日志之后修改的,忽略LoginIView,现在只有LoginIMvpView类了,报错依然如下:
Another exception was thrown: type '_LoginState' is not a subtype of type 'LoginIMvpView' of 'value'
from flutter_deer.
看下面这个:
class LoginPresenter extends BasePagePresenter{
////.....
}
from flutter_deer.
@simplezhli 我已经发现是如下这个赋值的问题,但是不知道为啥两边类型不一致?
from flutter_deer.
from flutter_deer.
class LoginPresenter extends BasePagePresenter<LoginIMvpView> {
}
from flutter_deer.
class LoginPresenter extends BasePagePresenter<LoginIMvpView> { }
加上了,还是报错:
from flutter_deer.
而且这边看错误日志打印了两次,和这个有关系吗
from flutter_deer.
我断点试了下,_state is LoginIMvpView返回的是true
from flutter_deer.
而且这边看错误日志打印了两次,和这个有关系吗
initState里面有什么操作吗
from flutter_deer.
initState
这边代码没动
from flutter_deer.
重新按照你的demo写法,拷贝修改后运行正常了,怀疑是导包的问题,因为项目里有与之同名的一些dart类,感谢回复,我先把issues关了。
from flutter_deer.
Related Issues (20)
- 使用了dio的封装库,closeProgress方法执行了 ,但是加载视图不消失。 HOT 16
- FAILURE: Build failed with an exception HOT 7
- 最新代码clone后运行flutter pub get失败,提示Generating synthetic localizations package failed HOT 11
- 项目刚导入进行pub get报错。 HOT 2
- TextField加上getVCode在Container不居中
- 缺少 import 'package:flutter_deer/res/resources.dart';文件,爆红
- 安卓apk无法下载 HOT 5
- 5月22日刚拉代码 一直卡在 Running Gradle task 'assembleDebug'... HOT 11
- 纯新手,想问下'package:flutter_deer/widgets/my_app_bar.dart'里的flutter_deer是个包吗 HOT 4
- fluro的使用 HOT 2
- Failed to connect to the VM observatory service at: ws://127.0.0.1:64266/PbgpFj8Gfhg=/ws HOT 3
- android运行报错,望指点一二 HOT 6
- 为什么不用riverpod HOT 4
- 120hz刷新率问题请教 HOT 5
- flutter 3.16 不兼容 HOT 2
- 如何取消重新登陆限制
- build时报错 HOT 3
- 请问一下 HOT 10
- HttpException: Connection closed before response was received HOT 9
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from flutter_deer.