/*
* ============LICENSE_START=======================================================
- * Copyright (C) 2022-2024 Nordix Foundation
+ * Copyright (C) 2022-2025 OpenInfra Foundation Europe. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
import java.util.Map;
import lombok.NoArgsConstructor;
import org.apache.commons.lang3.StringUtils;
-import org.apache.logging.log4j.util.Strings;
+import org.apache.commons.lang3.Strings;
import org.springframework.web.util.UriComponentsBuilder;
@NoArgsConstructor
*/
public RestServiceUrlTemplateBuilder queryParameter(final String queryParameterName,
final String queryParameterValue) {
- if (Strings.isNotBlank(queryParameterValue)) {
+ if (StringUtils.isNotBlank(queryParameterValue)) {
queryParameters.put(queryParameterName, queryParameterValue);
}
return this;
final Map<String, String> urlTemplateVariables = new HashMap<>();
pathSegments.forEach((pathSegmentName, variablePathValue) -> {
- if (StringUtils.equals(variablePathValue, FIXED_PATH_SEGMENT)) {
+ if (Strings.CS.equals(variablePathValue, FIXED_PATH_SEGMENT)) {
this.uriComponentsBuilder.pathSegment(pathSegmentName);
} else {
this.uriComponentsBuilder.pathSegment("{" + pathSegmentName + "}");
/*
* ============LICENSE_START=======================================================
- * Copyright (C) 2020-2025 Nordix Foundation
+ * Copyright (C) 2020-2025 OpenInfra Foundation Europe. All rights reserved.
* Modifications Copyright (C) 2020-2022 Bell Canada.
* Modifications Copyright (C) 2021 Pantheon.tech
* Modifications Copyright (C) 2022 TechMahindra Ltd.
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.codec.digest.DigestUtils;
-import org.apache.commons.lang3.StringUtils;
+import org.apache.commons.lang3.Strings;
import org.hibernate.exception.ConstraintViolationException;
import org.onap.cps.api.exceptions.AlreadyDefinedException;
import org.onap.cps.api.exceptions.DuplicatedYangResourceException;
private String getNameForChecksum(final String checksum,
final Collection<YangResourceEntity> yangResourceEntities) {
final Optional<String> optionalFileName = yangResourceEntities.stream()
- .filter(entity -> StringUtils.equals(checksum, (entity.getChecksum())))
+ .filter(entity -> Strings.CS.equals(checksum, (entity.getChecksum())))
.findFirst()
.map(YangResourceEntity::getFileName);
return optionalFileName.orElse("no filename");