chore: Bump version to 1.6.14 and add setValues method to AgentContext for improved context management

This commit is contained in:
extio-de
2025-09-23 17:52:25 +02:00
parent 103ff2cb40
commit 34ff8844a3
2 changed files with 10 additions and 1 deletions

View File

@@ -124,6 +124,15 @@ public final class AgentContext {
this.context.put(key, List.of(value));
}
}
public <T> void setValues(final String key, final Collection<T> values) {
if (values == null) {
this.context.remove(key);
}
else {
this.context.put(key, List.copyOf(values));
}
}
public Map<String, List<? extends Object>> getContext() {
return this.context;