Maintaining backward compatibility

This commit is contained in:
Luca Frosini 2023-04-26 09:31:43 +02:00
parent 037d119697
commit bb9e1fdd93
2 changed files with 30 additions and 4 deletions

View File

@ -32,9 +32,23 @@ public interface ResourceRegistryClient {
public void setHierarchicalMode(boolean hierarchicalMode);
public boolean isIncludeContexts();
/**
* Use {@link #includeContexts()} instead
* @return
*/
@Deprecated
public boolean isIncludeContextsInHeader();
public void setIncludeContexts(boolean includeContexts);
/**
* Use {@link #includeContexts(boolean)} instead
* @param includeContextsInHeader
*/
@Deprecated
public void setIncludeContextsInHeader(boolean includeContexts);
public boolean includeContexts();
public void includeContexts(boolean includeContexts);
public void addHeader(String name, String value);

View File

@ -76,13 +76,25 @@ public class ResourceRegistryClientImpl implements ResourceRegistryClient {
this.hierarchicalMode = hierarchicalMode;
}
@Deprecated
@Override
public boolean isIncludeContexts() {
public boolean isIncludeContextsInHeader() {
return includeContexts();
}
@Deprecated
@Override
public void setIncludeContextsInHeader(boolean includeContexts) {
includeContexts(includeContexts);
}
@Override
public boolean includeContexts() {
return includeContexts;
}
@Override
public void setIncludeContexts(boolean includeContexts) {
public void includeContexts(boolean includeContexts) {
this.includeContexts = includeContexts;
}