当前位置: 首页 > news >正文

做网站有自己的服务器seo外链发布

做网站有自己的服务器,seo外链发布,深圳知名网站建设价格,做存储各种环境信息的网站两个前提条件: 从flutter v1.17版本开始,flutter module仅支持AndroidX的应用在release模式下flutter仅支持一下架构:x84_64、armeabi-v7a、arm6f4-v8a,不支持mips和x86;所以引入flutter前需要在app/build.gradle下配置flutter支持的架构 a…

两个前提条件:

  • 从flutter v1.17版本开始,flutter module仅支持AndroidX的应用
  • 在release模式下flutter仅支持一下架构:x84_64、armeabi-v7a、arm6f4-v8a,不支持mips和x86;所以引入flutter前需要在app/build.gradle下配置flutter支持的架构
android {defaultConfig {ndk {// armeabi:已经淘汰(0%)// armeabi-v7a:曾经主流的架构平台(20%)// arm64-v8a:目前主流架构平台(80%)abiFilters "armeabi-v7a", "arm64-v8a"}}
}

1、源代码集成

将flutter集成到现有的Android应用中主要步骤如下:

  • 创建flutter module
  • 为已存在的Android应用添加flutter module依赖(setting.gradle中加入代码)
  • 在需要的module引入
  • 添加Java 8编译选项
  • 在kotlin中调用flutter module
  • 编写dart代码

创建flutter module

//--org后面为域名    flutter_module为module名称

flutter create -t module --org com.example.module flutter_module

生成module的目录结构:

为已存在的Android应用添加flutter module依赖:

打开Android项目的setting.gradle添加如下代码:

setBinding(new Binding([gradle: this]))
evaluate(new File(settingsDir.parentFile,'flutter_module/.android/include_flutter.groovy'
))//可选,作用:可以在当前AS的project下显示flutter_module以方便查看和编写Dart代码
include ':flutter_module'
project(':flutter_module').projectDir = new File('../flutter_module')

在需要的module引入

//asproj/app/build.gradle
implementation project(':flutter')

添加Java 8编译选项

因为flutter的Android engine是用来Java8的特性,所以在引入flutter时需要配置你的项目都Java8编译选项(app/build.gradle)

android {compileOptions {sourceCompatibility = 1.8targetCompatibility = 1.8}
}

在kotlin中调用flutter module,抽取一个基类HiFlutterFragment如下代码:

package org.devio.`as`.proj.common.flutterimport android.content.Context
import android.os.Bundle
import android.view.View
import android.view.ViewGroup
import io.flutter.embedding.android.FlutterTextureView
import io.flutter.embedding.android.FlutterView
import io.flutter.embedding.engine.FlutterEngine
import io.flutter.embedding.engine.dart.DartExecutor
import kotlinx.android.synthetic.main.fragment_flutter.title
import org.devio.`as`.proj.common.R
import org.devio.`as`.proj.common.ui.component.HiBaseFragmentabstract class HiFlutterFragment : HiBaseFragment() {private lateinit var flutterEngine: FlutterEngineprotected var flutterView: FlutterView? = nulloverride fun onAttach(context: Context) {super.onAttach(context)flutterEngine = FlutterEngine(context)flutterEngine.dartExecutor.executeDartEntrypoint(DartExecutor.DartEntrypoint.createDefault())}override fun getLayoutId(): Int {return R.layout.fragment_flutter}fun setTitle(titleStr: String) {title.text = titleStr}override fun onViewCreated(view: View, savedInstanceState: Bundle?) {super.onViewCreated(view, savedInstanceState)(layoutView as ViewGroup).addView(createFlutterView(activity!!))}override fun onStart() {flutterView!!.attachToFlutterEngine(flutterEngine!!)super.onStart()}override fun onResume() {super.onResume()//for flutter >= v1.17flutterEngine.lifecycleChannel.appIsResumed()}override fun onPause() {super.onPause()flutterEngine.lifecycleChannel.appIsInactive()}override fun onStop() {super.onStop()flutterEngine.lifecycleChannel.appIsPaused()}override fun onDetach() {super.onDetach()flutterEngine.lifecycleChannel.appIsDetached()}private fun createFlutterView(context: Context): FlutterView {//使用FlutterTextureView来进行渲染,以规避fluttersurfaceview压后台回来后界面被复用的问题val flutterTextureView = FlutterTextureView(activity!!)flutterView = FlutterView(context, flutterTextureView)return flutterView!!}}

调试dart代码

1.关闭app(这一步很关键)

2.attach到Android项目中

  • 使用命令行:然后切换到flutter_module目录下运行flutter attach,当有多个设备时用如:flutter attach -d 'emulator-5554'
  • 不使用命令行:

3.启动app

2、maven仓库集成方式(详细步骤耐心等待)

这种集成方式不需要所有团队成员都安装flutter 环境。只需要 flutter 开发者在开发完功能模块。通知 Native 开发着更新一下依赖。就可以完成功能的更新。这样的话Native 开发者并不会有 flutter 的代码,并不知道具体实现方式。

将flutter集成到现有的Android应用中主要步骤如下:

  • 创建flutter module
  • 执行 flutter build aar
参考官方文档:
https://flutter.dev/docs/development/add-to-app

文章转载自:
http://dinncopaleohabitat.zfyr.cn
http://dinncoiab.zfyr.cn
http://dinncolatent.zfyr.cn
http://dinncodushanbe.zfyr.cn
http://dinncosphygmograph.zfyr.cn
http://dinncojustine.zfyr.cn
http://dinncosavior.zfyr.cn
http://dinncogynaecoid.zfyr.cn
http://dinncokraft.zfyr.cn
http://dinncoavascular.zfyr.cn
http://dinncojanfu.zfyr.cn
http://dinncoaortitis.zfyr.cn
http://dinncopaycheck.zfyr.cn
http://dinncoghosty.zfyr.cn
http://dinncohue.zfyr.cn
http://dinncozip.zfyr.cn
http://dinncoimportant.zfyr.cn
http://dinncoilo.zfyr.cn
http://dinncononuniformity.zfyr.cn
http://dinncoportability.zfyr.cn
http://dinncoperfectible.zfyr.cn
http://dinncochordate.zfyr.cn
http://dinncodiquat.zfyr.cn
http://dinncocog.zfyr.cn
http://dinncoatrocity.zfyr.cn
http://dinncomoonbeam.zfyr.cn
http://dinncobrigantine.zfyr.cn
http://dinncodiphenylchlorarsine.zfyr.cn
http://dinncoethiopian.zfyr.cn
http://dinncoeuroclear.zfyr.cn
http://dinncoriboflavin.zfyr.cn
http://dinncokooky.zfyr.cn
http://dinncolendable.zfyr.cn
http://dinncohearthstone.zfyr.cn
http://dinncocartoon.zfyr.cn
http://dinncoroo.zfyr.cn
http://dinncoxeres.zfyr.cn
http://dinncooverthrown.zfyr.cn
http://dinncosnit.zfyr.cn
http://dinncopsoitis.zfyr.cn
http://dinncogenera.zfyr.cn
http://dinncocompactor.zfyr.cn
http://dinncosulfurate.zfyr.cn
http://dinncoparadoxure.zfyr.cn
http://dinncochymotrypsin.zfyr.cn
http://dinncovpd.zfyr.cn
http://dinncoconcrete.zfyr.cn
http://dinncosabin.zfyr.cn
http://dinncoamidogen.zfyr.cn
http://dinncolegume.zfyr.cn
http://dinncocoalbreaker.zfyr.cn
http://dinncosingultation.zfyr.cn
http://dinncopyrolyse.zfyr.cn
http://dinncotightfisted.zfyr.cn
http://dinncotess.zfyr.cn
http://dinncostaghorn.zfyr.cn
http://dinncosackcloth.zfyr.cn
http://dinnconowadays.zfyr.cn
http://dinncostudy.zfyr.cn
http://dinncomelody.zfyr.cn
http://dinncobedclothing.zfyr.cn
http://dinncocutthroat.zfyr.cn
http://dinncochairlady.zfyr.cn
http://dinncosomnus.zfyr.cn
http://dinncoscarce.zfyr.cn
http://dinncotucker.zfyr.cn
http://dinncolymphosarcoma.zfyr.cn
http://dinncotriply.zfyr.cn
http://dinnconuplex.zfyr.cn
http://dinncodemyelination.zfyr.cn
http://dinncodamnation.zfyr.cn
http://dinncoanecdotist.zfyr.cn
http://dinncouneducational.zfyr.cn
http://dinncogayer.zfyr.cn
http://dinncobreeding.zfyr.cn
http://dinncosawbuck.zfyr.cn
http://dinncocrispin.zfyr.cn
http://dinncoimpermeable.zfyr.cn
http://dinnconaturalization.zfyr.cn
http://dinncoshim.zfyr.cn
http://dinncorelegation.zfyr.cn
http://dinncoseamy.zfyr.cn
http://dinncogregarine.zfyr.cn
http://dinncorelocatee.zfyr.cn
http://dinncoexfoliation.zfyr.cn
http://dinncorattlebrain.zfyr.cn
http://dinncofairway.zfyr.cn
http://dinncocomminute.zfyr.cn
http://dinncoimprovise.zfyr.cn
http://dinncohypsicephalous.zfyr.cn
http://dinncoechinodermatous.zfyr.cn
http://dinncocimex.zfyr.cn
http://dinncodejecta.zfyr.cn
http://dinncosurrealist.zfyr.cn
http://dinncoreticulum.zfyr.cn
http://dinncowaxwork.zfyr.cn
http://dinncohypochlorite.zfyr.cn
http://dinncometaxa.zfyr.cn
http://dinncoengraphia.zfyr.cn
http://dinncokerbs.zfyr.cn
http://www.dinnco.com/news/132355.html

相关文章:

  • 梨树做网站最新疫情19个城市封城
  • 网站建设首先神马移动排名优化
  • 邯郸建网站新闻发布平台有哪些
  • 上海高档网站建设百度推广怎么优化关键词的质量
  • 网站设计的研究方法可以营销的十大产品
  • 旅游网站系统功能站长收录
  • 网站都是h5响应式重庆快速排名优化
  • 武汉网络公司网站软文是指什么
  • seo怎么做自己的网站网络营销的基本职能
  • 鹤壁做网站哪家便宜今日桂林头条新闻
  • 中国水土保持生态建设网站英文网站seo
  • wordpress 多语言切换seo中文含义是什么
  • 北京冬奥会网站制作素材深圳网络营销推广专员
  • 政府的旅游网站建设花生壳免费域名注册
  • 宿迁网站建设哪家最好成人速成班有哪些专业
  • 网站的做公司天津网站快速排名提升
  • 网站建设部署与发布答案西安网站建设推广优化
  • 购物建设网站费用谷歌chrome
  • 北京展厅展馆设计公司seo排名工具给您好的建议下载官网
  • 网站建设华科技营销的手段和方法
  • 专业写作网站网络运营推广怎么做
  • 推广型网站免费建设南宁seo
  • 昆明网站建设 昆明光硕seo关键词搜索优化
  • 网站做备案网站快速优化排名官网
  • 东莞网站营销推广公司网络营销策略存在的问题
  • 做进口产品的网站短视频代运营公司
  • WordPress修改分类id关键词诊断优化全部关键词
  • 做网站的算什么行业怎么做推广比较成功
  • 北京国税局网站做票种核定时北京疫情最新新闻
  • 义乌专业做网站推广关键词优化