• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Apps Does Android Studio support Java 14? if so how....

I've done some more investigation and now have a slightly different understanding. The version of Gradle that you use determines the max version of java that you can use for your gradle builds. See docs.gradle.org/current/userguide/compatibility.html. For example, I'm using gradle 7.4 and I use Java 14 to build my custom gradle plugins. The version of java that you use for your gradle builds has nothing to do with the version of java that android supports. It's the combination of the version of your android gradle plugin and your android sdk that determines what java language features you can use. Your andoid/SDK/build-tools directory contains a D8.bat file. D8 is the build tool used for converting java into dex. That batch file finds an appropriate java jdk to run the d8.jar file also contain in your build-tools directory. I'm not sure if this program takes java files as input or java class files, but I think it's the later. In my case, the java jdk it uses to run the d8.jar is a java 8 compiler. That compiler (jdk version) gets set up by Android Studio. Be aware that newer versions of Android Studio could embed a different compiler. I'm using Android Studio 2021.2.1, which is the most current version at the time of this posting. That warning message D8: "One or more classes has class file version >= 56 which is not officially supported", comes from that process. So essentially, that process seems to be saying that it ownly reliably supports java class file formats up to verion 55 which is of course Java 11. That said, android itself currently only supports Java 7 in its entirety and a subset of java 8. Here's a link to the subset of java 8 features that android supports: Use Java 8 language features and APIs | Android Developers. That link says that in order to those java 8 features you must set sourceCompatibility and targetCompatibility to Java 1.8. My guess is that if you set those options to a higher value it treats it like you set it to 1.8; it doesn't give you any errors; and it just confuses everyone as to what that means since most of us provide configuration data by example of what others have done. Again, that's just a guess. So what that D8 program does, is to take your input and builds dex code that is compatible to run on android. So if you use, some features that are not java 7 or part of the subset of java 8 that android supports, it apparently figures out a way to do that, perhaps with the addition of some added support code which may vary depending on the verion of the SDK version you're targeting. This process is known as desugaring. I'm going to guess that you'll get some kind of error if you provide a language feature that the d8 program doesn't support. That's probably why android documentation is pretty vague on the issue of java compatibility; it depends on your configuration.

room database problem

I've been using sqlite forever. Finally decided to update my app to room database. Converting it was a treat but afterwards I realized I may have lost a functionality that the DBHelper allowed me to do.

I am currently getting LiveData<List<type>> return from the Dao of my main table. Getting that through a Repository and a ViewModel which holds the LiveData along with an observer. In the database helper I had a routine after iterating the cursor that created a List<object>. The regular rows + header objects mixed in with them. i could then check for type in the Recyclerview adapter and either create a header or a row.

In the Dao I have several @Query lines but not sure how to use the Query to return the same result. I could get the List<type> from the viewmodel observer and work a little mojo on it finally passing it into an object list and use that for the Recyclerview adapter. The livedata would keep the feed up to date. Is there a better way?

Help Cannot Restore WhatsApp from Local Backup

Hello.

I am migrating Whatsapp to a new phone with Android 11 from an old phone with Android 8.

Followed steps outlined here:
https://www.techbout.com/restore-whatsapp-from-local-backup-android-phone-55696/

Long story short:

- Online backup is messed up
- Didn't backup app's data folder in root/Android/media

Tried restoring from local chat backup in Databases by renaming desired backup to msgstore.db.ctypt14 and it didn't work.

Also what is "chatsettingsbackup.db.crypt14" file in Backup folder?

Help - predictive text

Productive text is GARBAGE. So bad I'd get a new phone if i mule afford it. Other keyboards work momentarily but I find they act up too all I've been able to do with consistency is long press the key i want then the 3 or 4 options for that key pop up and i scroll to the letter i want release it go to next letter and so on til the word i want finally pops up. I use T9. Good luck

Wifi Calling

...Talked with samsung rep on the phone and they told me to call my cell carrier. I am now confused, I thought this would be a hardware feature, not dependant on my carrier.
....

Yes it's a hardware feature but your phone already includes support for phone calling and for WiFi connectivity. The actual WiFi Calling service is dependent on whether your account with your carrier includes it. Contact your carrier.

Digital Clock Thing

I mainly use analogue timepieces, but when I look at a digital clock (like in the corner of this laptop right now)... nope, it's just the time to me.;)

I always set any digital clock to 24 hour mode though - since public transport timetables are 24 hour it's always made more sense to me to use that (on this side of the Pond the American name "military time" sounds weird, since here it's more likely to be associated with train timetables than the military).

com.android.chrome:privileged_process4

Because my battery is holdinv pretty good until about a week ago. At evening i put it to charge and in the morning i almost always get from device care the message that some apps were closed and i get this com.android.chrome:privileged_process4. Also if i close all apps including chrome doesnt make any change, battery still going down pretty fast, by fast i mean like about 8 hours not using my phone. But before was easily holding all day long using the phone.
well "com.android.chrome" is your chrome browser and "priveleged process4" has to do with your permissions. you might want to clear or change permissions for the chrome browser and see if that helps:
https://support.google.com/android/answer/9431959?hl=en

if that does not help, you can do a few things.
1. reboot your phone
2. put your phone in safe mode. this prevents any 3rd party apps from running.
3. factory reset your phone

if those do not work, then like i said your battery is probably on its way out, so maybe now is the time to start looking for a new phone.

Help [SOLVED] "Safe Notepad" to keep bunch of passwords?

Thanks for the links.

To enter data, in Android, I'll just copy a whole text from my Windows computer (through the web or by coping the TXT file into Android), paste it, and encrypt it in one go. I don't need more than that.

There are tons of "notepad safe" apps, and as usual, it takes forever to find a good one.

Ideally, open-source.

--
Edit: Safe Notes looks like what I had in mind. I don't like its "slot" thingie at the bottom, and would rather have all notes in a list, where a note could simply be tagged in case I need to filter.

Pl6RyvOQBMU4tFq7eiwTlXtyo2D0uoP_CftVKuUqYTTCuPIH6ucuQNK-6vLvjMgOf7I=w1193-h921-rw


---
Edit: For others' benefit. I tried a bunch of them, and the closest I found of a free, no-brainer, no-thrill app is "Note Crypt Safe with Password".

Help Enable VoLTE

That's worth looking into. Typically, I'd forgotten where the phone came from but luckily kept the emails from Tello confirming my purchase from them. I can check this with them. Might be the clue THEY need.

By the way, I've also added an APN as specified by Tello. I really thought that was going to do it. But n o o o o o o . . .

Did you ever figure out how to get it to work? I have the same phone model. I'm currently testing out PagePlus, which uses Verizon, and one thing I noticed is that the "VoLTE provisioned" setting starts out disabled, and if I enable it, it doesn't stay enabled past a reboot of the phone. Even with "VoLTE provisioned" turned off, I can still make calls, which I don't really have an explanation for, but I just thought I'd mention it and ask you what you ultimately did on your end.

Filter

Back
Top Bottom