
com.ithit.webdav.integration.utils.IntegrationUtil Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jakarta-integration Show documentation
Show all versions of jakarta-integration Show documentation
IT Hit WebDAV integration for new Jakarta Java servlet containers
package com.ithit.webdav.integration.utils;
import java.util.List;
import java.util.Map;
public final class IntegrationUtil {
public static final String INSTANCE_HEADER_NAME = "InstanceId";
private IntegrationUtil() {}
public static String findInstanceHeader(Map> httpHeaders) {
return httpHeaders
.entrySet()
.stream()
.filter(x -> x.getKey().equalsIgnoreCase(INSTANCE_HEADER_NAME))
.findFirst().map(x -> {
if (!x.getValue().isEmpty()) {
return x.getValue().get(0);
}
return "";
})
.orElse("");
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy