Skip to content

Update code and docs for minimum Android API level 24 - #3085

Merged
eamonnmcmanus merged 2 commits into
google:mainfrom
Marcono1234:marcono1234/android-api-level-24
Aug 5, 2026
Merged

Update code and docs for minimum Android API level 24#3085
eamonnmcmanus merged 2 commits into
google:mainfrom
Marcono1234:marcono1234/android-api-level-24

Conversation

@Marcono1234

Copy link
Copy Markdown
Contributor

Purpose

Follow-up for #3082

Description

The overridden methods for NonNullElementWrapperList are already covered
by the tests in JsonArrayAsListTest.
Comment on lines +122 to +130
@Override
public void sort(Comparator<? super E> c) {
delegate.sort(c);
}

@Override
public Spliterator<E> spliterator() {
return delegate.spliterator();
}

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are already covered by the tests in JsonArrayAsListTest.

The minimum API level for the `check-android-compatibility` check had
been increased to 23, but it seems there was no usage from that API level.

@eamonnmcmanus eamonnmcmanus left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing this! I had meant to update the documentation, but I hadn't thought of all those other changes.

Comment thread README.md

#### Minimum Android API level

- Gson 2.15.0 and newer: API level 24

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had been planning on releasing 2.14.1 next, but I think you're right that the change in Android SDK level implies upping the minor level.

@eamonnmcmanus
eamonnmcmanus merged commit 9d5d6a8 into google:main Aug 5, 2026
21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants