Package org.mockserver.model
Class KeysAndValues<T extends KeyAndValue,K extends KeysAndValues>
java.lang.Object
org.mockserver.model.ObjectWithReflectiveEqualsHashCodeToString
org.mockserver.model.ObjectWithJsonToString
org.mockserver.model.KeysAndValues<T,K>
- Direct Known Subclasses:
Cookies
public abstract class KeysAndValues<T extends KeyAndValue,K extends KeysAndValues>
extends ObjectWithJsonToString
- Author:
- jamesdbloom
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedprotected -
Method Summary
Modifier and TypeMethodDescriptionabstract Tbuild(NottableString name, NottableString value) abstract Kclone()getConvertedMatcher(boolean controlPlaneMatcher) Returns the memoized request-side conversion for the given control-plane flag, ornullif not yet built.getMap()booleanisEmpty()booleanbooleanremove(NottableString name) replaceEntryIfExists(T entry) voidsetConvertedMatcher(boolean controlPlaneMatcher, Object converted) Stores the memoized request-side conversion for the given control-plane flag.withEntries(List<T> entries) withEntries(T... entries) withEntry(NottableString name, NottableString value) Methods inherited from class org.mockserver.model.ObjectWithJsonToString
toStringMethods inherited from class org.mockserver.model.ObjectWithReflectiveEqualsHashCodeToString
equals, fieldsExcludedFromEqualsAndHashCode, hashCode
-
Constructor Details
-
KeysAndValues
protected KeysAndValues() -
KeysAndValues
-
-
Method Details
-
build
-
getConvertedMatcher
Returns the memoized request-side conversion for the given control-plane flag, ornullif not yet built. The conversion is intentionally keyed bycontrolPlaneMatcherbecause the converted form embeds a control-plane-sensitive matcher; a data-plane conversion must never be served to a control-plane caller or vice versa. -
setConvertedMatcher
Stores the memoized request-side conversion for the given control-plane flag. The cache is cleared automatically on any mutation, so callers may safely reuse the value for the lifetime of an unmutated collection (e.g. across a single request's expectation scan). -
withEntries
-
withEntries
-
withEntry
-
withEntry
-
withEntry
-
replaceEntryIfExists
-
getEntries
-
getMap
-
isEmpty
public boolean isEmpty() -
remove
-
remove
-
clone
-