Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop public usage of StringUtil#join, deprecated since 2019 #45777

Merged
merged 1 commit into from
Jan 22, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -112,13 +112,13 @@ public String next() {
}

/**
* @deprecated Use {@link String#join} instead.
* Dropped for public usage, kept in place for usage by hyphenate method to avoid need for lambda
*
* @param delim delimiter
* @param it iterator
* @return the joined string
*/
@Deprecated
public static String join(String delim, Iterator<String> it) {
private static String join(String delim, Iterator<String> it) {
final StringBuilder b = new StringBuilder();
if (it.hasNext()) {
b.append(it.next());
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package io.quarkus.spring.boot.properties.deployment;

import static io.quarkus.runtime.util.StringUtil.camelHumpsIterator;
import static io.quarkus.runtime.util.StringUtil.join;
import static io.quarkus.runtime.util.StringUtil.lowerCase;
import static io.quarkus.runtime.util.StringUtil.withoutSuffix;

Expand Down Expand Up @@ -67,11 +66,10 @@ private String sanitisePrefix(String prefix) {
return prefix;
}

@SuppressWarnings("deprecation")
private String getPrefixFromClassName(DotName className) {
String simpleName = className.isInner() ? className.local() : className.withoutPackagePrefix();
return join("-",
withoutSuffix(lowerCase(camelHumpsIterator(simpleName)), "config", "configuration",
return String.join("-",
(Iterable<String>) () -> withoutSuffix(lowerCase(camelHumpsIterator(simpleName)), "config", "configuration",
"properties", "props"));
}

Expand Down
Loading