草庐IT

dynamic-sizing

全部标签

json - '_InternalLinkedHashMap<String, dynamic >' is not a subtype of type ' Iterable<dynamic>' in type cast

我正在尝试同时使用built_value和json_serializable来解析从服务器到模型类的json响应。以下是依赖项:built_collection:^4.0.0built_value:^6.1.4dev_dependencies:build_runner:^1.0.0built_value_generator:^6.1.4json_serializable:^1.4.0下面是我写的代码abstractclassUserDataimplementsBuilt{Stringgetuser_first_name;Stringgetuser_last_name;Stringget

json - '_InternalLinkedHashMap<String, dynamic >' is not a subtype of type ' Iterable<dynamic>' in type cast

我正在尝试同时使用built_value和json_serializable来解析从服务器到模型类的json响应。以下是依赖项:built_collection:^4.0.0built_value:^6.1.4dev_dependencies:build_runner:^1.0.0built_value_generator:^6.1.4json_serializable:^1.4.0下面是我写的代码abstractclassUserDataimplementsBuilt{Stringgetuser_first_name;Stringgetuser_last_name;Stringget

android - 更改安卓 :configChanges dynamically

我正在创建一个杂志应用程序,它使用ViewPager并在不同的WebView上滚动。大多数页面是纵向的,但也有一些页面可以横向显示。为了处理这个问题,我在包含ViewPager的Activity中使用了两种方法:publicvoidallowOrientationChanges(){setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_SENSOR);}publicvoidenforcePortrait(){setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_PORTR

dart - Flutter MethodChannel嵌套值: 'List<dynamic>' is not a subtype of type 'FutureOr<List<Map<String, double>>>'

我正在编写一个Flutter插件,它从平台特定端发送一个map列表(List>)。在平台特定方面,我使用默认消息编解码器发送这些对象。//(example:Androidside)List>out=newArrayList();...fillthemap...result.success(out);我在Dart端收到的这些值如下:staticFuture>>getListOfMaps()async{vartraces=await_channel.invokeMethod('getListOfMaps');print(traces);//worksreturntraces;}打印值会给出

dart - Flutter MethodChannel嵌套值: 'List<dynamic>' is not a subtype of type 'FutureOr<List<Map<String, double>>>'

我正在编写一个Flutter插件,它从平台特定端发送一个map列表(List>)。在平台特定方面,我使用默认消息编解码器发送这些对象。//(example:Androidside)List>out=newArrayList();...fillthemap...result.success(out);我在Dart端收到的这些值如下:staticFuture>>getListOfMaps()async{vartraces=await_channel.invokeMethod('getListOfMaps');print(traces);//worksreturntraces;}打印值会给出

android - "Error using newLatLngBounds(LatLngBounds, int): Map size can' t 为零...."在 Android 上使用 react-native-maps

我得到一个错误:“使用newLatLngBounds(LatLngBounds,int)时出错:map大小不能为零。mapView很可能尚未发生布局。等待布局发生或使用newLatLngBounds(LatLngBounds,int,int,int)允许您指定map的尺寸​​”。但我为getCurrentPosition设置了一个警报,并且我正在从getCurrentPosition()接收坐标。importReact,{Component}from'react';import{View,Dimensions}from'react-native';importMapViewfrom'r

安卓 SQLite : Index -1 requested with a size of 1

我的应用程序需要一个数据库,但由于以下错误,它一直强制关闭。它在我的一个Activity中有效,但在另一个Activity中无效数据库处理程序:publicclassDBGestion{privatestaticfinalintVERSION_BDD=1;privatestaticfinalStringNOM_BDD="cityquest.db";privatestaticfinalStringTABLE_QUEST="table_quest";privatestaticfinalStringCOL_ID="ID";privatestaticfinalintNUM_COL_ID=0;p

flutter - 类型文件不是 'imageprovider dynamic ' 类型的子类型

当我从图像选择器中选择图像时,我收到此错误类型文件不是“imageproviderdynamic”类型的子类型即使出现相同的错误,我也尝试使用堆栈class_ProfileStateextendsState{@overrideWidgetbuild(BuildContextcontext){returnScaffold(appBar:AppBar(automaticallyImplyLeading:true,title:Text('Profile'),centerTitle:true,elevation:10.0,),body:Container(decoration:BoxDecor

flutter - 类型文件不是 'imageprovider dynamic ' 类型的子类型

当我从图像选择器中选择图像时,我收到此错误类型文件不是“imageproviderdynamic”类型的子类型即使出现相同的错误,我也尝试使用堆栈class_ProfileStateextendsState{@overrideWidgetbuild(BuildContextcontext){returnScaffold(appBar:AppBar(automaticallyImplyLeading:true,title:Text('Profile'),centerTitle:true,elevation:10.0,),body:Container(decoration:BoxDecor

java - 收到错误 "java.lang.StackOverflowError: stack size 1036KB"和 OutOfMemory

我正在使用一个完全处理图像和视频的应用程序。我将设备的所有图像和视频存储到应用程序数据库中,并且此任务在后台服务中执行。在这个过程中,我使用getFacesFromBitmap(mBitmap)检查检测图像中的人脸。问题是有时我收到错误java.lang.StackOverflowError:stacksize1036KB有时我收到OOM错误。那么有什么好的方法可以解决这个问题吗? 最佳答案 StackOverflowError通常是由堆栈大小过大(太多的方法相互调用)引起的有时它是由递归调用自身的方法引起的(想象一个永远不断调用自