Can i call platform channel from another app in flutter? - java

I am developing an app in flutter and I want to use an SDK which isn't available for flutter and they have a sample project which is written in java (android native) and I want to integrate that app to my current flutter app, is that possible to be done with platform channels?
My experience in the android native is very weak so I almost can pick up with that project.
Thanks in advance,

Yes, you can. It's your own app though, not another one. And it's not necessary, but Android Studio will help you.
You have to modify the /android project of your Flutter project. You need to implement the SDK in question, and copy/paste/refactor the relevant sample code. You can then expose this code to the Flutter side via a method channel. To learn how, read this doc.
Important : Hot Restart will not update native code. You have to recompile everytime you want to apply native code changes.

Related

How Add Flutter To Existing Or New Android App

Suppose I have a large existing native android application written in java. And now I have decided to make this application cross-platform using flutter technology. I know that I can implement flutter and rewrite the project on this technology in parts, but can I, for example, make a cross-platform activity on flutter and put native java code inside it
there isn't anything to convert and android native app to flutter but if you want your existing android application cross-platform you can use kotlin to make it hybrid https://kotlinlang.org/lp/mobile/

Is it possible to use Flutter to make Android app that implemented Accessibility API?

Have anyone had the experience in using Flutter to make Android app that utilize the Android accessibility API?
Is this possible?
Yes it's possible of course since it's possible with native android you can use native channels for this
I have already built a plugin for interacting with accessibility service in android and he does the job you can read contents from the screen outside with it this is the plugin flutter_accessibility_service just check the example and instruction from the use

What is the right way to add Java code to a Cordova Android app?

I am working on an Cordova Android app. As part of the app, I wrote some Java classes to create a service using WorkManager to poll our server and send a notification to the client on certain events.
Right now the code is invoked through MainActivity.java, where I create the worker, and all of the classes sit in the Java folder under the Android Platform directory. My understanding is that this isn't ideal since my code will get dropped every time we want to reset the platform.
What is the right way to add this code to a project and is there a tutorial that I can follow? Should it all be a plugin?
Thank you in advance.
You should definitely refactor your code into a plugin. Check out the doc here
You can make your plugin for Android only as well.
I would recommend too, to clone a very simple plugin and check out the code.

How to make an Android app without using Android Studio?

I downloaded the Android studio and installed it. When I launched it, it's all "graphical". My screen reader is reading nothing on it.
I'd prefer if I could use my Notepad app, but the "stand alone" tutorials are too tiresome, and not many tutorials on the web have instructions making apps using Notepad. I wanted to know if there is an alternate IDE, or another way to code Android apps?
The Java IDE Eclipse is also not very compatible with my screen reader. I use JAWS screen reader by Freedom Scientific. I used to code Java desktop software using my Notepad, so I'm familiar with programming using Notepad.
Also, if I somehow figure out how to make Android apps using Notepad, how am I going to test them? Do I need a phone? I'm sorry for all these beginner questions, but I'm a beginner :)
You can follow this link:
http://developer.android.com/tools/building/building-cmdline.html
If you only want to build, not run, you don't need a phone. If you want test without a phone you can use an emulator by running"AVD Manager.exe" in Android SDK folder.
The good thing since the transition to android studio is that now the building of an android project is done using Gradle and can be piloted entirely by command line. So technically, you don't need an IDE at all.
Basically, every project has at least a build.gradle file that contains the instructions to build it. You only have to launch Gradle with the appropriate command to compile your app.
Yelliver mentionned the tools to build the app from the command line, there are also tools to create the project structure and the basic build files: http://developer.android.com/tools/projects/projects-cmdline.html (this documentation appears not to be entirely up-to-date, though, as it mentions the old project.properties format)
Having a phone to run your app is certainly going to be nicer and faster to develop. The emulator is far from perfect, quite slow, and sometimes not responsive. It is also easier to install other apps on your phone than on the emulator, in case your app interacts with other apps.
I wrote two small scripts for Android development without using Android Studio. They are building apk and installing it on the connected device and opening the logcat with the output of the installed application. This two scripts not even near to complete when to think all the features of the Android Studio but they are allowing to at least run the project on your phone.

Java Application on Smartphone

What alteration should be made in a Java Application to be able to install it on Java Enabled Smartphone?
I tried using a random app of mine to see what happens, when I open it on the cell, it says Install? I say yes, and it says invalid file.
Now I was wondering what alteration should be made?
My smartphone (Samsung S8500) runs on bada which is more or less the same as Android, but alterations in the General.
You need different SDK for smartphones. Like for Android, you need Android SDK 1.5 or any other version. You just cannot install the same application. You need to develop using the resources provided by the SDK.
If your application is Java based mobile application then you can use some tools to convert it for Android. Doesn't work every time but worth a try.
In your case, Bada OS is not like Android what i learn from here. So, you need to develop the application using J2ME .

Categories

Resources