Class ParameterDisplay
java.lang.Object
io.jenkins.plugins.batchcontrol.store.ParameterDisplay
@Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class)
public final class ParameterDisplay
extends Object
D-72: the one place where typed
ParameterValues become the masked text that Batch
Control displays or writes (the request's parameters map, run records, incidents, CSV).
- a sensitive value (
ParameterValue.isSensitive(), aSecret) is "********"; - a file value is "[file]" followed by its original file name, never its content, its Base64 text or a server path;
- anything else is
String.valueOf(value.getValue()).
File values are core's FileParameterValue, the file values of the optional
file-parameters plugin when it is installed (FileParametersSupport), and any other value
whose raw value is an uploaded file item or a File.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanisFile(ParameterValue value) Whethervalueis a file value (see the class description).masked(Collection<? extends ParameterValue> values) The masked display map ofvalues, by parameter name in submission order.static StringstoredText(ParameterValue value) D-72b (2): the text a non-file value stores, which the length and character limits apply to: the plaintext of aSecret(a password included, although it is displayed masked), otherwiseString.valueOf(value.getValue()),""fornull.static Stringtext(ParameterValue value) The masked display text of one value (see the class description).
-
Field Details
-
FILE_PREFIX
Display prefix of a file value (D-72).- See Also:
-
-
Method Details
-
masked
The masked display map ofvalues, by parameter name in submission order. Values without a name are left out; with a repeated name the first value wins, asParametersAction#getParameterreads it (a run request refuses repeated names before this is derived, D-72b (1); run records and incidents mask a build's own values). -
text
The masked display text of one value (see the class description). -
storedText
D-72b (2): the text a non-file value stores, which the length and character limits apply to: the plaintext of aSecret(a password included, although it is displayed masked), otherwiseString.valueOf(value.getValue()),""fornull. A file value has none (null): its content, Base64 included, is bounded by the body cap only.nullas well when the value cannot be read as text. -
isFile
Whethervalueis a file value (see the class description).
-